AryaWu/sqlite
0
1# 2008 Jan 212#3# The author disclaims copyright to this source code. In place of4# a legal notice, here is a blessing:5#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.9#10#***********************************************************************11# This file implements regression tests for SQLite library.12#13# This file implements tests for the sqlite3_exec interface14#15# $Id: exec.test,v 1.1 2008/01/21 16:22:46 drh Exp $16 17set testdir [file dirname $argv0]18source $testdir/tester.tcl19 20do_test exec-1.1 {21 execsql {22 CREATE TABLE t1(a,b);23 INSERT INTO t1 VALUES(1,2);24 SELECT * FROM t1;25 }26} {1 2}27do_test exec-1.2 {28 sqlite3_exec db {/* comment */;;; SELECT * FROM t1; /* comment */}29} {0 {a b 1 2}}30do_test exec-1.3 {31 sqlite3 db2 test.db32 db2 eval {CREATE TABLE t2(x, y);}33 db2 close34 sqlite3_exec db {SELECT * FROM t1}35} {0 {a b 1 2}}36 37finish_test38 