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

Unified Diff: third_party/sqlite/sqlite-src-3080704/test/trigger7.test

Issue 2363173002: [sqlite] Remove obsolete reference version 3.8.7.4. (Closed)
Patch Set: Created 4 years, 3 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 side-by-side diff with in-line comments
Download patch
Index: third_party/sqlite/sqlite-src-3080704/test/trigger7.test
diff --git a/third_party/sqlite/sqlite-src-3080704/test/trigger7.test b/third_party/sqlite/sqlite-src-3080704/test/trigger7.test
deleted file mode 100644
index 8fde2004f87bd0c283b3a1e3ee25d1ac1fbb3c4d..0000000000000000000000000000000000000000
--- a/third_party/sqlite/sqlite-src-3080704/test/trigger7.test
+++ /dev/null
@@ -1,119 +0,0 @@
-# 2005 August 18
-#
-# The author disclaims copyright to this source code. In place of
-# a legal notice, here is a blessing:
-#
-# May you do good and not evil.
-# May you find forgiveness for yourself and forgive others.
-# May you share freely, never taking more than you give.
-#
-#***********************************************************************
-# This file implements regression tests for SQLite library.
-#
-# This file implements tests to increase coverage of trigger.c.
-#
-# $Id: trigger7.test,v 1.3 2008/08/11 18:44:58 drh Exp $
-
-set testdir [file dirname $argv0]
-source $testdir/tester.tcl
-ifcapable {!trigger} {
- finish_test
- return
-}
-
-
-# Error messages resulting from qualified trigger names.
-#
-do_test trigger7-1.1 {
- execsql {
- CREATE TABLE t1(x, y);
- }
- catchsql {
- CREATE TEMP TRIGGER main.r1 AFTER INSERT ON t1 BEGIN
- SELECT 'no nothing';
- END
- }
-} {1 {temporary trigger may not have qualified name}}
-do_test trigger7-1.2 {
- catchsql {
- CREATE TRIGGER not_a_db.r1 AFTER INSERT ON t1 BEGIN
- SELECT 'no nothing';
- END
- }
-} {1 {unknown database not_a_db}}
-
-
-# When the UPDATE OF syntax is used, no code is generated for triggers
-# that do not match the update columns.
-#
-ifcapable explain {
- do_test trigger7-2.1 {
- execsql {
- CREATE TRIGGER r1 AFTER UPDATE OF x ON t1 BEGIN
- SELECT '___update_t1.x___';
- END;
- CREATE TRIGGER r2 AFTER UPDATE OF y ON t1 BEGIN
- SELECT '___update_t1.y___';
- END;
- }
- set txt [db eval {EXPLAIN UPDATE t1 SET x=5}]
- string match *___update_t1.x___* $txt
- } 1
- do_test trigger7-2.2 {
- set txt [db eval {EXPLAIN UPDATE t1 SET x=5}]
- string match *___update_t1.y___* $txt
- } 0
- do_test trigger7-2.3 {
- set txt [db eval {EXPLAIN UPDATE t1 SET y=5}]
- string match *___update_t1.x___* $txt
- } 0
- do_test trigger7-2.4 {
- set txt [db eval {EXPLAIN UPDATE t1 SET y=5}]
- string match *___update_t1.y___* $txt
- } 1
- do_test trigger7-2.5 {
- set txt [db eval {EXPLAIN UPDATE t1 SET rowid=5}]
- string match *___update_t1.x___* $txt
- } 0
- do_test trigger7-2.6 {
- set txt [db eval {EXPLAIN UPDATE t1 SET rowid=5}]
- string match *___update_t1.x___* $txt
- } 0
-}
-
-# Test the ability to create many triggers on the same table, then
-# selectively drop those triggers.
-#
-do_test trigger7-3.1 {
- execsql {
- CREATE TABLE t2(x,y,z);
- CREATE TRIGGER t2r1 AFTER INSERT ON t2 BEGIN SELECT 1; END;
- CREATE TRIGGER t2r2 BEFORE INSERT ON t2 BEGIN SELECT 1; END;
- CREATE TRIGGER t2r3 AFTER UPDATE ON t2 BEGIN SELECT 1; END;
- CREATE TRIGGER t2r4 BEFORE UPDATE ON t2 BEGIN SELECT 1; END;
- CREATE TRIGGER t2r5 AFTER DELETE ON t2 BEGIN SELECT 1; END;
- CREATE TRIGGER t2r6 BEFORE DELETE ON t2 BEGIN SELECT 1; END;
- CREATE TRIGGER t2r7 AFTER INSERT ON t2 BEGIN SELECT 1; END;
- CREATE TRIGGER t2r8 BEFORE INSERT ON t2 BEGIN SELECT 1; END;
- CREATE TRIGGER t2r9 AFTER UPDATE ON t2 BEGIN SELECT 1; END;
- CREATE TRIGGER t2r10 BEFORE UPDATE ON t2 BEGIN SELECT 1; END;
- CREATE TRIGGER t2r11 AFTER DELETE ON t2 BEGIN SELECT 1; END;
- CREATE TRIGGER t2r12 BEFORE DELETE ON t2 BEGIN SELECT 1; END;
- DROP TRIGGER t2r6;
- }
-} {}
-
-# This test corrupts the database file so it must be the last test
-# in the series.
-#
-do_test trigger7-99.1 {
- execsql {
- PRAGMA writable_schema=on;
- UPDATE sqlite_master SET sql='nonsense';
- }
- db close
- catch { sqlite3 db test.db }
- catchsql { DROP TRIGGER t2r5 }
-} {1 {malformed database schema (t2r12) - near "nonsense": syntax error}}
-
-finish_test
« no previous file with comments | « third_party/sqlite/sqlite-src-3080704/test/trigger6.test ('k') | third_party/sqlite/sqlite-src-3080704/test/trigger8.test » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698