SQLite

Check-in [8beae3ff8c]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Flush the TCL statement cache before each lock_status pragma. (CVS 2270)
Downloads: Tarball | ZIP archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1: 8beae3ff8cbe23f20eb242187edbdb72133a24c3
User & Date: drh 2005-01-24 01:38:33.000
Context
2005-01-24
10:25
Modifications and bugfixes so that the test suite passes with the TCL statement cache turned on. (CVS 2271) (check-in: d5233e0747 user: danielk1977 tags: trunk)
01:38
Flush the TCL statement cache before each lock_status pragma. (CVS 2270) (check-in: 8beae3ff8c user: drh tags: trunk)
00:28
Change the TCL interface so that it can cache VMs and reuse them without recompiling. But for now leave the cache turned off by default. (CVS 2269) (check-in: 8db6bfef52 user: drh tags: trunk)
Changes
Unified Diff Ignore Whitespace Patch
Changes to test/attach2.test.
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
#    May you share freely, never taking more than you give.
#
#***********************************************************************
# This file implements regression tests for SQLite library.  The
# focus of this script is testing the ATTACH and DETACH commands
# and related functionality.
#
# $Id: attach2.test,v 1.30 2004/11/23 10:13:03 danielk1977 Exp $
#

set testdir [file dirname $argv0]
source $testdir/tester.tcl


# Ticket #354







|







8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
#    May you share freely, never taking more than you give.
#
#***********************************************************************
# This file implements regression tests for SQLite library.  The
# focus of this script is testing the ATTACH and DETACH commands
# and related functionality.
#
# $Id: attach2.test,v 1.31 2005/01/24 01:38:33 drh Exp $
#

set testdir [file dirname $argv0]
source $testdir/tester.tcl


# Ticket #354
149
150
151
152
153
154
155

156
157
158
159
160
161
162
  catch {db$i close}
}

# A procedure to verify the status of locks on a database.
#
proc lock_status {testnum db expected_result} {
  do_test attach2-$testnum [subst {

    execsql {PRAGMA lock_status} $db
  }] $expected_result
}
set sqlite_os_trace 0

# Tests attach2-4.* test that read-locks work correctly with attached
# databases.







>







149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
  catch {db$i close}
}

# A procedure to verify the status of locks on a database.
#
proc lock_status {testnum db expected_result} {
  do_test attach2-$testnum [subst {
    $db cache flush  ;# The lock_status pragma should not be cached
    execsql {PRAGMA lock_status} $db
  }] $expected_result
}
set sqlite_os_trace 0

# Tests attach2-4.* test that read-locks work correctly with attached
# databases.