(self)
| 1584 | self.assertEqual(cloned.__module__, func.__module__) |
| 1585 | |
| 1586 | def test_function_qualname(self): |
| 1587 | def func(x): |
| 1588 | return x |
| 1589 | |
| 1590 | # Default __qualname__ attribute (Python 3 only) |
| 1591 | if hasattr(func, "__qualname__"): |
| 1592 | cloned = pickle_depickle(func, protocol=self.protocol) |
| 1593 | self.assertEqual(cloned.__qualname__, func.__qualname__) |
| 1594 | |
| 1595 | # Mutated __qualname__ attribute |
| 1596 | func.__qualname__ = "<modifiedlambda>" |
| 1597 | cloned = pickle_depickle(func, protocol=self.protocol) |
| 1598 | self.assertEqual(cloned.__qualname__, func.__qualname__) |
| 1599 | |
| 1600 | def test_property(self): |
| 1601 | # Note that the @property decorator only has an effect on new-style |
nothing calls this directly
no test coverage detected