3 # The author disclaims copyright to this source code. In place of
4 # a legal notice, here is a blessing:
6 # May you do good and not evil.
7 # May you find forgiveness for yourself and forgive others.
8 # May you share freely, never taking more than you give.
10 #***********************************************************************
12 # This file contains tests for the RBU module. More specifically, it
13 # contains tests to ensure that the sqlite3rbu_vacuum() API works as
17 source [file join [file dirname [info script]] rbu_common.tcl]
18 if_no_rbu_support { finish_test ; return }
19 set testprefix rbuvacuum3
22 CREATE TABLE t1(a PRIMARY KEY, b, c);
23 CREATE INDEX i1b ON t1(b);
24 CREATE INDEX i1c ON t1(c);
27 VALUES(1) UNION ALL SELECT i+1 FROM s WHERE i<100
29 INSERT INTO t1 SELECT i, randomblob(100), randomblob(100) FROM s;
34 sqlite3rbu_vacuum rbu test.db state.db
37 if {$rc!="SQLITE_OK"} break
44 sqlite3rbu_vacuum rbu test.db state.db
47 if {$rc!="SQLITE_OK"} break
55 sqlite3rbu_vacuum rbu test.db state.db
57 if {$rc!="SQLITE_OK"} break