/ Check-in [87c7e82f]
Login

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

Overview
Comment:Make sure thread003.test waits for all spawned threads to finish before continuing. (CVS 5644)
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1: 87c7e82f54cd446721d553d5c48ca2571b063669
User & Date: danielk1977 2008-08-30 09:10:17
Context
2008-08-30
13:25
Add some code to permutations.test to make sure no test file modifies the shared-cache setting. (CVS 5645) check-in: 8565b7c6 user: danielk1977 tags: trunk
09:10
Make sure thread003.test waits for all spawned threads to finish before continuing. (CVS 5644) check-in: 87c7e82f user: danielk1977 tags: trunk
2008-08-29
18:42
remove private declaration of sqlite3_snprintf() in sqliteInt.h as there is already a public declaration in sqlite3.h (CVS 5643) check-in: 4113e778 user: rse tags: trunk
Changes
Hide Diffs Side-by-Side Diffs Ignore Whitespace Patch

Changes to test/thread003.test.

     8      8   #    May you share freely, never taking more than you give.
     9      9   #
    10     10   #***********************************************************************
    11     11   #
    12     12   #   This file contains tests that attempt to break the pcache module
    13     13   #   by bombarding it with simultaneous requests from multiple threads.
    14     14   #     
    15         -# $Id: thread003.test,v 1.3 2008/08/28 13:55:10 danielk1977 Exp $
           15  +# $Id: thread003.test,v 1.4 2008/08/30 09:10:17 danielk1977 Exp $
    16     16   
    17     17   set testdir [file dirname $argv0]
    18     18   
    19     19   source $testdir/tester.tcl
    20     20   source $testdir/thread_common.tcl
    21     21   if {[info commands sqlthread] eq ""} {
    22     22     finish_test
................................................................................
   151    151   
   152    152   # In this test case, one thread is continually querying the database.
   153    153   # The other thread does not have a database connection, but calls
   154    154   # sqlite3_release_memory() over and over again.
   155    155   #
   156    156   set nSecond 30
   157    157   puts "Starting thread003.3 (should run for ~$nSecond seconds)"
          158  +unset -nocomplain finished(1)
          159  +unset -nocomplain finished(2)
   158    160   do_test thread003.4 {
   159    161     thread_spawn finished(1) $thread_procs [format {
   160    162       set iEnd [expr {[clock_seconds] + %d}]
   161    163       set ::DB [sqlthread open test.db]
   162    164   
   163    165       # Set the cache size to 15 pages per cache. 30 available globally.
   164    166       execsql { PRAGMA cache_size = 15 }