Many hyperlinks are disabled.
Use anonymous login
to enable hyperlinks.
Overview
Comment: | Add new test file vacuummem.test. To test that any temporary memory used by VACUUM is freed as soon as the VACUUM has finished (not, for example, when sqlite3_close() is finally called). |
---|---|
Downloads: | Tarball | ZIP archive |
Timelines: | family | ancestors | descendants | both | trunk |
Files: | files | file ages | folders |
SHA1: |
1b1ad0b28c392ade4321734e9b022a54 |
User & Date: | dan 2016-07-21 16:43:54.563 |
Context
2016-07-21
| ||
18:02 | Add extra test cases to verify the fix in [64ca1a835]. (check-in: bf98a2de7e user: dan tags: trunk) | |
16:43 | Add new test file vacuummem.test. To test that any temporary memory used by VACUUM is freed as soon as the VACUUM has finished (not, for example, when sqlite3_close() is finally called). (check-in: 1b1ad0b28c user: dan tags: trunk) | |
2016-07-15
| ||
19:17 | Add the largely untested SQLITE_FTS5_NO_WITHOUT_ROWID compile time option to fts5. For building a dynamically loadable extension that does not use WITHOUT ROWID. (check-in: d0a1cf1c56 user: dan tags: trunk) | |
Changes
Added test/vacuummem.test.
> > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 | # 2005 February 15 # # 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. The # focus of this file is testing that the VACUUM statement correctly # frees any memory used for a temporary cache. # set testdir [file dirname $argv0] source $testdir/tester.tcl set testprefix vacuummem proc memory_used {} { set stat [sqlite3_status SQLITE_STATUS_MEMORY_USED 1] lindex $stat 1 } do_execsql_test 1.0 { PRAGMA cache_size = -2000; CREATE TABLE t1(a, b, c); WITH r(i) AS ( SELECT 1 UNION ALL SELECT i+1 FROM r WHERE i<100000 ) INSERT INTO t1 SELECT randomblob(100),randomblob(100),randomblob(100) FROM r; CREATE INDEX t1a ON t1(a); CREATE INDEX t1b ON t1(b); CREATE INDEX t1c ON t1(c); } do_test 1.1 { memory_used } {#/2300000/} do_execsql_test 1.2 VACUUM do_test 1.3 { memory_used } {#/2300000/} do_execsql_test 1.4 { SELECT count(*) FROM t1 WHERE +a IS NOT NULL } {100000} do_test 1.5 { memory_used } {#/2300000/} finish_test |