| OLD | NEW |
| 1 # 2006 October 19 | 1 # 2006 October 19 |
| 2 # | 2 # |
| 3 # The author disclaims copyright to this source code. | 3 # The author disclaims copyright to this source code. |
| 4 # | 4 # |
| 5 #************************************************************************* | 5 #************************************************************************* |
| 6 # This file implements regression tests for SQLite library. The | 6 # This file implements regression tests for SQLite library. The |
| 7 # focus of this script is testing deletions in the FTS3 module. | 7 # focus of this script is testing deletions in the FTS3 module. |
| 8 # | 8 # |
| 9 # $Id: fts3ae.test,v 1.1 2007/08/20 17:38:42 shess Exp $ | 9 # $Id: fts3ae.test,v 1.1 2007/08/20 17:38:42 shess Exp $ |
| 10 # | 10 # |
| (...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 51 INSERT INTO t1 (rowid, content) VALUES(18, 'two five'); | 51 INSERT INTO t1 (rowid, content) VALUES(18, 'two five'); |
| 52 INSERT INTO t1 (rowid, content) VALUES(19, 'one two five'); | 52 INSERT INTO t1 (rowid, content) VALUES(19, 'one two five'); |
| 53 DELETE FROM t1 WHERE rowid = 16; | 53 DELETE FROM t1 WHERE rowid = 16; |
| 54 INSERT INTO t1 (rowid, content) VALUES(20, 'three five'); | 54 INSERT INTO t1 (rowid, content) VALUES(20, 'three five'); |
| 55 INSERT INTO t1 (rowid, content) VALUES(21, 'one three five'); | 55 INSERT INTO t1 (rowid, content) VALUES(21, 'one three five'); |
| 56 INSERT INTO t1 (rowid, content) VALUES(22, 'two three five'); | 56 INSERT INTO t1 (rowid, content) VALUES(22, 'two three five'); |
| 57 DELETE FROM t1 WHERE rowid = 19; | 57 DELETE FROM t1 WHERE rowid = 19; |
| 58 DELETE FROM t1 WHERE rowid = 22; | 58 DELETE FROM t1 WHERE rowid = 22; |
| 59 } | 59 } |
| 60 | 60 |
| 61 do_test fts3af-1.1 { | 61 do_test fts3ae-1.1 { |
| 62 execsql {SELECT COUNT(*) FROM t1} | 62 execsql {SELECT COUNT(*) FROM t1} |
| 63 } {14} | 63 } {14} |
| 64 | 64 |
| 65 do_test fts3ae-2.1 { | 65 do_test fts3ae-2.1 { |
| 66 execsql {SELECT rowid FROM t1 WHERE content MATCH 'one'} | 66 execsql {SELECT rowid FROM t1 WHERE content MATCH 'one'} |
| 67 } {3 5 9 11 15 17 21} | 67 } {3 5 9 11 15 17 21} |
| 68 | 68 |
| 69 do_test fts3ae-2.2 { | 69 do_test fts3ae-2.2 { |
| 70 execsql {SELECT rowid FROM t1 WHERE content MATCH 'two'} | 70 execsql {SELECT rowid FROM t1 WHERE content MATCH 'two'} |
| 71 } {2 3 6 11 14 15 18} | 71 } {2 3 6 11 14 15 18} |
| 72 | 72 |
| 73 do_test fts3ae-2.3 { | 73 do_test fts3ae-2.3 { |
| 74 execsql {SELECT rowid FROM t1 WHERE content MATCH 'three'} | 74 execsql {SELECT rowid FROM t1 WHERE content MATCH 'three'} |
| 75 } {5 6 12 14 15 20 21} | 75 } {5 6 12 14 15 20 21} |
| 76 | 76 |
| 77 do_test fts3ae-2.4 { | 77 do_test fts3ae-2.4 { |
| 78 execsql {SELECT rowid FROM t1 WHERE content MATCH 'four'} | 78 execsql {SELECT rowid FROM t1 WHERE content MATCH 'four'} |
| 79 } {8 9 11 12 14 15} | 79 } {8 9 11 12 14 15} |
| 80 | 80 |
| 81 do_test fts3ae-2.5 { | 81 do_test fts3ae-2.5 { |
| 82 execsql {SELECT rowid FROM t1 WHERE content MATCH 'five'} | 82 execsql {SELECT rowid FROM t1 WHERE content MATCH 'five'} |
| 83 } {17 18 20 21} | 83 } {17 18 20 21} |
| 84 | 84 |
| 85 finish_test | 85 finish_test |
| OLD | NEW |