diff options
| author | Mike Bayer <mike_mp@zzzcomputing.com> | 2009-11-22 22:11:41 +0000 |
|---|---|---|
| committer | Mike Bayer <mike_mp@zzzcomputing.com> | 2009-11-22 22:11:41 +0000 |
| commit | d9388a51944e1c5bb389a33a2cd824a7e8672115 (patch) | |
| tree | 2a349d610575c6a021b02ec29a78a2d08c1d1619 /test/sql | |
| parent | 66b7d008ee2975744212fc1b3831375b15db055f (diff) | |
| download | sqlalchemy-d9388a51944e1c5bb389a33a2cd824a7e8672115.tar.gz | |
- VARCHAR/NVARCHAR will not render without a length, raises
an error before passing to MySQL. Doesn't impact
CAST since VARCHAR is not allowed in MySQL CAST anyway,
the dialect renders CHAR/NCHAR in those cases.
[ticket:1252]
Diffstat (limited to 'test/sql')
| -rw-r--r-- | test/sql/test_types.py | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/test/sql/test_types.py b/test/sql/test_types.py index 332e02ef5..04c193e01 100644 --- a/test/sql/test_types.py +++ b/test/sql/test_types.py @@ -42,8 +42,8 @@ class AdaptTest(TestBase): (DATE, "DATE"), (TIME, "TIME"), (CLOB, "CLOB"), - (VARCHAR, "VARCHAR"), - (NVARCHAR, ("NVARCHAR", "NATIONAL VARCHAR")), + (VARCHAR(10), "VARCHAR(10)"), + (NVARCHAR(10), ("NVARCHAR(10)", "NATIONAL VARCHAR(10)", "NVARCHAR2(10)")), (CHAR, "CHAR"), (NCHAR, ("NCHAR", "NATIONAL CHAR")), (BLOB, "BLOB"), @@ -52,7 +52,7 @@ class AdaptTest(TestBase): if isinstance(expected, str): expected = (expected, ) for exp in expected: - compiled = type_().compile(dialect=dialect) + compiled = types.to_instance(type_).compile(dialect=dialect) if exp in compiled: break else: |
