(self)
| 1228 | assert list(reversed(bx)) == ["c", "a"] |
| 1229 | |
| 1230 | def test_clear(self): |
| 1231 | bx = Box() |
| 1232 | bx.a = 1 |
| 1233 | bx.c = 4 |
| 1234 | bx["g"] = 7 |
| 1235 | bx.d = 2 |
| 1236 | assert list(bx.keys()) == ["a", "c", "g", "d"] |
| 1237 | bx.clear() |
| 1238 | assert bx == {} |
| 1239 | assert not bx.keys() |
| 1240 | |
| 1241 | def test_bad_recursive(self): |
| 1242 | b = Box() |