1
0
mirror of https://github.com/sqlite/sqlite.git synced 2025-07-29 08:01:23 +03:00

Fix a bug in jrnlTruncate(). And other coverage improvements. (CVS 4367)

FossilOrigin-Name: 02b751fb9dbc683b1b77a2ed3cdeb4190f7339e0
This commit is contained in:
danielk1977
2007-09-01 18:24:55 +00:00
parent 4ff7fa0d67
commit 880c15beb9
11 changed files with 100 additions and 44 deletions

View File

@ -13,7 +13,7 @@
# IO traffic generated by SQLite (making sure SQLite is not writing out
# more database pages than it has to, stuff like that).
#
# $Id: io.test,v 1.7 2007/08/29 17:59:42 drh Exp $
# $Id: io.test,v 1.8 2007/09/01 18:24:55 danielk1977 Exp $
set testdir [file dirname $argv0]
source $testdir/tester.tcl
@ -110,7 +110,6 @@ do_test io-1.5 {
nWrite db
} {3}
ifcapable atomicwrite {
#----------------------------------------------------------------------
@ -332,6 +331,30 @@ do_test io-2.10.2 {
do_test io-2.10.3 {
execsql { ROLLBACK }
} {}
do_test io-2.11.0 {
execsql {
PRAGMA locking_mode = exclusive;
PRAGMA locking_mode;
}
} {exclusive exclusive}
breakpoint
do_test io-2.11.1 {
execsql {
INSERT INTO abc VALUES(11, 12);
}
file exists test.db-journal
} {0}
breakpoint
do_test io-2.11.2 {
execsql {
PRAGMA locking_mode = normal;
INSERT INTO abc VALUES(13, 14);
}
file exists test.db-journal
} {0}
} ;# /* ifcapable atomicwrite */
#----------------------------------------------------------------------