summaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorjan.nijtmans <nijtmans@users.sourceforge.net>2020-12-26 22:47:02 (GMT)
committerjan.nijtmans <nijtmans@users.sourceforge.net>2020-12-26 22:47:02 (GMT)
commitb91eaa4a758229d9a7b3a08c859c3f3368782b4f (patch)
tree44c9db3f91f4ba4e16f5d1148d204f0e08295d3f /tests
parent63426886f59eb4e4cc53551a575da6229bd25b43 (diff)
parent52cf0e0a28737d7f04d2485d39fd089a5d5b5643 (diff)
downloadtcl-b91eaa4a758229d9a7b3a08c859c3f3368782b4f.zip
tcl-b91eaa4a758229d9a7b3a08c859c3f3368782b4f.tar.gz
tcl-b91eaa4a758229d9a7b3a08c859c3f3368782b4f.tar.bz2
Merge 8.7
Diffstat (limited to 'tests')
-rw-r--r--tests/chanio.test4
-rw-r--r--tests/fCmd.test13
-rw-r--r--tests/safe.test3
-rw-r--r--tests/socket.test8
4 files changed, 17 insertions, 11 deletions
diff --git a/tests/chanio.test b/tests/chanio.test
index 687dda6..04f0e3f 100644
--- a/tests/chanio.test
+++ b/tests/chanio.test
@@ -6502,10 +6502,10 @@ test chan-io-50.5 {testing handler deletion vs reentrant calls} -setup {
set u recursive
lappend z "del calling recursive"
set timer [after 50 lappend z timeout]
- set mode [test servicemode 1]
+ set mode [testservicemode 1]
vwait z
after cancel $timer
- test servicemode $mode
+ testservicemode $mode
lappend z "del after update"
}
}
diff --git a/tests/fCmd.test b/tests/fCmd.test
index 5b70c81..6a909f8 100644
--- a/tests/fCmd.test
+++ b/tests/fCmd.test
@@ -22,7 +22,7 @@ cd [temporaryDirectory]
testConstraint testsetplatform [llength [info commands testsetplatform]]
testConstraint testchmod [llength [info commands testchmod]]
-testConstraint win10 0
+testConstraint winLessThan10 0
# Don't know how to determine this constraint correctly
testConstraint notNetworkFilesystem 0
testConstraint reg 0
@@ -63,8 +63,9 @@ if {[testConstraint unix]} {
}
}
-if {[testConstraint win] && $::tcl_platform(osVersion) >= 10.0} {
- testConstraint win10 1
+# Also used in winFCmd...
+if {[testConstraint win] && $::tcl_platform(osVersion) < 10.0} {
+ testConstraint winLessThan10 1
}
testConstraint darwin9 [expr {
@@ -2313,13 +2314,15 @@ test fCmd-28.7 {file link: source already exists} -setup {
} -returnCodes error -cleanup {
cd [workingDirectory]
} -result {could not create new link "abc.file": that path already exists}
-test fCmd-28.8 {file link} -constraints {linkFile win10} -setup {
+# In Windows 10 developer mode, we _can_ create symbolic links to files!
+test fCmd-28.8 {file link} -constraints {linkFile winLessThan10} -setup {
cd [temporaryDirectory]
} -body {
file link -symbolic abc.link abc.file
} -cleanup {
+ file delete -force abc.link
cd [workingDirectory]
-} -result abc.file
+} -returnCodes error -result {could not create new link "abc.link" pointing to "abc.file": invalid argument}
test fCmd-28.9 {file link: success with file} -constraints {linkFile} -setup {
cd [temporaryDirectory]
file delete -force abc.link
diff --git a/tests/safe.test b/tests/safe.test
index 3718028..db881c2 100644
--- a/tests/safe.test
+++ b/tests/safe.test
@@ -173,6 +173,8 @@ test safe-4.6 {safe::interpDelete, indirectly} -setup {
# A replacement test using example files is "safe-9.8".
# Tests 5.* test the example files before using them to test safe interpreters.
+unset -nocomplain path
+
test safe-5.1 {example tclIndex commands, test in parent interpreter} -setup {
set tmpAutoPath $::auto_path
lappend ::auto_path [file join $TestsDir auto0 auto1] [file join $TestsDir auto0 auto2]
@@ -1654,6 +1656,7 @@ test safe-16.8 {Bug 3529949: defang ~user in paths used by AliasGlob (2)} -setup
# cleanup
set ::auto_path $SaveAutoPath
unset SaveAutoPath TestsDir PathMapp
+unset -nocomplain path
rename mapList {}
rename mapAndSortList {}
::tcltest::cleanupTests
diff --git a/tests/socket.test b/tests/socket.test
index 51014aa..a1a66b5 100644
--- a/tests/socket.test
+++ b/tests/socket.test
@@ -1873,7 +1873,7 @@ proc transf_test {{testmode transfer} {maxIter 1000} {maxTime 10000}} {
set ::count [expr {$maxIter / 4 * 3 - 1}]; # bypass 3/4 iterations
}
}
- tcltest::DebugPuts 1 "== test \[$::localhost\]:$port $testmode =="
+ tcltest::DebugPuts 2 "== test \[$::localhost\]:$port $testmode =="
set ::parent [thread::id]
# helper thread creating async connection and initiating transfer (detach) to parent:
set ::helper [thread::create]
@@ -1901,7 +1901,7 @@ proc transf_test {{testmode transfer} {maxIter 1000} {maxTime 10000}} {
}
# parent proc commiting transfer attempt (attach) and checking acquire was successful:
proc transf_parent {fd args} {
- tcltest::DebugPuts 1 "** trma / $::count ** $args **"
+ tcltest::DebugPuts 2 "** trma / $::count ** $args **"
thread::attach $fd
if {"parent-close" in $::testmode} {;# to test close during connect
set ::count $::count
@@ -1928,7 +1928,7 @@ proc transf_test {{testmode transfer} {maxIter 1000} {maxTime 10000}} {
break
}
if {[incr ::count] >= $maxIter} break
- tcltest::DebugPuts 1 "** iter / $::count **"
+ tcltest::DebugPuts 2 "** iter / $::count **"
thread::send -async $::helper [list iteration nr $::count]
}
update
@@ -1937,7 +1937,7 @@ proc transf_test {{testmode transfer} {maxIter 1000} {maxTime 10000}} {
catch {after cancel $tout}
if {$srvsock ne {}} {close $srvsock}
if {[info exists ::helper]} {thread::release -wait $::helper}
- tcltest::DebugPuts 1 "== stop / $::count =="
+ tcltest::DebugPuts 2 "== stop / $::count =="
unset -nocomplain ::count ::testmode ::parent ::helper
}
}