MCPcopy Create free account
hub / github.com/cdgriffith/Box / test_pickle_default_box

Method test_pickle_default_box

test/test_box.py:969–974  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

967 assert type(loaded.a) is _SubclassBox
968
969 def test_pickle_default_box(self):
970 if platform.python_implementation() == "PyPy":
971 pytest.skip("Pickling does not work correctly on PyPy")
972 bb = Box(default_box=True)
973 loaded = pickle.loads(pickle.dumps(bb))
974 assert bb == loaded
975
976 def test_pickle_preserves_nested_box_dots(self):
977 """Nested boxes must keep box_dots after pickle (#260)."""

Callers

nothing calls this directly

Calls 1

BoxClass · 0.90

Tested by

no test coverage detected