summaryrefslogtreecommitdiffstats
path: root/tests/tcltest.test
diff options
context:
space:
mode:
authorsebres <sebres@users.sourceforge.net>2018-04-09 19:50:12 (GMT)
committersebres <sebres@users.sourceforge.net>2018-04-09 19:50:12 (GMT)
commita9ef86f152a4cda4acf25dbb79dbd9cd18449458 (patch)
tree1f036d6c2baadc7cd9b67ceac71deae44861624a /tests/tcltest.test
parent24a04c081909c75252c8def939e0473206550302 (diff)
downloadtcl-a9ef86f152a4cda4acf25dbb79dbd9cd18449458.zip
tcl-a9ef86f152a4cda4acf25dbb79dbd9cd18449458.tar.gz
tcl-a9ef86f152a4cda4acf25dbb79dbd9cd18449458.tar.bz2
win: fix several test-cases for windows platform
Diffstat (limited to 'tests/tcltest.test')
-rw-r--r--tests/tcltest.test8
1 files changed, 5 insertions, 3 deletions
diff --git a/tests/tcltest.test b/tests/tcltest.test
index ce8d617..d513856 100644
--- a/tests/tcltest.test
+++ b/tests/tcltest.test
@@ -549,8 +549,9 @@ switch -- $::tcl_platform(platform) {
file attributes $notWriteableDir -permissions 00555
}
default {
+ # note in FAT/NTFS we won't be able to protect directory with read-only attribute...
catch {file attributes $notWriteableDir -readonly 1}
- catch {testchmod 000 $notWriteableDir}
+ catch {testchmod 0 $notWriteableDir}
}
}
test tcltest-8.3 {tcltest a.tcl -tmpdir notReadableDir} {
@@ -565,9 +566,10 @@ test tcltest-8.3 {tcltest a.tcl -tmpdir notReadableDir} {
# This constraint doesn't go at the top of the file so that it doesn't
# interfere with tcltest-5.5
testConstraint notFAT [expr {
- ![string match "FAT*" [lindex [file system $notWriteableDir] 1]]
+ ![regexp {^(FAT\d*|NTFS)$} [lindex [file system $notWriteableDir] 1]]
+ || $::tcl_platform(platform) eq "unix" || [llength [info commands testchmod]]
}]
-# FAT permissions are fairly hopeless; ignore this test if that FS is used
+# FAT/NTFS permissions are fairly hopeless; ignore this test if that FS is used
test tcltest-8.4 {tcltest a.tcl -tmpdir notWriteableDir} {
-constraints {unixOrPc notRoot notFAT}
-body {