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

Method test_default_box_callable

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

Source from the content-addressed store, hash-verified

1793 assert {"a": 1} | my_box == {"a": 5}
1794
1795 def test_default_box_callable(self):
1796 def func(box_instance, key):
1797 return DDBox(bi=str(box_instance), key=key)
1798
1799 my_box = DDBox(default_box_attr=func)
1800
1801 assert my_box.a == {"bi": "{}", "key": "a"}
1802
1803
1804@pytest.mark.parametrize("create_on_get", [True, False])

Callers

nothing calls this directly

Calls 1

DDBoxClass · 0.90

Tested by

no test coverage detected