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

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

Issue 1610963002: Import SQLite 3.10.2. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 11 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
« no previous file with comments | « third_party/sqlite/src/test/fts3atoken.test ('k') | third_party/sqlite/src/test/fts3d.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 # 2011 April 25 1 # 2011 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 #*************************************************************************
(...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after
79 3 "INSERT OR FAIL $T1" 0 1 {{a b c d} {e f g h} {i j k l}} 79 3 "INSERT OR FAIL $T1" 0 1 {{a b c d} {e f g h} {i j k l}}
80 4 "INSERT OR IGNORE $T1" 0 0 {{a b c d} {e f g h} {i j k l}} 80 4 "INSERT OR IGNORE $T1" 0 0 {{a b c d} {e f g h} {i j k l}}
81 5 "INSERT OR REPLACE $T1" 0 0 {x {e f g h} {i j k l}} 81 5 "INSERT OR REPLACE $T1" 0 0 {x {e f g h} {i j k l}}
82 82
83 6 "INSERT OR ROLLBACK $T2" 1 1 {{a b c d} {e f g h}} 83 6 "INSERT OR ROLLBACK $T2" 1 1 {{a b c d} {e f g h}}
84 7 "INSERT OR ABORT $T2" 1 1 {{a b c d} {e f g h} {i j k l}} 84 7 "INSERT OR ABORT $T2" 1 1 {{a b c d} {e f g h} {i j k l}}
85 8 "INSERT OR FAIL $T2" 1 1 {{a b c d} {e f g h} {i j k l} z} 85 8 "INSERT OR FAIL $T2" 1 1 {{a b c d} {e f g h} {i j k l} z}
86 9 "INSERT OR IGNORE $T2" 1 0 {{a b c d} {e f g h} {i j k l} z} 86 9 "INSERT OR IGNORE $T2" 1 0 {{a b c d} {e f g h} {i j k l} z}
87 10 "INSERT OR REPLACE $T2" 1 0 {{a b c d} y {i j k l} z} 87 10 "INSERT OR REPLACE $T2" 1 0 {{a b c d} y {i j k l} z}
88 88
89 11 "UPDATE OR ROLLBACK $T3" 1 1 {{a b c d} {e f g h}} 89 11 "UPDATE OR ROLLBACK $T3" 0 1 {{a b c d} {e f g h}}
90 12 "UPDATE OR ABORT $T3" 1 1 {{a b c d} {e f g h} {i j k l}} 90 12 "UPDATE OR ABORT $T3" 0 1 {{a b c d} {e f g h} {i j k l}}
91 13 "UPDATE OR FAIL $T3" 1 1 {{a b c d} {e f g h} {i j k l}} 91 13 "UPDATE OR FAIL $T3" 0 1 {{a b c d} {e f g h} {i j k l}}
92 14 "UPDATE OR IGNORE $T3" 1 0 {{a b c d} {e f g h} {i j k l}} 92 14 "UPDATE OR IGNORE $T3" 0 0 {{a b c d} {e f g h} {i j k l}}
93 15 "UPDATE OR REPLACE $T3" 1 0 {{a b c d} {i j k l}} 93 15 "UPDATE OR REPLACE $T3" 0 0 {{a b c d} {i j k l}}
94 94
95 16 "UPDATE OR ROLLBACK $T4" 1 1 {{a b c d} {e f g h}} 95 16 "UPDATE OR ROLLBACK $T4" 1 1 {{a b c d} {e f g h}}
96 17 "UPDATE OR ABORT $T4" 1 1 {{a b c d} {e f g h} {i j k l}} 96 17 "UPDATE OR ABORT $T4" 1 1 {{a b c d} {e f g h} {i j k l}}
97 18 "UPDATE OR FAIL $T4" 1 1 {{e f g h} {i j k l} {a b c d}} 97 18 "UPDATE OR FAIL $T4" 1 1 {{e f g h} {i j k l} {a b c d}}
98 19 "UPDATE OR IGNORE $T4" 1 0 {{e f g h} {i j k l} {a b c d}} 98 19 "UPDATE OR IGNORE $T4" 1 0 {{e f g h} {i j k l} {a b c d}}
99 20 "UPDATE OR REPLACE $T4" 1 0 {{e f g h} {a b c d}} 99 20 "UPDATE OR REPLACE $T4" 1 0 {{e f g h} {a b c d}}
100 }] { 100 }] {
101 db_restore_and_reopen 101 db_restore_and_reopen
102 execsql { 102 execsql {
103 BEGIN; 103 BEGIN;
(...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after
171 REPLACE INTO t3(docid, content) VALUES (NULL, 'one two three four'); 171 REPLACE INTO t3(docid, content) VALUES (NULL, 'one two three four');
172 REPLACE INTO t3(docid, content) VALUES (NULL, 'one two three four five six'); 172 REPLACE INTO t3(docid, content) VALUES (NULL, 'one two three four five six');
173 SELECT docid FROM t3; 173 SELECT docid FROM t3;
174 } {3 4 5} 174 } {3 4 5}
175 175
176 do_execsql_test 3.8 { 176 do_execsql_test 3.8 {
177 UPDATE OR REPLACE t3 SET docid = 5, content='three four' WHERE docid = 4; 177 UPDATE OR REPLACE t3 SET docid = 5, content='three four' WHERE docid = 4;
178 SELECT quote(matchinfo(t3, 'na')) FROM t3 WHERE t3 MATCH 'one' 178 SELECT quote(matchinfo(t3, 'na')) FROM t3 WHERE t3 MATCH 'one'
179 } {X'0200000002000000'} 179 } {X'0200000002000000'}
180 180
181 #-------------------------------------------------------------------------
182 # Test that the xSavepoint is invoked correctly if the first write
183 # operation within a transaction is to a virtual table.
184 #
185 do_catchsql_test 4.1.1 {
186 CREATE VIRTUAL TABLE t0 USING fts4;
187 BEGIN;
188 INSERT INTO t0(rowid, content) SELECT
189 1, 'abc' UNION ALL SELECT
190 2, 'def' UNION ALL SELECT
191 1, 'ghi';
192 } {1 {constraint failed}}
193 do_execsql_test 4.1.2 {
194 COMMIT;
195 }
196 do_execsql_test 4.1.3 {
197 SELECT * FROM t0 WHERE t0 MATCH 'abc';
198 INSERT INTO t0(t0) VALUES('integrity-check');
199 } {}
200
201 do_execsql_test 4.2.1 {
202 CREATE VIRTUAL TABLE t01 USING fts4;
203 BEGIN;
204 SAVEPOINT abc;
205 INSERT INTO t01 VALUES('a b c');
206 ROLLBACK TO abc;
207 COMMIT;
208 }
209 do_execsql_test 4.2.2 {
210 SELECT * FROM t01 WHERE t01 MATCH 'b';
211 INSERT INTO t01(t01) VALUES('integrity-check');
212 } {}
213
181 finish_test 214 finish_test
215
OLDNEW
« no previous file with comments | « third_party/sqlite/src/test/fts3atoken.test ('k') | third_party/sqlite/src/test/fts3d.test » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698