]> git.ipfire.org Git - thirdparty/sqlite.git/commitdiff
Fix the "checksymbols" target in Makefile.in so that it actually works.
authordrh <drh@noemail.net>
Mon, 29 Dec 2014 02:55:58 +0000 (02:55 +0000)
committerdrh <drh@noemail.net>
Mon, 29 Dec 2014 02:55:58 +0000 (02:55 +0000)
Enhance the releasetest.tcl script to count the total number of tests
run over all configurations.

FossilOrigin-Name: 4eda1c746043acbdb7ef3e1f95bf8b01ee976479

Makefile.in
manifest
manifest.uuid
test/releasetest.tcl

index 887f99e0ee5c8dcb410208abbeb41d1e05b8eb52..6867afcf52b44e5cb5e56759f291bd6323f1dc77 100644 (file)
@@ -974,7 +974,8 @@ speedtest1$(TEXE):  $(TOP)/test/wordcount.c sqlite3.lo
 # releasetest.tcl script.
 #
 checksymbols: sqlite3.lo
-       nm -g --defined-only sqlite3.lo | grep -v " sqlite3_" ; test $$? -ne 0
+       nm -g --defined-only sqlite3.o | grep -v " sqlite3_" ; test $$? -ne 0
+       echo '0 errors out of 1 tests'
 
 # The next two rules are used to support the "threadtest" target. Building
 # threadtest runs a few thread-safety tests that are implemented in C. This
index ab14a67a570bbcd9e75346f40f85bd8d8af1080d..8891c37497270213d9acc7d4e56db1ac8399da61 100644 (file)
--- a/manifest
+++ b/manifest
@@ -1,7 +1,7 @@
-C Fix\sWITHOUT\sROWID\stables\sso\sthat\sthey\scorrectly\sdeal\swith\sPRIMARY\sKEYs\sthat\ncontain\sredundant\scolumns.
-D 2014-12-28T22:10:51.114
+C Fix\sthe\s"checksymbols"\starget\sin\sMakefile.in\sso\sthat\sit\sactually\sworks.\nEnhance\sthe\sreleasetest.tcl\sscript\sto\scount\sthe\stotal\snumber\sof\stests\nrun\sover\sall\sconfigurations.
+D 2014-12-29T02:55:58.026
 F Makefile.arm-wince-mingw32ce-gcc d6df77f1f48d690bd73162294bbba7f59507c72f
-F Makefile.in c20e37499a3d664a3732257ed042352eba777a4d
+F Makefile.in 40326b6d788007dd5e00587c54adcd2621832bb3
 F Makefile.linux-gcc 91d710bdc4998cb015f39edf3cb314ec4f4d7e23
 F Makefile.msc b363b90fe1bfc3b87d190f2f728a126c00d9ce09
 F Makefile.vxworks 034289efa9d591b04b1a73598623119c306cbba0
@@ -801,7 +801,7 @@ F test/randexpr1.test eda062a97e60f9c38ae8d806b03b0ddf23d796df
 F test/rdonly.test dd30a4858d8e0fbad2304c2bd74a33d4df36412a
 F test/regexp1.test 497ea812f264d12b6198d6e50a76be4a1973a9d8
 F test/reindex.test 44edd3966b474468b823d481eafef0c305022254
-F test/releasetest.tcl 80d10f058667e6d0c8ab379d6e5bb0a60ecb40e2
+F test/releasetest.tcl 14552a8741165a0489cd9ec3e9a651ba1f1b3567
 F test/resolver01.test 33abf37ff8335e6bf98f2b45a0af3e06996ccd9a
 F test/rollback.test 458fe73eb3ffdfdf9f6ba3e9b7350a6220414dea
 F test/rollback2.test fc14cf6d1a2b250d2735ef16124b971bce152f14
@@ -1234,7 +1234,7 @@ F tool/vdbe_profile.tcl 67746953071a9f8f2f668b73fe899074e2c6d8c1
 F tool/warnings-clang.sh f6aa929dc20ef1f856af04a730772f59283631d4
 F tool/warnings.sh 0abfd78ceb09b7f7c27c688c8e3fe93268a13b32
 F tool/win/sqlite.vsix deb315d026cc8400325c5863eef847784a219a2f
