Many hyperlinks are disabled.
Use anonymous login
to enable hyperlinks.
Overview
Comment: | Update a couple test scripts to account for more floating point display variation in Windows-based versions of TCL. |
---|---|
Downloads: | Tarball | ZIP archive |
Timelines: | family | ancestors | descendants | both | trunk |
Files: | files | file ages | folders |
SHA1: |
a4a8402bfec381dd23b7a96c2f4b52c0 |
User & Date: | shaneh 2011-06-20 17:41:41.693 |
Original Comment: | Update a couple test scripts to account for more floating point variation under various Windows-based versions of TCL. Update a couple test scripts to account for more floating point display variation in Windows-based versions of TCL. |
Context
2011-06-20
| ||
18:00 | Rework the autoconf script to better deal with utime() and dlopen(). (check-in: f69ed286ff user: drh tags: trunk) | |
17:41 | Update a couple test scripts to account for more floating point display variation in Windows-based versions of TCL. (check-in: a4a8402bfe user: shaneh tags: trunk) | |
17:24 | Fix various harmless compiler warnings in FTS3 and RTREE. (check-in: fe62179efd user: drh tags: trunk) | |
Changes
Changes to test/enc4.test.
︙ | ︙ | |||
57 58 59 60 61 62 63 | do_test enc4-$i.$j.2 { set S [sqlite3_prepare_v2 db "SELECT $init+?" -1 dummy] sqlite3_expired $S } {0} set k 1 foreach val $vals { | | < < | | | 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 | do_test enc4-$i.$j.2 { set S [sqlite3_prepare_v2 db "SELECT $init+?" -1 dummy] sqlite3_expired $S } {0} set k 1 foreach val $vals { for {set x 1} {$x<16} {incr x} { set part [expr $init + [string range $val 0 [expr $x-1]]] do_realnum_test enc4-$i.$j.$k.3.$x { sqlite3_reset $S sqlite3_bind_text $S 1 $val $x sqlite3_step $S sqlite3_column_text $S 0 } [list $part] do_realnum_test enc4-$i.$j.$k.4.$x { sqlite3_reset $S sqlite3_bind_text16 $S 1 [encoding convertto unicode $val] [expr $x*2] sqlite3_step $S sqlite3_column_text $S 0 } [list $part] } |
︙ | ︙ |
Changes to test/tester.tcl.
︙ | ︙ | |||
351 352 353 354 355 356 357 | } else { puts " Ok" } flush stdout } proc realnum_normalize {r} { | > | | 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 | } else { puts " Ok" } flush stdout } proc realnum_normalize {r} { # different TCL versions display floating point values differently. string map {1.#INF inf Inf inf .0e e} [regsub -all {(e[+-])0+} $r {\1}] } proc do_realnum_test {name cmd expected} { uplevel [list do_test $name [ subst -nocommands { realnum_normalize [ $cmd ] } ] [realnum_normalize $expected]] } |
︙ | ︙ |