diff options
author | Michael Trier <mtrier@gmail.com> | 2010-02-26 08:50:04 +0000 |
---|---|---|
committer | Michael Trier <mtrier@gmail.com> | 2010-02-26 08:50:04 +0000 |
commit | 824e42b1e60152c0892d51a3e1920b0013bde204 (patch) | |
tree | 453d908b4224ae953bc6d3ea33bf5437c6613694 /test | |
parent | 65be1c2415fdb7193b8eadf1b2c48fbb855cc730 (diff) | |
download | sqlalchemy-824e42b1e60152c0892d51a3e1920b0013bde204.tar.gz |
Match tests have been completely wrong.
Diffstat (limited to 'test')
-rw-r--r-- | test/dialect/test_mssql.py | 4 | ||||
-rw-r--r-- | test/dialect/test_mysql.py | 4 | ||||
-rw-r--r-- | test/dialect/test_postgresql.py | 4 | ||||
-rw-r--r-- | test/dialect/test_sqlite.py | 2 |
4 files changed, 7 insertions, 7 deletions
diff --git a/test/dialect/test_mssql.py b/test/dialect/test_mssql.py index b9c730e46..aa5ecf8cd 100644 --- a/test/dialect/test_mssql.py +++ b/test/dialect/test_mssql.py @@ -555,7 +555,7 @@ class MatchTest(TestBase, AssertsCompiledSQL): matchtable.insert().execute([ {'id': 1, 'title': 'Agile Web Development with Rails', 'category_id': 2}, {'id': 2, 'title': 'Dive Into Python', 'category_id': 1}, - {'id': 3, 'title': 'Programming Matz''s Ruby', 'category_id': 2}, + {'id': 3, 'title': "Programming Matz's Ruby", 'category_id': 2}, {'id': 4, 'title': 'The Definitive Guide to Django', 'category_id': 1}, {'id': 5, 'title': 'Python in a Nutshell', 'category_id': 1} ]) @@ -576,7 +576,7 @@ class MatchTest(TestBase, AssertsCompiledSQL): eq_([2, 5], [r.id for r in results]) def test_simple_match_with_apostrophe(self): - results = matchtable.select().where(matchtable.c.title.match('"Matz''s"')).execute().fetchall() + results = matchtable.select().where(matchtable.c.title.match("Matz's")).execute().fetchall() eq_([3], [r.id for r in results]) def test_simple_prefix_match(self): diff --git a/test/dialect/test_mysql.py b/test/dialect/test_mysql.py index 11e0d77a4..23a85b6bb 100644 --- a/test/dialect/test_mysql.py +++ b/test/dialect/test_mysql.py @@ -1261,7 +1261,7 @@ class MatchTest(TestBase, AssertsCompiledSQL): 'title': 'Dive Into Python', 'category_id': 1}, {'id': 3, - 'title': 'Programming Matz''s Ruby', + 'title': "Programming Matz's Ruby", 'category_id': 2}, {'id': 4, 'title': 'The Definitive Guide to Django', @@ -1302,7 +1302,7 @@ class MatchTest(TestBase, AssertsCompiledSQL): def test_simple_match_with_apostrophe(self): results = (matchtable.select(). - where(matchtable.c.title.match('"Matz''s"')). + where(matchtable.c.title.match("Matz's")). execute(). fetchall()) eq_([3], [r.id for r in results]) diff --git a/test/dialect/test_postgresql.py b/test/dialect/test_postgresql.py index 60022e18a..9982821c0 100644 --- a/test/dialect/test_postgresql.py +++ b/test/dialect/test_postgresql.py @@ -1641,7 +1641,7 @@ class MatchTest(TestBase, AssertsCompiledSQL): matchtable.insert().execute([ {'id': 1, 'title': 'Agile Web Development with Rails', 'category_id': 2}, {'id': 2, 'title': 'Dive Into Python', 'category_id': 1}, - {'id': 3, 'title': 'Programming Matz''s Ruby', 'category_id': 2}, + {'id': 3, 'title': "Programming Matz's Ruby", 'category_id': 2}, {'id': 4, 'title': 'The Definitive Guide to Django', 'category_id': 1}, {'id': 5, 'title': 'Python in a Nutshell', 'category_id': 1} ]) @@ -1666,7 +1666,7 @@ class MatchTest(TestBase, AssertsCompiledSQL): eq_([2, 5], [r.id for r in results]) def test_simple_match_with_apostrophe(self): - results = matchtable.select().where(matchtable.c.title.match("Matz''s")).execute().fetchall() + results = matchtable.select().where(matchtable.c.title.match("Matz's")).execute().fetchall() eq_([3], [r.id for r in results]) def test_simple_derivative_match(self): diff --git a/test/dialect/test_sqlite.py b/test/dialect/test_sqlite.py index 7b428404c..bb08fe341 100644 --- a/test/dialect/test_sqlite.py +++ b/test/dialect/test_sqlite.py @@ -516,7 +516,7 @@ class MatchTest(TestBase, AssertsCompiledSQL): matchtable.insert().execute([ {'id': 1, 'title': 'Agile Web Development with Rails', 'category_id': 2}, {'id': 2, 'title': 'Dive Into Python', 'category_id': 1}, - {'id': 3, 'title': 'Programming Matz''s Ruby', 'category_id': 2}, + {'id': 3, 'title': "Programming Matz's Ruby", 'category_id': 2}, {'id': 4, 'title': 'The Definitive Guide to Django', 'category_id': 1}, {'id': 5, 'title': 'Python in a Nutshell', 'category_id': 1} ]) |