diff options
author | dan miller | 2007-10-21 08:36:32 +0000 |
---|---|---|
committer | dan miller | 2007-10-21 08:36:32 +0000 |
commit | 2f8d7092bc2c9609fa98d6888106b96f38b22828 (patch) | |
tree | da6c37579258cc965b52a75aee6135fe44237698 /libraries/sqlite/unix/sqlite-3.5.1/test/async.test | |
parent | * Committing new PolicyManager based on an ACL system. (diff) | |
download | opensim-SC-2f8d7092bc2c9609fa98d6888106b96f38b22828.zip opensim-SC-2f8d7092bc2c9609fa98d6888106b96f38b22828.tar.gz opensim-SC-2f8d7092bc2c9609fa98d6888106b96f38b22828.tar.bz2 opensim-SC-2f8d7092bc2c9609fa98d6888106b96f38b22828.tar.xz |
libraries moved to opensim-libs, a new repository
Diffstat (limited to 'libraries/sqlite/unix/sqlite-3.5.1/test/async.test')
-rw-r--r-- | libraries/sqlite/unix/sqlite-3.5.1/test/async.test | 78 |
1 files changed, 0 insertions, 78 deletions
diff --git a/libraries/sqlite/unix/sqlite-3.5.1/test/async.test b/libraries/sqlite/unix/sqlite-3.5.1/test/async.test deleted file mode 100644 index 268a7ca..0000000 --- a/libraries/sqlite/unix/sqlite-3.5.1/test/async.test +++ /dev/null | |||
@@ -1,78 +0,0 @@ | |||
1 | # | ||
2 | # May you do good and not evil. | ||
3 | # May you find forgiveness for yourself and forgive others. | ||
4 | # May you share freely, never taking more than you give. | ||
5 | # | ||
6 | #*********************************************************************** | ||
7 | # This file runs all tests. | ||
8 | # | ||
9 | # $Id: async.test,v 1.12 2007/09/14 16:20:01 danielk1977 Exp $ | ||
10 | |||
11 | |||
12 | if {[catch {sqlite3async_enable}]} { | ||
13 | # The async logic is not built into this system | ||
14 | return | ||
15 | } | ||
16 | |||
17 | set testdir [file dirname $argv0] | ||
18 | source $testdir/tester.tcl | ||
19 | rename finish_test really_finish_test | ||
20 | proc finish_test {} { | ||
21 | catch {db close} | ||
22 | catch {db2 close} | ||
23 | catch {db3 close} | ||
24 | } | ||
25 | set ISQUICK 1 | ||
26 | |||
27 | set INCLUDE { | ||
28 | insert.test | ||
29 | insert2.test | ||
30 | insert3.test | ||
31 | lock.test | ||
32 | lock2.test | ||
33 | lock3.test | ||
34 | select1.test | ||
35 | select2.test | ||
36 | select3.test | ||
37 | select4.test | ||
38 | trans.test | ||
39 | } | ||
40 | |||
41 | # Enable asynchronous IO. | ||
42 | sqlite3async_enable 1 | ||
43 | |||
44 | rename do_test really_do_test | ||
45 | proc do_test {name args} { | ||
46 | uplevel really_do_test async_io-$name $args | ||
47 | sqlite3async_start | ||
48 | sqlite3async_halt idle | ||
49 | sqlite3async_wait | ||
50 | } | ||
51 | |||
52 | foreach testfile [lsort -dictionary [glob $testdir/*.test]] { | ||
53 | set tail [file tail $testfile] | ||
54 | if {[lsearch -exact $INCLUDE $tail]<0} continue | ||
55 | source $testfile | ||
56 | |||
57 | # Make sure everything is flushed through. This is because [source]ing | ||
58 | # the next test file will delete the database file on disk (using | ||
59 | # [file delete]). If the asynchronous backend still has the file | ||
60 | # open, it will become confused. | ||
61 | # | ||
62 | sqlite3async_halt idle | ||
63 | sqlite3async_start | ||
64 | sqlite3async_wait | ||
65 | } | ||
66 | |||
67 | # Flush the write-queue and disable asynchronous IO. This should ensure | ||
68 | # all allocated memory is cleaned up. | ||
69 | set sqlite3async_trace 1 | ||
70 | sqlite3async_halt idle | ||
71 | sqlite3async_start | ||
72 | sqlite3async_wait | ||
73 | sqlite3async_enable 0 | ||
74 | set sqlite3async_trace 0 | ||
75 | |||
76 | really_finish_test | ||
77 | rename really_do_test do_test | ||
78 | rename really_finish_test finish_test | ||