/ Check-in [11b8a4cb]
Login

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

Overview
Comment:Fix a problem causing some Tcl test cases to fail with errors like "expected: [<multiline-whitespace>], got: []".
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA3-256: 11b8a4cba747ca214fe3506caa3b711c87be4d55412754e673cc0603afefb086
User & Date: dan 2019-01-14 19:13:30
Context
2019-01-14
20:44
Add scalar function "prefix_length()" to ext/misc/prefixes.c. check-in: 0bf15505 user: dan tags: trunk
19:13
Fix a problem causing some Tcl test cases to fail with errors like "expected: [<multiline-whitespace>], got: []". check-in: 11b8a4cb user: dan tags: trunk
16:16
Add the "prefixes" table-valued function in the ext/misc folder. check-in: f0fd2163 user: drh tags: trunk
Changes
Hide Diffs Side-by-Side Diffs Ignore Whitespace Patch

Changes to test/tester.tcl.

   937    937     }
   938    938   
   939    939     if {[llength $args]==2} {
   940    940       foreach {testname sql} $args {}
   941    941       set result ""
   942    942     } elseif {[llength $args]==3} {
   943    943       foreach {testname sql result} $args {}
          944  +
          945  +    # With some versions of Tcl on windows, if $result is all whitespace but
          946  +    # contains some CR/LF characters, the [list {*}$result] below returns a
          947  +    # copy of $result instead of a zero length string. Not clear exactly why
          948  +    # this is. The following is a workaround.
          949  +    if {[llength $result]==0} { set result "" }
   944    950     } else {
   945    951       error [string trim {
   946    952         wrong # args: should be "do_execsql_test ?-db DB? testname sql ?result?"
   947    953       }]
   948    954     }
   949    955   
   950    956     fix_testname testname