OLD | NEW |
1 # 2009 April 25 | 1 # 2009 April 25 |
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 #*********************************************************************** |
11 # | 11 # |
12 # $Id: async4.test,v 1.4 2009/06/05 17:09:12 drh Exp $ | 12 # $Id: async4.test,v 1.4 2009/06/05 17:09:12 drh Exp $ |
13 | 13 |
14 set testdir [file dirname $argv0] | 14 set testdir [file dirname $argv0] |
15 source $testdir/tester.tcl | 15 source $testdir/tester.tcl |
16 | 16 |
| 17 # Do not use a codec for tests in this file, as the database file is |
| 18 # manipulated directly using tcl scripts (using the [hexio_write] command). |
| 19 # |
| 20 do_not_use_codec |
| 21 |
17 # These tests only work for Tcl version 8.5 and later on Windows (for now) | 22 # These tests only work for Tcl version 8.5 and later on Windows (for now) |
18 # | 23 # |
19 if {$tcl_platform(platform)=="windows"} { | 24 if {$tcl_platform(platform)=="windows"} { |
20 scan $::tcl_version %f vx | 25 scan $::tcl_version %f vx |
21 if {$vx<8.5} { | 26 if {$vx<8.5} { |
22 finish_test | 27 finish_test |
23 return | 28 return |
24 } | 29 } |
25 } | 30 } |
26 | 31 |
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
87 } {} | 92 } {} |
88 do_test async4.1.14 { | 93 do_test async4.1.14 { |
89 execsql { | 94 execsql { |
90 CREATE INDEX i1 ON t2(a); | 95 CREATE INDEX i1 ON t2(a); |
91 CREATE INDEX i2 ON t1(a); | 96 CREATE INDEX i2 ON t1(a); |
92 } db2 | 97 } db2 |
93 } {} | 98 } {} |
94 do_test async4.1.15 { | 99 do_test async4.1.15 { |
95 sqlite3async_start | 100 sqlite3async_start |
96 sqlite3async_wait | 101 sqlite3async_wait |
| 102 hexio_write test.db 28 00000000 |
97 execsql { pragma integrity_check } db2 | 103 execsql { pragma integrity_check } db2 |
98 } {{*** in database main *** | 104 } {{*** in database main *** |
99 Page 5 is never used}} | 105 Page 5 is never used}} |
100 do_test async4.1.16 { | 106 do_test async4.1.16 { |
101 db close | 107 db close |
102 db2 close | 108 db2 close |
103 sqlite3async_start | 109 sqlite3async_start |
104 sqlite3async_wait | 110 sqlite3async_wait |
105 } {} | 111 } {} |
106 do_test async4.1.17 { | 112 do_test async4.1.17 { |
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
153 list [catch { sqlite3async_control delay -1 } msg] $msg | 159 list [catch { sqlite3async_control delay -1 } msg] $msg |
154 } {1 SQLITE_MISUSE} | 160 } {1 SQLITE_MISUSE} |
155 | 161 |
156 do_test async4.2.8 { | 162 do_test async4.2.8 { |
157 db close | 163 db close |
158 sqlite3async_start | 164 sqlite3async_start |
159 sqlite3async_wait | 165 sqlite3async_wait |
160 } {} | 166 } {} |
161 | 167 |
162 finish_test | 168 finish_test |
OLD | NEW |