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

Method test_copy

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

Source from the content-addressed store, hash-verified

900 my_box["a-b"] = 3
901
902 def test_copy(self):
903 my_box = Box(movie_data, camel_killer_box=True)
904 bb = my_box.copy()
905 assert my_box == bb
906 assert isinstance(bb, Box)
907 assert bb._box_config["camel_killer_box"]
908
909 aa = copy.deepcopy(my_box)
910 assert my_box == aa
911 assert isinstance(aa, Box)
912
913 cc = my_box.__copy__()
914 assert my_box == cc
915 assert isinstance(cc, Box)
916 assert cc._box_config["camel_killer_box"]
917
918 dd = BoxList([my_box])
919 assert dd == copy.copy(dd)
920 assert isinstance(copy.copy(dd), BoxList)
921
922 def test_custom_key_errors(self):
923 my_box = Box()

Callers

nothing calls this directly

Calls 4

copyMethod · 0.95
__copy__Method · 0.95
BoxClass · 0.90
BoxListClass · 0.90

Tested by

no test coverage detected