| OLD | NEW |
| 1 # 2008 June 28 | 1 # 2008 June 28 |
| 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 103 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 114 INSERT INTO t1 VALUES(1, 2); | 114 INSERT INTO t1 VALUES(1, 2); |
| 115 } | 115 } |
| 116 } {} | 116 } {} |
| 117 | 117 |
| 118 # Make sure we are not accidentally using the dotfile locking scheme. | 118 # Make sure we are not accidentally using the dotfile locking scheme. |
| 119 do_test lock5-flock.2 { | 119 do_test lock5-flock.2 { |
| 120 file exists test.db.lock | 120 file exists test.db.lock |
| 121 } {0} | 121 } {0} |
| 122 | 122 |
| 123 do_test lock5-flock.3 { | 123 do_test lock5-flock.3 { |
| 124 sqlite3 db2 test.db -vfs unix-flock | 124 catch { sqlite3 db2 test.db -vfs unix-flock } |
| 125 catchsql { SELECT * FROM t1 } db2 | 125 catchsql { SELECT * FROM t1 } db2 |
| 126 } {1 {database is locked}} | 126 } {1 {database is locked}} |
| 127 | 127 |
| 128 do_test lock5-flock.4 { | 128 do_test lock5-flock.4 { |
| 129 execsql COMMIT | 129 execsql COMMIT |
| 130 catchsql { SELECT * FROM t1 } db2 | 130 catchsql { SELECT * FROM t1 } db2 |
| 131 } {0 {1 2}} | 131 } {0 {1 2}} |
| 132 | 132 |
| 133 do_test lock5-flock.5 { | 133 do_test lock5-flock.5 { |
| 134 execsql BEGIN | 134 execsql BEGIN |
| (...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 186 do_test lock5-flock.X { | 186 do_test lock5-flock.X { |
| 187 db close | 187 db close |
| 188 db2 close | 188 db2 close |
| 189 } {} | 189 } {} |
| 190 | 190 |
| 191 ifcapable lock_proxy_pragmas { | 191 ifcapable lock_proxy_pragmas { |
| 192 set env(SQLITE_FORCE_PROXY_LOCKING) $::using_proxy | 192 set env(SQLITE_FORCE_PROXY_LOCKING) $::using_proxy |
| 193 } | 193 } |
| 194 | 194 |
| 195 finish_test | 195 finish_test |
| OLD | NEW |