Adjust the fts3rank.test module so that it works on big-endian systems
(hopefully - I don't have a big-endian machine to test the change on.) FossilOrigin-Name: e4766cabdf64d8e998048ae43154466fc9c3fad0b86102a42b65122abfcbbe55
This commit is contained in:
+10
-5
@@ -14,7 +14,7 @@
|
||||
|
||||
set testdir [file dirname $argv0]
|
||||
source $testdir/tester.tcl
|
||||
set testprefix fts3expr5
|
||||
set testprefix fts3rank
|
||||
|
||||
# If SQLITE_ENABLE_FTS3 is defined, omit this file.
|
||||
ifcapable !fts3 {
|
||||
@@ -56,9 +56,14 @@ do_catchsql_test 1.4 {
|
||||
SELECT * FROM t1 ORDER BY rank(x'0000000000000000') DESC, rowid
|
||||
} {0 {{one two} one {one two} three {one two} two}}
|
||||
|
||||
do_catchsql_test 1.5 {
|
||||
SELECT * FROM t1 ORDER BY rank(x'0100000001000000') DESC, rowid
|
||||
} {1 {invalid matchinfo blob passed to function rank()}}
|
||||
if {$tcl_platform(byteOrder)=="littleEndian"} {
|
||||
do_catchsql_test 1.5le {
|
||||
SELECT * FROM t1 ORDER BY rank(x'0100000001000000') DESC, rowid
|
||||
} {1 {invalid matchinfo blob passed to function rank()}}
|
||||
} else {
|
||||
do_catchsql_test 1.5be {
|
||||
SELECT * FROM t1 ORDER BY rank(x'0000000100000001') DESC, rowid
|
||||
} {1 {invalid matchinfo blob passed to function rank()}}
|
||||
}
|
||||
|
||||
finish_test
|
||||
|
||||
|
||||
Reference in New Issue
Block a user