Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(248)

Side by Side Diff: third_party/sqlite/src/test/shared2.test

Issue 6990047: Import SQLite 3.7.6.3. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « third_party/sqlite/src/test/shared.test ('k') | third_party/sqlite/src/test/shared3.test » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 # 2005 January 19 1 # 2005 January 19
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: shared2.test,v 1.8 2009/06/05 17:09:12 drh Exp $ 12 # $Id: shared2.test,v 1.8 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 source $testdir/lock_common.tcl
17 source $testdir/malloc_common.tcl
16 db close 18 db close
17 19
18 ifcapable !shared_cache { 20 ifcapable !shared_cache {
19 finish_test 21 finish_test
20 return 22 return
21 } 23 }
22 set ::enable_shared_cache [sqlite3_enable_shared_cache 1] 24 set ::enable_shared_cache [sqlite3_enable_shared_cache 1]
23 25
24 # Test that if we delete all rows from a table any read-uncommitted 26 # Test that if we delete all rows from a table any read-uncommitted
25 # cursors are correctly invalidated. Test on both table and index btrees. 27 # cursors are correctly invalidated. Test on both table and index btrees.
(...skipping 133 matching lines...) Expand 10 before | Expand all | Expand 10 after
159 execsql { CREATE TABLE t2(a, b, c) } 161 execsql { CREATE TABLE t2(a, b, c) }
160 162
161 # The following statement would crash when attempting to sqlite3_free() 163 # The following statement would crash when attempting to sqlite3_free()
162 # a pointer allocated from a lookaside buffer. 164 # a pointer allocated from a lookaside buffer.
163 execsql { CREATE INDEX i1 ON t2(a) } db2 165 execsql { CREATE INDEX i1 ON t2(a) } db2
164 } {} 166 } {}
165 167
166 db close 168 db close
167 db2 close 169 db2 close
168 170
171 # The following test verifies that shared-cache mode does not automatically
172 # turn on exclusive-locking mode for some reason.
173 do_multiclient_test {tn} {
174 sql1 { CREATE TABLE t1(a, b) }
175 sql2 { CREATE TABLE t2(a, b) }
176 do_test shared2-6.$tn.1 { sql1 { SELECT * FROM t2 } } {}
177 do_test shared2-6.$tn.2 { sql2 { SELECT * FROM t1 } } {}
178 }
179
169 sqlite3_enable_shared_cache $::enable_shared_cache 180 sqlite3_enable_shared_cache $::enable_shared_cache
170 finish_test 181 finish_test
OLDNEW
« no previous file with comments | « third_party/sqlite/src/test/shared.test ('k') | third_party/sqlite/src/test/shared3.test » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698