summaryrefslogtreecommitdiff
path: root/test/dialect/postgresql
diff options
context:
space:
mode:
Diffstat (limited to 'test/dialect/postgresql')
-rw-r--r--test/dialect/postgresql/test_compiler.py5
-rw-r--r--test/dialect/postgresql/test_types.py36
2 files changed, 36 insertions, 5 deletions
diff --git a/test/dialect/postgresql/test_compiler.py b/test/dialect/postgresql/test_compiler.py
index c707137a8..2223b0a76 100644
--- a/test/dialect/postgresql/test_compiler.py
+++ b/test/dialect/postgresql/test_compiler.py
@@ -212,7 +212,10 @@ class CompileTest(fixtures.TestBase, AssertsCompiledSQL):
t1 = Table(
"sometable",
MetaData(),
- Column("somecolumn", Enum("x", "y", "z", native_enum=False)),
+ Column(
+ "somecolumn",
+ Enum("x", "y", "z", native_enum=False, create_constraint=True),
+ ),
)
self.assert_compile(
schema.CreateTable(t1),
diff --git a/test/dialect/postgresql/test_types.py b/test/dialect/postgresql/test_types.py
index 2adde8edc..d7f6faf92 100644
--- a/test/dialect/postgresql/test_types.py
+++ b/test/dialect/postgresql/test_types.py
@@ -288,7 +288,14 @@ class EnumTest(fixtures.TestBase, AssertsExecutionResults):
metadata,
Column(
"bar",
- Enum("one", "two", "three", name="myenum", native_enum=False),
+ Enum(
+ "one",
+ "two",
+ "three",
+ name="myenum",
+ create_constraint=True,
+ native_enum=False,
+ ),
),
)
@@ -317,7 +324,14 @@ class EnumTest(fixtures.TestBase, AssertsExecutionResults):
"foo",
metadata,
Column(
- "bar", Enum("B", util.u("Ü"), name="myenum", native_enum=False)
+ "bar",
+ Enum(
+ "B",
+ util.u("Ü"),
+ name="myenum",
+ create_constraint=True,
+ native_enum=False,
+ ),
),
)
@@ -500,7 +514,16 @@ class EnumTest(fixtures.TestBase, AssertsExecutionResults):
t1 = Table(
"foo",
metadata,
- Column("bar", Enum("one", "two", "three", name="myenum")),
+ Column(
+ "bar",
+ Enum(
+ "one",
+ "two",
+ "three",
+ name="myenum",
+ create_constraint=True,
+ ),
+ ),
)
def go():
@@ -1762,7 +1785,12 @@ class ArrayEnum(fixtures.TestBase):
"my_col",
array_cls(
enum_cls(
- "foo", "bar", "baz", name="my_enum", native_enum=False
+ "foo",
+ "bar",
+ "baz",
+ name="my_enum",
+ create_constraint=True,
+ native_enum=False,
)
),
),