/ Check-in [9d532fb5]
Login

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

Overview
Comment:Add a space before each line of error output in the test scripts so that all errors can be conveniently located in logs by doing "grep '^ '".
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1:9d532fb50d310df629ea65193f21dc9b3594ff5f
User & Date: drh 2015-11-12 21:42:40
Context
2015-11-12
22:15
Always parse the schema *before* running "PRAGMA cache_size", not after. check-in: 12e7d9ec user: drh tags: trunk
21:55
Import the test_sqllog.c enhancements from trunk. check-in: 178da339 user: drh tags: apple-osx
21:42
Add a space before each line of error output in the test scripts so that all errors can be conveniently located in logs by doing "grep '^ '". check-in: 9d532fb5 user: drh tags: trunk
20:12
Add support for the SQLITE_SQLLOG_CONDITIONAL environment variable to the logging code in test_sqllog.c. When defined, logging is only performed if the "<database>-sqllog" file is present in the file system when the main database is opened. check-in: cab8126b user: dan tags: trunk
Changes
Hide Diffs Side-by-Side Diffs Ignore Whitespace Patch

Changes to test/pragma2.test.

   131    131   # EVIDENCE-OF: R-23955-02765 Cache_spill is enabled by default
   132    132   #
   133    133   db close
   134    134   delete_file test.db test.db-journal
   135    135   delete_file test2.db test2.db-journal
   136    136   sqlite3 db test.db
   137    137   do_execsql_test pragma2-4.1 {
          138  +  PRAGMA main.cache_size=2000;
          139  +  PRAGMA temp.cache_size=2000;
   138    140     PRAGMA cache_spill;
   139    141     PRAGMA main.cache_spill;
   140    142     PRAGMA temp.cache_spill;
   141    143   } {2000 2000 2000}
   142    144   do_execsql_test pragma2-4.2 {
   143    145     PRAGMA cache_spill=OFF;
   144    146     PRAGMA cache_spill;

Changes to test/tester.tcl.

   742    742         } else {
   743    743           set ok [expr {[string compare $result $expected]==0}]
   744    744         }
   745    745         if {!$ok} {
   746    746           # if {![info exists ::testprefix] || $::testprefix eq ""} {
   747    747           #   error "no test prefix"
   748    748           # }
   749         -        output2_if_no_verbose -nonewline $name...
   750         -        output2 "\nExpected: \[$expected\]\n     Got: \[$result\]"
          749  +        output1 ""
          750  +        output2 " $name expected: \[$expected\]\n $name got:      \[$result\]"
   751    751           fail_test $name
   752    752         } else {
   753    753           output1 " Ok"
   754    754         }
   755    755       }
   756    756     } else {
   757    757       output1 " Omitted"
................................................................................
  1043   1043     run_thread_tests 1
  1044   1044     if {[llength $omitList]>0} {
  1045   1045       output2 "Omitted test cases:"
  1046   1046       set prec {}
  1047   1047       foreach {rec} [lsort $omitList] {
  1048   1048         if {$rec==$prec} continue
  1049   1049         set prec $rec
  1050         -      output2 [format {  %-12s %s} [lindex $rec 0] [lindex $rec 1]]
         1050  +      output2 [format {.  %-12s %s} [lindex $rec 0] [lindex $rec 1]]
  1051   1051       }
  1052   1052     }
  1053   1053     if {$nErr>0 && ![working_64bit_int]} {
  1054   1054       output2 "******************************************************************"
  1055   1055       output2 "N.B.:  The version of TCL that you used to build this test harness"
  1056   1056       output2 "is defective in that it does not support 64-bit integers.  Some or"
  1057   1057       output2 "all of the test failures above might be a result from this defect"

Changes to test/wal3.test.

   271    271   } [list {0 1 lock exclusive} {1 7 lock exclusive}      \
   272    272           {1 7 unlock exclusive} {0 1 unlock exclusive}  \
   273    273   ]
   274    274   proc lock_callback {method filename handle lock} {
   275    275     if {$lock == "1 7 lock exclusive"} { return SQLITE_BUSY }
   276    276     return SQLITE_OK
   277    277   }
   278         -puts "  Warning: This next test case causes SQLite to call xSleep(1) 100 times."
   279         -puts "  Normally this equates to a 100ms delay, but if SQLite is built on unix"
   280         -puts "  without HAVE_USLEEP defined, it may be 100 seconds."
          278  +puts "# Warning: This next test case causes SQLite to call xSleep(1) 100 times."
          279  +puts "# Normally this equates to a 100ms delay, but if SQLite is built on unix"
          280  +puts "# without HAVE_USLEEP defined, it may be 100 seconds."
   281    281   do_test wal3-4.3 {
   282    282     db close
   283    283     set ::locks [list]
   284    284     sqlite3 db test.db -vfs T
   285    285     catchsql { SELECT * FROM x }
   286    286   } {1 {locking protocol}}
   287    287   
   288         -puts "  Warning: Same again!"
          288  +puts "# Warning: Same again!"
   289    289   proc lock_callback {method filename handle lock} {
   290    290     if {$lock == "0 1 lock exclusive"} { return SQLITE_BUSY }
   291    291     return SQLITE_OK
   292    292   }
   293    293   do_test wal3-4.4 {
   294    294     db close
   295    295     set ::locks [list]