summaryrefslogtreecommitdiff
path: root/test/dialect/mysql.py
diff options
context:
space:
mode:
authorJason Kirtland <jek@discorporate.us>2008-01-09 20:22:41 +0000
committerJason Kirtland <jek@discorporate.us>2008-01-09 20:22:41 +0000
commitc83bb94e0d65c31ff423c3e08dd1fc27744ab4dc (patch)
treedc60005e9541f534e2533dc951caf53e777e282a /test/dialect/mysql.py
parent979c9323dce30c3a12552668fc93958cba566cca (diff)
downloadsqlalchemy-c83bb94e0d65c31ff423c3e08dd1fc27744ab4dc.tar.gz
Added UnicodeText alias
Diffstat (limited to 'test/dialect/mysql.py')
-rw-r--r--test/dialect/mysql.py16
1 files changed, 14 insertions, 2 deletions
diff --git a/test/dialect/mysql.py b/test/dialect/mysql.py
index 5f5c4a750..0a9153327 100644
--- a/test/dialect/mysql.py
+++ b/test/dialect/mysql.py
@@ -1,5 +1,5 @@
import testbase
-import sets
+import sets, warnings
from sqlalchemy import *
from sqlalchemy import sql, exceptions
from sqlalchemy.databases import mysql
@@ -632,6 +632,11 @@ class TypesTest(AssertMixin):
specs = [( String(), mysql.MSText(), ),
( String(1), mysql.MSString(1), ),
( String(3), mysql.MSString(3), ),
+ ( Text(), mysql.MSText(), ),
+ ( Unicode(), mysql.MSText(), ),
+ ( Unicode(1), mysql.MSString(1), ),
+ ( Unicode(3), mysql.MSString(3), ),
+ ( UnicodeText(), mysql.MSText(), ),
( mysql.MSChar(1), ),
( mysql.MSChar(3), ),
( NCHAR(2), mysql.MSChar(2), ),
@@ -660,7 +665,13 @@ class TypesTest(AssertMixin):
m = MetaData(db)
t_table = Table('mysql_types', m, *columns)
try:
- m.create_all()
+ try:
+ warnings.filterwarnings('ignore',
+ 'Using String type with no length.*')
+ m.create_all()
+ finally:
+ warnings.filterwarnings("always",
+ 'Using String type with no length.*')
m2 = MetaData(db)
rt = Table('mysql_types', m2, autoload=True)
@@ -876,6 +887,7 @@ class SQLTest(SQLCompileTest):
(String, "CAST(t.col AS CHAR)"),
(Unicode, "CAST(t.col AS CHAR)"),
+ (UnicodeText, "CAST(t.col AS CHAR)"),
(VARCHAR, "CAST(t.col AS CHAR)"),
(NCHAR, "CAST(t.col AS CHAR)"),
(CHAR, "CAST(t.col AS CHAR)"),