sqlite/test/pagesize.test
drh 32fc1a5c51 Fix a bug in the pagesize test script. (CVS 1931)
FossilOrigin-Name: 1cf05bc607c88a3c0b81e82ee2d4fc761f08901a
2004-09-02 15:49:07 +00:00

57 lines
1.2 KiB
Plaintext

# 2004 September 2
#
# 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 for the page_size PRAGMA.
#
# $Id: pagesize.test,v 1.2 2004/09/02 15:49:08 drh Exp $
set testdir [file dirname $argv0]
source $testdir/tester.tcl
do_test pagesize-1.1 {
execsql {PRAGMA page_size}
} 1024
do_test pagesize-1.2 {
catch {execsql {EXPLAIN PRAGMA page_size}}
} 0
do_test pagesize-1.3 {
execsql {
CREATE TABLE t1(a);
PRAGMA page_size=2048;
PRAGMA page_size;
}
} 1024
do_test pagesize-1.4 {
db close
file delete -force test.db
sqlite3 db test.db
execsql {
PRAGMA page_size=2048;
CREATE TABLE t1(a);
PRAGMA page_size;
}
} 2048
do_test pagesize-1.5 {
db close
sqlite3 db test.db
execsql {
PRAGMA page_size
}
} 2048
do_test pagesize-1.6 {
file size test.db
} 4096
finish_test