summaryrefslogtreecommitdiffstats
path: root/tests/string.test
diff options
context:
space:
mode:
authorhobbs <hobbs>2002-05-29 09:09:00 (GMT)
committerhobbs <hobbs>2002-05-29 09:09:00 (GMT)
commitd09632b15964e5b79ad13ce6f7cad080df914050 (patch)
tree88864fae0ce82572aaca19bfe8d59618a1919120 /tests/string.test
parent5fe462614952a2b96420e57e700d9fd11e4d6cdf (diff)
downloadtcl-d09632b15964e5b79ad13ce6f7cad080df914050.zip
tcl-d09632b15964e5b79ad13ce6f7cad080df914050.tar.gz
tcl-d09632b15964e5b79ad13ce6f7cad080df914050.tar.bz2
added more string comparison checks
Diffstat (limited to 'tests/string.test')
-rw-r--r--tests/string.test14
1 files changed, 13 insertions, 1 deletions
diff --git a/tests/string.test b/tests/string.test
index 8cc5e00..d2bdb6d 100644
--- a/tests/string.test
+++ b/tests/string.test
@@ -12,7 +12,7 @@
# See the file "license.terms" for information on usage and redistribution
# of this file, and for a DISCLAIMER OF ALL WARRANTIES.
#
-# RCS: @(#) $Id: string.test,v 1.33 2002/02/15 14:28:50 dkf Exp $
+# RCS: @(#) $Id: string.test,v 1.34 2002/05/29 09:09:00 hobbs Exp $
if {[lsearch [namespace children] ::tcltest] == -1} {
package require tcltest
@@ -131,6 +131,18 @@ test string-2.30 {string compare with NUL character vs. other ASCII} {
# these puts chars in the wrong order
string compare \x00 \x01
} -1
+test string-2.31 {string compare, high bit} {
+ proc foo {} {string compare "a\x80" "a@"}
+ foo
+} 1
+test string-2.32 {string compare, high bit} {
+ proc foo {} {string compare "a\x00" "a\x01"}
+ foo
+} -1
+test string-2.33 {string compare, high bit} {
+ proc foo {} {string compare "\x00\x00" "\x00\x01"}
+ foo
+} -1
# only need a few tests on equal, since it uses the same code as
# string compare, but just modifies the return output