Fix a problem causing the recovery extension to use excessive memory and CPU time...
[sqlite.git] / test / fts4rename.test
blob5571ea7b1534c30a48c1668b3cdb7409face561f
1 # 2019 April 30
3 # The author disclaims copyright to this source code.  In place of
4 # a legal notice, here is a blessing:
6 #    May you do good and not evil.
7 #    May you find forgiveness for yourself and forgive others.
8 #    May you share freely, never taking more than you give.
10 #*************************************************************************
13 set testdir [file dirname $argv0]
14 source $testdir/tester.tcl
15 source $testdir/fts3_common.tcl
16 set ::testprefix fts4rename
18 # If SQLITE_ENABLE_FTS3 is defined, omit this file.
19 ifcapable !fts3 {
20   finish_test
21   return
24 do_execsql_test 1.0 {
25   CREATE VIRTUAL TABLE temp.t1 USING fts3(a);
26   BEGIN;
27   CREATE TABLE t2(x);
28 } {}
30 do_catchsql_test 1.1 {
31   ALTER TABLE t1_content RENAME c0a TO docid;
32 } {1 {error in table t1_content after rename: duplicate column name: docid}}
34 do_catchsql_test 1.2 {
35   UPDATE t1 SET Col0 = 1 ;
36 } {1 {no such column: Col0}}
38 do_catchsql_test 1.3 {
39   ROLLBACK;
40   DROP TABLE t1;
41 } {0 {}}
43 finish_test