summaryrefslogtreecommitdiffstats
path: root/tests/auto/qsqldriver/tst_qsqldriver.cpp
diff options
context:
space:
mode:
authorBill King <bill.king@nokia.com>2009-07-13 04:56:24 (GMT)
committerBill King <bill.king@nokia.com>2009-07-13 04:56:24 (GMT)
commitc2f6c3eb4381a987df47601fcbab4e3a98d40813 (patch)
treedd2ead50e5dbf4476997ff08cae247945d7bda12 /tests/auto/qsqldriver/tst_qsqldriver.cpp
parentb7d274c1fc818b347ff9256a00e4f667f0bd1556 (diff)
downloadQt-c2f6c3eb4381a987df47601fcbab4e3a98d40813.zip
Qt-c2f6c3eb4381a987df47601fcbab4e3a98d40813.tar.gz
Qt-c2f6c3eb4381a987df47601fcbab4e3a98d40813.tar.bz2
Fixes up the autotest for mysql over ODBC connection.
Diffstat (limited to 'tests/auto/qsqldriver/tst_qsqldriver.cpp')
-rw-r--r--tests/auto/qsqldriver/tst_qsqldriver.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/tests/auto/qsqldriver/tst_qsqldriver.cpp b/tests/auto/qsqldriver/tst_qsqldriver.cpp
index 6d428df..b79c093 100644
--- a/tests/auto/qsqldriver/tst_qsqldriver.cpp
+++ b/tests/auto/qsqldriver/tst_qsqldriver.cpp
@@ -158,7 +158,7 @@ void tst_QSqlDriver::record()
//check that we can't get records using incorrect tablename casing that's been quoted
rec = db.driver()->record(db.driver()->escapeIdentifier(tablename,QSqlDriver::TableName));
- if (db.driverName().startsWith("QMYSQL") || db.driverName().startsWith("QSQLITE") || db.driverName().startsWith("QTDS"))
+ if (tst_Databases::isMySQL(db) || db.driverName().startsWith("QSQLITE") || db.driverName().startsWith("QTDS"))
QCOMPARE(rec.count(), 4); //mysql, sqlite and tds will match
else
QCOMPARE(rec.count(), 0);
@@ -204,7 +204,7 @@ void tst_QSqlDriver::primaryIndex()
tablename = tablename.toUpper();
index = db.driver()->primaryIndex(db.driver()->escapeIdentifier(tablename, QSqlDriver::TableName));
- if (db.driverName().startsWith("QMYSQL") || db.driverName().startsWith("QSQLITE") || db.driverName().startsWith("QTDS"))
+ if (tst_Databases::isMySQL(db) || db.driverName().startsWith("QSQLITE") || db.driverName().startsWith("QTDS"))
QCOMPARE(index.count(), 1); //mysql will always find the table name regardless of casing
else
QCOMPARE(index.count(), 0);