(self)
| 265 | self.assertEqual(pickle_depickle(lambda: 1, protocol=self.protocol)(), 1) |
| 266 | |
| 267 | def test_nested_lambdas(self): |
| 268 | a, b = 1, 2 |
| 269 | f1 = lambda x: x + a # noqa: E731 |
| 270 | f2 = lambda x: f1(x) // b # noqa: E731 |
| 271 | self.assertEqual(pickle_depickle(f2, protocol=self.protocol)(1), 1) |
| 272 | |
| 273 | def test_recursive_closure(self): |
| 274 | def f1(): |
nothing calls this directly
no test coverage detected