From f20d127e834becb63b56003f41c130bf76f4d522 Mon Sep 17 00:00:00 2001 From: Stephen Lombardo Date: Wed, 22 Apr 2009 11:20:54 -0400 Subject: [PATCH] expanded test for making changes to ATTACHED databases --- test/crypto.test | 20 +++++++++++++++++++- 1 file changed, 19 insertions(+), 1 deletion(-) diff --git a/test/crypto.test b/test/crypto.test index c919e12..cf5573c 100644 --- a/test/crypto.test +++ b/test/crypto.test @@ -235,8 +235,26 @@ do_test codec-1.12 { ATTACH 'test3.db' AS db3; SELECT count(*) FROM db3.t3; } db2 - + } {25000 15000} +do_test codec-1.13 { + execsql { + BEGIN; + } db2 + + for {set i 1} {$i<=10000} {incr i} { + set r [expr {int(rand()*500000)}] + execsql "INSERT INTO t2 VALUES($i,$r);" db2 + execsql "INSERT INTO db3.t3 VALUES($i,$r);" db2 + } + + execsql { + COMMIT; + SELECT count(*) FROM t2; + SELECT count(*) FROM db3.t3; + DETACH db3; + } db2 +} {35000 25000} finish_test