Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1505)

Unified Diff: third_party/sqlite/src/test/corruptD.test

Issue 949043002: Add //third_party/sqlite to dirs_to_snapshot, remove net_sql.patch (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 5 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « third_party/sqlite/src/test/corruptC.test ('k') | third_party/sqlite/src/test/corruptE.test » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/sqlite/src/test/corruptD.test
diff --git a/third_party/sqlite/src/test/corruptD.test b/third_party/sqlite/src/test/corruptD.test
index 61dada65889db69c916119ab549c56af64413a73..63474584c3f9a8058407ad377f05542acfd5b264 100644
--- a/third_party/sqlite/src/test/corruptD.test
+++ b/third_party/sqlite/src/test/corruptD.test
@@ -19,6 +19,10 @@ source $testdir/tester.tcl
#
do_not_use_codec
+# These tests deal with corrupt database files
+#
+database_may_be_corrupt
+
#--------------------------------------------------------------------------
# OVERVIEW
#
@@ -85,7 +89,7 @@ do_test corruptD-1.0 {
DELETE FROM t1 WHERE a = 30;
DELETE FROM t1 WHERE a = 40;
}
- copy_file test.db test.bu
+ forcecopy test.db test.bu
} {}
proc incr_change_counter {} {
@@ -96,7 +100,7 @@ proc incr_change_counter {} {
proc restore_file {} {
db close
- copy_file test.bu test.db
+ forcecopy test.bu test.db
sqlite3 db test.db
}
@@ -107,12 +111,12 @@ proc restore_file {} {
do_test corruptD-1.1.1 {
incr_change_counter
hexio_write test.db [expr 1024+1] FFFF
- catchsql { SELECT * FROM t1 }
+ catchsql { SELECT * FROM t1 ORDER BY rowid }
} {1 {database disk image is malformed}}
do_test corruptD-1.1.2 {
incr_change_counter
hexio_write test.db [expr 1024+1] [hexio_render_int32 1021]
- catchsql { SELECT * FROM t1 }
+ catchsql { SELECT * FROM t1 ORDER BY rowid }
} {1 {database disk image is malformed}}
#-------------------------------------------------------------------------
« no previous file with comments | « third_party/sqlite/src/test/corruptC.test ('k') | third_party/sqlite/src/test/corruptE.test » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698