aboutsummaryrefslogtreecommitdiff
path: root/tests/lsort.test
diff options
context:
space:
mode:
authorEvan Hunter <evan@ozhiker.com>2016-10-09 18:15:18 +0100
committerSteve Bennett <steveb@workware.net.au>2016-10-11 08:33:24 +1000
commit3d31b6fe9b1144adaf9127ccde69cefa77316268 (patch)
tree5a6801614938eb611043c54f9f2f46018a4c5f6b /tests/lsort.test
parent00fb0474d517db114375b5e979d7f8cbb8b71b57 (diff)
downloadjimtcl-3d31b6fe9b1144adaf9127ccde69cefa77316268.zip
jimtcl-3d31b6fe9b1144adaf9127ccde69cefa77316268.tar.gz
jimtcl-3d31b6fe9b1144adaf9127ccde69cefa77316268.tar.bz2
Separate out Jim specific tests
Diffstat (limited to 'tests/lsort.test')
-rw-r--r--tests/lsort.test13
1 files changed, 9 insertions, 4 deletions
diff --git a/tests/lsort.test b/tests/lsort.test
index ca2fc49..69b7467 100644
--- a/tests/lsort.test
+++ b/tests/lsort.test
@@ -149,9 +149,12 @@ test lsort-3.9 {SortCompare procedure, -integer option} {
test lsort-3.10 {SortCompare procedure, -integer option} {
list [catch {lsort -integer {3 q}} msg] $msg
} {1 {expected integer but got "q"}}
-test lsort-3.11 {SortCompare procedure, -integer option} {
+# JimTCL specifically does not adhere to the octal default for numbers starting with zero
+test lsort-3.11 {SortCompare procedure, -integer option} -constraints jim -body {
lsort -integer {35 21 0x20 30 023 100 8}
-} {8 21 023 30 0x20 35 100}
+} -result {8 21 023 30 0x20 35 100}
+
+
test lsort-3.15 {SortCompare procedure, -command option} {
proc cmp {a b} {
error "comparison error"
@@ -176,9 +179,11 @@ test lsort-3.18 {SortCompare procedure, -command option} {
}
lsort -command cmp {48 6 18 22 21 35 36}
} {48 36 35 22 21 18 6}
-test lsort-3.19 {SortCompare procedure, -decreasing option} {
+# JimTCL specifically does not adhere to the octal default for numbers starting with zero
+test lsort-3.19 {SortCompare procedure, -decreasing optio} -constraints jim -body {
lsort -decreasing -integer {35 21 0x20 30 023 100 8}
-} {100 35 0x20 30 023 21 8}
+} -result {100 35 0x20 30 023 21 8}
+
test lsort-3.20 {SortCompare procedure, -real option} -body {
lsort -real {6...4 3}
} -returnCodes error -result {expected floating-point number but got "6...4"}