MCPcopy
hub / github.com/sqlalchemy/sqlalchemy / test_pk_mutation

Method test_pk_mutation

test/orm/test_composites.py:1129–1139  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

1127 eq_(g.version, g2.version)
1128
1129 def test_pk_mutation(self):
1130 Graph, Version = self.classes.Graph, self.classes.Version
1131
1132 sess = self._fixture()
1133
1134 g = sess.query(Graph).first()
1135
1136 g.version = Version(2, 1)
1137 sess.commit()
1138 g2 = sess.get(Graph, Version(2, 1))
1139 eq_(g.version, g2.version)
1140
1141 @testing.fails_on_everything_except("sqlite")
1142 def test_null_pk(self):

Callers

nothing calls this directly

Calls 7

_fixtureMethod · 0.95
eq_Function · 0.90
VersionClass · 0.70
firstMethod · 0.45
queryMethod · 0.45
commitMethod · 0.45
getMethod · 0.45

Tested by

no test coverage detected