SQLite

Check-in [df2c28dc73]
Login

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

Overview
Comment:In rollback.test, do not check for journal deletion if the journal mode is not DELETE. Call show_memstats after each test module in all.test and quick.test. (CVS 5814)
Downloads: Tarball | ZIP archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1: df2c28dc7310510bada292a2e8c1be073803858c
User & Date: drh 2008-10-13 14:16:11.000
Context
2008-10-13
15:35
Fix the SQLITE_OMIT_DATETIME_FUNCS compile-time option so that it builds successfully. (CVS 5815) (check-in: c3f9164515 user: drh tags: trunk)
14:16
In rollback.test, do not check for journal deletion if the journal mode is not DELETE. Call show_memstats after each test module in all.test and quick.test. (CVS 5814) (check-in: df2c28dc73 user: drh tags: trunk)
10:56
Use one less temporary table in genfkey.c. The retired table was being used to workaround the bug fixed by (5812). (CVS 5813) (check-in: 73efca985a user: danielk1977 tags: trunk)
Changes
Unified Diff Ignore Whitespace Patch
Changes to test/all.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
# 2001 September 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 runs all tests.
#
# $Id: all.test,v 1.58 2008/09/09 18:28:07 danielk1977 Exp $

set testdir [file dirname $argv0]
source $testdir/tester.tcl
rename finish_test really_finish_test
proc finish_test {} {

  # no-op
}

if {[file exists ./sqlite_test_count]} {
  set COUNT [exec cat ./sqlite_test_count]
} else {
  set COUNT 3
}












|





>
|







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
# 2001 September 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 runs all tests.
#
# $Id: all.test,v 1.59 2008/10/13 14:16:11 drh Exp $

set testdir [file dirname $argv0]
source $testdir/tester.tcl
rename finish_test really_finish_test
proc finish_test {} {
  catch {db close}
  show_memstats
}

if {[file exists ./sqlite_test_count]} {
  set COUNT [exec cat ./sqlite_test_count]
} else {
  set COUNT 3
}
Changes to test/quick.test.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
#
#    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 runs all tests.
#
# $Id: quick.test,v 1.87 2008/09/09 18:28:07 danielk1977 Exp $

proc lshift {lvar} {
  upvar $lvar l
  set ret [lindex $l 0]
  set l [lrange $l 1 end]
  return $ret
}








|







1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
#
#    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 runs all tests.
#
# $Id: quick.test,v 1.88 2008/10/13 14:16:11 drh Exp $

proc lshift {lvar} {
  upvar $lvar l
  set ret [lindex $l 0]
  set l [lrange $l 1 end]
  return $ret
}
31
32
33
34
35
36
37
38



39
40
41
42
43
44
45
    }
  }
}

set testdir [file dirname $argv0]
source $testdir/tester.tcl
rename finish_test really_finish_test
proc finish_test {} {}



set ISQUICK 1

set EXCLUDE {
  all.test
  async.test
  async2.test
  async3.test







|
>
>
>







31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
    }
  }
}

set testdir [file dirname $argv0]
source $testdir/tester.tcl
rename finish_test really_finish_test
proc finish_test {} {
  catch {db close}
  show_memstats
}
set ISQUICK 1

set EXCLUDE {
  all.test
  async.test
  async2.test
  async3.test
Changes to test/rollback.test.
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
#
#***********************************************************************
# This file implements regression tests for SQLite library.  The
# focus of this file is verifying that a rollback in one statement
# caused by an ON CONFLICT ROLLBACK clause aborts any other pending
# statements.
#
# $Id: rollback.test,v 1.8 2008/10/07 15:00:09 danielk1977 Exp $

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

set DB [sqlite3_connection_pointer db]

do_test rollback-1.1 {







|







9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
#
#***********************************************************************
# This file implements regression tests for SQLite library.  The
# focus of this file is verifying that a rollback in one statement
# caused by an ON CONFLICT ROLLBACK clause aborts any other pending
# statements.
#
# $Id: rollback.test,v 1.9 2008/10/13 14:16:11 drh Exp $

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

set DB [sqlite3_connection_pointer db]

do_test rollback-1.1 {
121
122
123
124
125
126
127

128
129
130

131
132
133
134
135
136
137
138
139
140
  # 
  do_test rollback-2.2 {
    sqlite3 db2 testA.db
    execsql {
      SELECT distinct tbl_name FROM sqlite_master;
    } db2
  } {t1 t3}

  do_test rollback-2.3 {
    file exists testA.db-journal
  } 0

  do_test rollback-2.4 {
    execsql {
      SELECT distinct tbl_name FROM sqlite_master;
    } db2
  } {t1 t3}

  db2 close
}

finish_test







>
|
|
|
>










121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
  # 
  do_test rollback-2.2 {
    sqlite3 db2 testA.db
    execsql {
      SELECT distinct tbl_name FROM sqlite_master;
    } db2
  } {t1 t3}
  if {[lsearch {exclusive persistent_journal no_journal} $permutation]<0} {
    do_test rollback-2.3 {
      file exists testA.db-journal
    } 0
  }
  do_test rollback-2.4 {
    execsql {
      SELECT distinct tbl_name FROM sqlite_master;
    } db2
  } {t1 t3}

  db2 close
}

finish_test