MCPcopy Create free account
hub / github.com/sqlalchemy/sqlalchemy / test_empty_uc

Method test_empty_uc

test/sql/test_constraints.py:1109–1121  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

1107 )
1108
1109 def test_empty_uc(self):
1110 # test that an empty constraint is ignored
1111 metadata = MetaData()
1112 tbl = Table(
1113 "test",
1114 metadata,
1115 Column("x", Integer, autoincrement=False),
1116 Column("y", Integer, autoincrement=False),
1117 UniqueConstraint(),
1118 )
1119 self.assert_compile(
1120 schema.CreateTable(tbl), "CREATE TABLE test (x INTEGER, y INTEGER)"
1121 )
1122
1123 def test_deferrable_column_check(self):
1124 t = Table(

Callers

nothing calls this directly

Calls 5

MetaDataClass · 0.90
TableClass · 0.90
ColumnClass · 0.90
UniqueConstraintClass · 0.90
assert_compileMethod · 0.80

Tested by

no test coverage detected