MCPcopy
hub / github.com/sqlalchemy/sqlalchemy / test_odict_copy

Method test_odict_copy

test/base/test_utils.py:187–197  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

185 eq_(list(o.keys()), ["name", "fullname", "password"])
186
187 def test_odict_copy(self):
188 o = util.OrderedDict()
189 o["zzz"] = 1
190 o["aaa"] = 2
191 eq_(list(o.keys()), ["zzz", "aaa"])
192
193 o2 = o.copy()
194 eq_(list(o2.keys()), list(o.keys()))
195
196 o3 = copy.copy(o)
197 eq_(list(o3.keys()), list(o.keys()))
198
199 def test_no_sort_legacy_dictionary(self):
200 d1 = {"c": 1, "b": 2, "a": 3}

Callers

nothing calls this directly

Calls 3

eq_Function · 0.90
keysMethod · 0.45
copyMethod · 0.45

Tested by

no test coverage detected