1
0
mirror of https://github.com/sqlite/sqlite.git synced 2025-12-24 14:17:58 +03:00

Add the "truncate" journal mode which commits transactions by truncating the

rollback journal file to zero length and not calling fsync(). (CVS 5745)

FossilOrigin-Name: 7c561f2e9264de676c1028943f6c3d06542fd802
This commit is contained in:
drh
2008-09-26 21:08:08 +00:00
parent 9e2d64b8d3
commit 04335886a1
7 changed files with 92 additions and 29 deletions

View File

@@ -9,7 +9,7 @@
#
#***********************************************************************
#
# $Id: permutations.test,v 1.30 2008/09/12 10:22:40 danielk1977 Exp $
# $Id: permutations.test,v 1.31 2008/09/26 21:08:08 drh Exp $
set testdir [file dirname $argv0]
source $testdir/tester.tcl
@@ -377,10 +377,23 @@ run_tests "exclusive" -description {
} -presql {
pragma locking_mode = 'exclusive'
} -include {
vacuum.test
rollback.test select1.test select2.test
malloc.test ioerr.test
}
# Run some tests in exclusive locking mode with truncated journals.
#
run_tests "exclusive-truncate" -description {
Run tests in exclusive locking mode and truncate journal mode.
} -presql {
pragma locking_mode = 'exclusive';
pragma journal_mode = TRUNCATE;
} -include {
delete.test delete2.test insert.test rollback.test select1.test
select2.test update.test malloc.test ioerr.test
}
# Run some tests in persistent journal mode.
#
run_tests "persistent_journal" -description {
@@ -392,6 +405,18 @@ run_tests "persistent_journal" -description {
select2.test trans.test update.test vacuum.test
}
# Run some tests in truncating journal mode.
#
run_tests "truncate_journal" -description {
Run tests in persistent-journal mode.
} -presql {
pragma journal_mode = truncate
} -include {
delete.test delete2.test insert.test rollback.test select1.test
select2.test trans.test update.test vacuum.test
malloc.test ioerr.test
}
# Run some error tests in persistent journal mode.
#
run_tests "persistent_journal_error" -description {