Coverage improvements for main.c. (CVS 3023)

FossilOrigin-Name: 50964ef9b0159bfdcd7eae88b0806957cab184dc
This commit is contained in:
danielk1977
2006-01-24 11:30:27 +00:00
parent 161fb79619
commit 7246f5b9cb
4 changed files with 31 additions and 10 deletions
+6 -1
View File
@@ -9,7 +9,7 @@
#
#***********************************************************************
#
# $Id: shared2.test,v 1.1 2006/01/19 08:43:32 danielk1977 Exp $
# $Id: shared2.test,v 1.2 2006/01/24 11:30:27 danielk1977 Exp $
set testdir [file dirname $argv0]
source $testdir/tester.tcl
@@ -81,5 +81,10 @@ do_test shared2-1.3 {
db1 close
db2 close
do_test shared2-1.4 {
sqlite3_thread_cleanup
sqlite3_enable_shared_cache 1
} {0}
sqlite3_enable_shared_cache $::enable_shared_cache
finish_test
+17 -1
View File
@@ -13,7 +13,7 @@
# cache context. What happens to connection B if one connection A encounters
# an IO-error whilst reading or writing the file-system?
#
# $Id: shared_err.test,v 1.7 2006/01/24 00:15:16 drh Exp $
# $Id: shared_err.test,v 1.8 2006/01/24 11:30:27 danielk1977 Exp $
proc skip {args} {}
@@ -333,6 +333,22 @@ do_malloc_test 5 -tclbody {
catch {dbY close}
}
do_malloc_test 6 -tclbody {
catch {db close}
sqlite3_thread_cleanup
sqlite3_enable_shared_cache 0
} -cleanup {
sqlite3_enable_shared_cache 1
}
do_test shared_misuse-7.1 {
sqlite3 db test.db
catch {
sqlite3_enable_shared_cache 0
} msg
set msg
} {library routine called out of sequence}
catch {db close}
sqlite3_enable_shared_cache $::enable_shared_cache
finish_test