summaryrefslogtreecommitdiffstats
path: root/tests/tcltest.test
diff options
context:
space:
mode:
authorsebres <sebres@users.sourceforge.net>2018-04-30 11:10:14 (GMT)
committersebres <sebres@users.sourceforge.net>2018-04-30 11:10:14 (GMT)
commitddfce0ed3f91a335d169f6f25cae2da7051d0631 (patch)
treeaa841cbe8a6780d3d9f2c28e9c5059c0b44516ce /tests/tcltest.test
parentdf94eecf119611a2fa8de1abb3abe59269be7550 (diff)
parent9856afd5903e2aec8bed684abb91fe307cd20765 (diff)
downloadtcl-ddfce0ed3f91a335d169f6f25cae2da7051d0631.zip
tcl-ddfce0ed3f91a335d169f6f25cae2da7051d0631.tar.gz
tcl-ddfce0ed3f91a335d169f6f25cae2da7051d0631.tar.bz2
merge fix-1613456fff, closes [1613456fffffffff] and [27b682284974d0cd]
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 {