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

Side by Side Diff: third_party/sqlite/src/test/walmode.test

Issue 901033002: Import SQLite 3.8.7.4. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Chromium changes to support SQLite 3.8.7.4. 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 unified diff | Download patch
OLDNEW
1 # 2010 April 19 1 # 2010 April 19
2 # 2 #
3 # The author disclaims copyright to this source code. In place of 3 # The author disclaims copyright to this source code. In place of
4 # a legal notice, here is a blessing: 4 # a legal notice, here is a blessing:
5 # 5 #
6 # May you do good and not evil. 6 # May you do good and not evil.
7 # May you find forgiveness for yourself and forgive others. 7 # May you find forgiveness for yourself and forgive others.
8 # May you share freely, never taking more than you give. 8 # May you share freely, never taking more than you give.
9 # 9 #
10 #*********************************************************************** 10 #***********************************************************************
(...skipping 277 matching lines...) Expand 10 before | Expand all | Expand 10 after
288 } [list $mode wal] 288 } [list $mode wal]
289 } 289 }
290 db close 290 db close
291 291
292 #------------------------------------------------------------------------- 292 #-------------------------------------------------------------------------
293 # Test the effect of a "PRAGMA journal_mode" command being the first 293 # Test the effect of a "PRAGMA journal_mode" command being the first
294 # thing executed by a new connection. This means that the schema is not 294 # thing executed by a new connection. This means that the schema is not
295 # loaded when sqlite3_prepare_v2() is called to compile the statement. 295 # loaded when sqlite3_prepare_v2() is called to compile the statement.
296 # 296 #
297 do_test walmode-7.0 { 297 do_test walmode-7.0 {
298 file delete -force test.db 298 forcedelete test.db
299 sqlite3 db test.db 299 sqlite3 db test.db
300 execsql { 300 execsql {
301 PRAGMA journal_mode = WAL; 301 PRAGMA journal_mode = WAL;
302 CREATE TABLE t1(a, b); 302 CREATE TABLE t1(a, b);
303 } 303 }
304 } {wal} 304 } {wal}
305 foreach {tn sql result} { 305 foreach {tn sql result} {
306 1 "PRAGMA journal_mode" wal 306 1 "PRAGMA journal_mode" wal
307 2 "PRAGMA main.journal_mode" wal 307 2 "PRAGMA main.journal_mode" wal
308 3 "PRAGMA journal_mode = delete" delete 308 3 "PRAGMA journal_mode = delete" delete
(...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after
378 db2 close 378 db2 close
379 379
380 do_execsql_test walmode-8.20 { PRAGMA journal_mode = DELETE } {delete} 380 do_execsql_test walmode-8.20 { PRAGMA journal_mode = DELETE } {delete}
381 do_execsql_test walmode-8.21 { PRAGMA main.journal_mode } {delete} 381 do_execsql_test walmode-8.21 { PRAGMA main.journal_mode } {delete}
382 do_execsql_test walmode-8.22 { PRAGMA two.journal_mode } {delete} 382 do_execsql_test walmode-8.22 { PRAGMA two.journal_mode } {delete}
383 do_execsql_test walmode-8.21 { PRAGMA journal_mode = WAL } {wal} 383 do_execsql_test walmode-8.21 { PRAGMA journal_mode = WAL } {wal}
384 do_execsql_test walmode-8.21 { PRAGMA main.journal_mode } {wal} 384 do_execsql_test walmode-8.21 { PRAGMA main.journal_mode } {wal}
385 do_execsql_test walmode-8.22 { PRAGMA two.journal_mode } {wal} 385 do_execsql_test walmode-8.22 { PRAGMA two.journal_mode } {wal}
386 386
387 finish_test 387 finish_test
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698