OLD | NEW |
1 # 2007 Oct 3 | 1 # 2007 Oct 3 |
2 # | 2 # |
3 # The author disclaims copyright to this source code. In place of | 3 # The author disclaims copyright to this source code. In place of |
4 # a legal notice, here is a blessing: | 4 # a legal notice, here is a blessing: |
5 # | 5 # |
6 # May you do good and not evil. | 6 # May you do good and not evil. |
7 # May you find forgiveness for yourself and forgive others. | 7 # May you find forgiveness for yourself and forgive others. |
8 # May you share freely, never taking more than you give. | 8 # May you share freely, never taking more than you give. |
9 # | 9 # |
10 #*********************************************************************** | 10 #*********************************************************************** |
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
42 execsql { | 42 execsql { |
43 DELETE FROM filler | 43 DELETE FROM filler |
44 WHERE rowid <= (SELECT MAX(rowid) FROM filler LIMIT 20) | 44 WHERE rowid <= (SELECT MAX(rowid) FROM filler LIMIT 20) |
45 } | 45 } |
46 } {} | 46 } {} |
47 integrity_check tkt2686-$i.3 | 47 integrity_check tkt2686-$i.3 |
48 catch {db eval COMMIT} | 48 catch {db eval COMMIT} |
49 } | 49 } |
50 | 50 |
51 db close | 51 db close |
52 file delete -force test.db test.db-journal | 52 forcedelete test.db test.db-journal |
53 sqlite3 db test.db | 53 sqlite3 db test.db |
54 | 54 |
55 db eval { | 55 db eval { |
56 PRAGMA page_size=1024; | 56 PRAGMA page_size=1024; |
57 PRAGMA max_page_count=50; | 57 PRAGMA max_page_count=50; |
58 PRAGMA auto_vacuum=1; | 58 PRAGMA auto_vacuum=1; |
59 CREATE TABLE filler (fill); | 59 CREATE TABLE filler (fill); |
60 } | 60 } |
61 for {set i 10000} {$i<12000} {incr i} { | 61 for {set i 10000} {$i<12000} {incr i} { |
62 do_test tkt2686-$i.1 { | 62 do_test tkt2686-$i.1 { |
63 db eval BEGIN | 63 db eval BEGIN |
64 set rc [catch { | 64 set rc [catch { |
65 while 1 { | 65 while 1 { |
66 db eval {INSERT INTO filler (fill) VALUES (randstr(1000, 10000)) } | 66 db eval {INSERT INTO filler (fill) VALUES (randstr(1000, 10000)) } |
67 } | 67 } |
68 } msg] | 68 } msg] |
69 lappend rc $msg | 69 lappend rc $msg |
70 } {1 {database or disk is full}} | 70 } {1 {database or disk is full}} |
71 do_test tkt2686-$i.2 { | 71 do_test tkt2686-$i.2 { |
72 execsql { | 72 execsql { |
73 DELETE FROM filler | 73 DELETE FROM filler |
74 WHERE rowid <= (SELECT MAX(rowid) FROM filler LIMIT 20) | 74 WHERE rowid <= (SELECT MAX(rowid) FROM filler LIMIT 20) |
75 } | 75 } |
76 } {} | 76 } {} |
77 integrity_check tkt2686-$i.3 | 77 integrity_check tkt2686-$i.3 |
78 catch {db eval COMMIT} | 78 catch {db eval COMMIT} |
79 } | 79 } |
80 | 80 |
81 finish_test | 81 finish_test |
OLD | NEW |