summaryrefslogtreecommitdiffstats
path: root/tests/fileName.test
diff options
context:
space:
mode:
authorvincentdarley <vincentdarley>2003-10-03 17:25:22 (GMT)
committervincentdarley <vincentdarley>2003-10-03 17:25:22 (GMT)
commit5e610d838ab3c6b8398b2ae540ca3d73f2025e8a (patch)
tree0d47a9e7196a908e951c272e96bb45c5b051a95d /tests/fileName.test
parent7874bbbf7780a2d50f99f77b4d0590e5b4e6fcbf (diff)
downloadtcl-5e610d838ab3c6b8398b2ae540ca3d73f2025e8a.zip
tcl-5e610d838ab3c6b8398b2ae540ca3d73f2025e8a.tar.gz
tcl-5e610d838ab3c6b8398b2ae540ca3d73f2025e8a.tar.bz2
new tests for reported problems, fixes to follow
Diffstat (limited to 'tests/fileName.test')
-rw-r--r--tests/fileName.test70
1 files changed, 69 insertions, 1 deletions
diff --git a/tests/fileName.test b/tests/fileName.test
index 6247fb9..e858caa 100644
--- a/tests/fileName.test
+++ b/tests/fileName.test
@@ -10,7 +10,7 @@
# See the file "license.terms" for information on usage and redistribution
# of this file, and for a DISCLAIMER OF ALL WARRANTIES.
#
-# RCS: @(#) $Id: fileName.test,v 1.30.2.1 2003/04/29 11:45:24 vincentdarley Exp $
+# RCS: @(#) $Id: fileName.test,v 1.30.2.2 2003/10/03 17:25:22 vincentdarley Exp $
if {[lsearch [namespace children] ::tcltest] == -1} {
package require tcltest
@@ -895,6 +895,74 @@ test filename-9.18 {Tcl_JoinPath: win} {testsetplatform} {
testsetplatform win
file join foo/./bar
} {foo/./bar}
+test filename-9.19 {Tcl_JoinPath: win} {testsetplatform} {
+ testsetplatform win
+ set res {}
+ lappend res \
+ [file join {C:\foo\bar}] \
+ [file join C:/blah {C:\foo\bar}] \
+ [file join C:/blah C:/blah {C:\foo\bar}]
+} {C:/foo/bar C:/foo/bar C:/foo/bar}
+test filename-9.20 {Tcl_JoinPath: unix} {testsetplatform} {
+ testsetplatform unix
+ set res {}
+ lappend res \
+ [file join {/foo/bar}] \
+ [file join /x {/foo/bar}] \
+ [file join /x /x {/foo/bar}]
+} {/foo/bar /foo/bar /foo/bar}
+test filename-9.21 {Tcl_JoinPath: mac} {testsetplatform} {
+ testsetplatform mac
+ set res {}
+ lappend res \
+ [file join {/foo/bar}] \
+ [file join drive: {/foo/bar}] \
+ [file join drive: drive: {/foo/bar}]
+} {foo:bar foo:bar foo:bar}
+test filename-9.22 {Tcl_JoinPath: mac} {testsetplatform} {
+ testsetplatform mac
+ set res {}
+ lappend res \
+ [file join {foo:bar}] \
+ [file join drive: {foo:bar}] \
+ [file join drive: drive: {foo:bar}]
+} {foo:bar foo:bar foo:bar}
+test filename-9.23 {Tcl_JoinPath: win} {testsetplatform} {
+ testsetplatform win
+ set res {}
+ lappend res \
+ [file join {foo\bar}] \
+ [file join C:/blah {foo\bar}] \
+ [file join C:/blah C:/blah {foo\bar}]
+ string map [list C:/blah ""] $res
+} {foo/bar /foo/bar /foo/bar}
+test filename-9.24 {Tcl_JoinPath: unix} {testsetplatform} {
+ testsetplatform unix
+ set res {}
+ lappend res \
+ [file join {foo/bar}] \
+ [file join /x {foo/bar}] \
+ [file join /x /x {foo/bar}]
+ string map [list /x ""] $res
+} {foo/bar /foo/bar /foo/bar}
+test filename-9.25 {Tcl_JoinPath: mac} {testsetplatform} {
+ testsetplatform mac
+ set res {}
+ lappend res \
+ [file join {foo/bar}] \
+ [file join drive: {foo/bar}] \
+ [file join drive: drive: {foo/bar}]
+ string map [list drive: ""] $res
+} {:foo:bar foo:bar foo:bar}
+test filename-9.26 {Tcl_JoinPath: mac} {testsetplatform} {
+ testsetplatform mac
+ set res {}
+ lappend res \
+ [file join {:foo:bar}] \
+ [file join drive: {:foo:bar}] \
+ [file join drive: drive: {:foo:bar}]
+ string map [list drive: ""] $res
+} {:foo:bar foo:bar foo:bar}
test filename-10.1 {Tcl_TranslateFileName} {testsetplatform} {
testsetplatform unix