/ Check-in [9e004c51]
Login

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

Overview
Comment:Add Tcl (flush) commands to exclusive2.test, which is failing on some systems but not others. (CVS 3806)
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1:9e004c519a30257fe3230ac7af630d296e139c9e
User & Date: danielk1977 2007-04-03 16:13:52
Context
2007-04-04
01:27
Test coverage improvements. (CVS 3807) check-in: 25f49acc user: drh tags: trunk
2007-04-03
16:13
Add Tcl (flush) commands to exclusive2.test, which is failing on some systems but not others. (CVS 3806) check-in: 9e004c51 user: danielk1977 tags: trunk
2007-04-02
22:19
Fix to Makefile.in so that "make test" works. (CVS 3805) check-in: f592dd2d user: drh tags: trunk
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Changes to test/exclusive2.test.

6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
..
25
26
27
28
29
30
31
32

33
34
35
36
37
38
39
...
153
154
155
156
157
158
159

160
161
162
163
164
165
166
#    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.
#
# $Id: exclusive2.test,v 1.1 2007/03/26 10:27:19 danielk1977 Exp $

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

ifcapable {!pager_pragmas} {
  finish_test
  return
................................................................................
  fconfigure $fd -translation binary -encoding binary
  if {$new ne ""} {
    seek $fd 24
    set a [expr {($new&0xFF000000)>>24}]
    set b [expr {($new&0x00FF0000)>>16}]
    set c [expr {($new&0x0000FF00)>>8}]
    set d [expr {($new&0x000000FF)}]
    puts $fd [binary format cccc $a $b $c $d]

  }

  seek $fd 24
  foreach {a b c d} [list 0 0 0 0] {}
  binary scan [read $fd 4] cccc a b c d
  set  ret [expr ($a&0x000000FF)<<24]
  incr ret [expr ($b&0x000000FF)<<16]
................................................................................
  t1sig
} $::sig

do_test exclusive2-2.4 {
  set fd [open test.db a]
  seek $fd 1024
  puts -nonewline $fd [string repeat [binary format c 0] 10000]

  t1sig
} $::sig

do_test exclusive2-2.5 {
  pagerChangeCounter test.db 5
} {5}
do_test exclusive2-2.6 {







|







 







|
>







 







>







6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
..
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
...
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
#    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.
#
# $Id: exclusive2.test,v 1.2 2007/04/03 16:13:52 danielk1977 Exp $

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

ifcapable {!pager_pragmas} {
  finish_test
  return
................................................................................
  fconfigure $fd -translation binary -encoding binary
  if {$new ne ""} {
    seek $fd 24
    set a [expr {($new&0xFF000000)>>24}]
    set b [expr {($new&0x00FF0000)>>16}]
    set c [expr {($new&0x0000FF00)>>8}]
    set d [expr {($new&0x000000FF)}]
    puts -nonewline $fd [binary format cccc $a $b $c $d]
    flush $fd
  }

  seek $fd 24
  foreach {a b c d} [list 0 0 0 0] {}
  binary scan [read $fd 4] cccc a b c d
  set  ret [expr ($a&0x000000FF)<<24]
  incr ret [expr ($b&0x000000FF)<<16]
................................................................................
  t1sig
} $::sig

do_test exclusive2-2.4 {
  set fd [open test.db a]
  seek $fd 1024
  puts -nonewline $fd [string repeat [binary format c 0] 10000]
  flush $fd
  t1sig
} $::sig

do_test exclusive2-2.5 {
  pagerChangeCounter test.db 5
} {5}
do_test exclusive2-2.6 {