(self)
| 100 | assert self.get(d, "f") == [[[6, [1, 2]], 6], 2] |
| 101 | |
| 102 | def test_get_with_nested_list(self): |
| 103 | d = {"x": 1, "y": 2, "z": (sum, ["x", "y"])} |
| 104 | |
| 105 | assert self.get(d, [["x"], "y"]) == ((1,), 2) |
| 106 | assert self.get(d, "z") == 3 |
| 107 | |
| 108 | def test_get_works_with_unhashables_in_values(self): |
| 109 | f = lambda x, y: x + len(y) |