diff options
author | Aaron Kennedy <aaron.kennedy@nokia.com> | 2010-04-15 06:41:15 (GMT) |
---|---|---|
committer | Aaron Kennedy <aaron.kennedy@nokia.com> | 2010-04-15 06:41:15 (GMT) |
commit | d8a49ccfb8308aec11cd24e823c297ef157cc4c6 (patch) | |
tree | 18fc19e36264839be851553a892480ce575da11e /tests/auto/declarative/qdeclarativesqldatabase/data/error-a.js | |
parent | 30a3e78a12b72ab6f67992ec2f06cd4f21a01a6c (diff) | |
parent | 62e52a19f1c7ac81a36f394e43f916c3c8933e8f (diff) | |
download | Qt-d8a49ccfb8308aec11cd24e823c297ef157cc4c6.zip Qt-d8a49ccfb8308aec11cd24e823c297ef157cc4c6.tar.gz Qt-d8a49ccfb8308aec11cd24e823c297ef157cc4c6.tar.bz2 |
Merge branch '4.7' of scm.dev.nokia.troll.no:qt/qt-qml into 4.7
Diffstat (limited to 'tests/auto/declarative/qdeclarativesqldatabase/data/error-a.js')
-rw-r--r-- | tests/auto/declarative/qdeclarativesqldatabase/data/error-a.js | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/tests/auto/declarative/qdeclarativesqldatabase/data/error-a.js b/tests/auto/declarative/qdeclarativesqldatabase/data/error-a.js new file mode 100644 index 0000000..10a23f6 --- /dev/null +++ b/tests/auto/declarative/qdeclarativesqldatabase/data/error-a.js @@ -0,0 +1,20 @@ +function test() { + var db = openDatabaseSync("QmlTestDB-error-a", "1.0", "Test database from Qt autotests", 1000000); + var r="transaction_not_finished"; + + try { + db.transaction( + function(tx) { + var rs = tx.executeSql('SELECT * FROM NotExists'); + r = "SHOULD NOT SUCCEED"; + } + ); + } catch (err) { + if (err.message == "no such table: NotExists Unable to execute statement") + r = "passed"; + else + r = "WRONG ERROR="+err.message; + } + + return r; +} |