-P 3286424b4d30035de69b88ef0b2897365ff848f9
-R fdb1da8fdb04c896d0536c98941bdfa0
+P 0dfef6757056ef0bdea8f049f7469ccf6960e2cb
+R 74cab324b9af5a87ce922fe9e97d1a6b
 U drh
-Z ccbcde8f60a3b3f04760cafd27073216
+Z 3ab79c0378fea7c029a9124c0c9f4912
index e8065acc31b4f28bdc570a8aea4a5e41b05d30cc..5ec8724985807fb5f54e7d153e7a90229de3a7b3 100644 (file)
@@ -1 +1 @@
-0dfef6757056ef0bdea8f049f7469ccf6960e2cb
\ No newline at end of file
+4eda1c746043acbdb7ef3e1f95bf8b01ee976479
\ No newline at end of file
index 879b7f8fb97d8e6c95bd0ed0441d35adab32bf97..6a91ac585b5deed0d44b24252ef92ab2b602021b 100644 (file)
@@ -65,7 +65,6 @@ array set ::Configs {
     -DSQLITE_SECURE_DELETE=1
     -DSQLITE_SOUNDEX=1
     -DSQLITE_ENABLE_ATOMIC_WRITE=1
-    -DSQLITE_ENABLE_IOTRACE=1
     -DSQLITE_ENABLE_MEMORY_MANAGEMENT=1
     -DSQLITE_ENABLE_OVERSIZE_CELL_CHECK=1
   }
@@ -201,6 +200,37 @@ foreach {key value} [array get ::Platforms] {
   }
 }
 
+# Open the file $logfile and look for a report on the number of errors
+# and the number of test cases run.  Add these values to the global
+# $::NERRCASE and $::NTESTCASE variables.
+#
+# If any errors occur, then write into $errmsgVar the text of an appropriate
+# one-line error message to show on the output.
+#
+proc count_tests_and_errors {logfile rcVar errmsgVar} {
+  upvar 1 $rcVar rc $errmsgVar errmsg
+  set fd [open $logfile rb]
+  set seen 0
+  while {![eof $fd]} {
+    set line [gets $fd]
+    if {[regexp {^(\d+) errors out of (\d+) tests} $line all nerr ntest]} {
+      incr ::NERRCASE $nerr
+      incr ::NTESTCASE $ntest
+      set seen 1
+      if {$nerr>0} {
+        set rc 1
+        set errmsg $line
+      }
+      break;
+    }
+  }
+  close $fd
+  if {!$seen} {
+    set rc 1
+    set errmsg "Test did not complete"
+  }
+}
+
 proc run_test_suite {name testtarget config} {
   # Tcl variable $opts is used to build up the value used to set the
   # OPTS Makefile variable. Variable $cflags holds the value for
@@ -242,9 +272,11 @@ proc run_test_suite {name testtarget config} {
   set tm1 [clock seconds]
   set origdir [pwd]
   dryrun cd $dir
+  set errmsg {}
   set rc [catch [configureCommand]]
   if {!$rc} {
     set rc [catch [makeCommand $testtarget $cflags $opts]]
+    count_tests_and_errors test.log rc errmsg
   }
   set tm2 [clock seconds]
   dryrun cd $origdir
@@ -257,6 +289,7 @@ proc run_test_suite {name testtarget config} {
     if {$rc} {
       puts " FAIL $tm"
       incr ::NERR
+      if {$errmsg!=""} {puts "     $errmsg"}
     } else {
       puts " Ok   $tm"
     }
@@ -407,6 +440,8 @@ proc main {argv} {
 
   set ::NERR 0
   set ::NTEST 0
+  set ::NTESTCASE 0
+  set ::NERRCASE 0
   set STARTTIME [clock seconds]
   foreach {zConfig target} $::CONFIGLIST {
     if {$::QUICK} {set target test}
@@ -441,7 +476,7 @@ proc main {argv} {
   set sec [expr {$elapsetime%60}]
   set etime [format (%02d:%02d:%02d) $hr $min $sec]
   puts [string repeat * 70]
-  puts "$::NERR failures of $::NTEST test suites run in $etime"
+  puts "$::NERRCASE failures of $::NTESTCASE tests run in $etime"
 }
 
 main $argv