MCPcopy
hub / github.com/sqlalchemy/sqlalchemy / test_pop_default

Method test_pop_default

test/ext/test_mutable.py:373–384  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

371 eq_(f1.data, {"c": "d"})
372
373 def test_pop_default(self):
374 sess = fixture_session()
375
376 f1 = Foo(data={"a": "b", "c": "d"})
377 sess.add(f1)
378 sess.commit()
379
380 eq_(f1.data.pop("a", "q"), "b")
381 eq_(f1.data.pop("a", "q"), "q")
382 sess.commit()
383
384 eq_(f1.data, {"c": "d"})
385
386 def test_pop_default_none(self):
387 sess = fixture_session()

Callers

nothing calls this directly

Calls 6

fixture_sessionFunction · 0.90
eq_Function · 0.90
FooClass · 0.70
addMethod · 0.45
commitMethod · 0.45
popMethod · 0.45

Tested by

no test coverage detected