From 1990c76e8d05fcf48cccabb5d2f1a49c3c99ecd1 Mon Sep 17 00:00:00 2001 From: "jan.nijtmans" Date: Fri, 18 Jul 2014 10:00:52 +0000 Subject: Make sure the "sockettest" command is available even when running socket.test individually. --- tests/socket.test | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/tests/socket.test b/tests/socket.test index 8ffd86b..29f1015 100644 --- a/tests/socket.test +++ b/tests/socket.test @@ -60,8 +60,13 @@ # listening at port 2048. If all fails, a message is printed and the tests # using the remote server are not performed. -package require tcltest 2 -namespace import -force ::tcltest::* +if {[lsearch [namespace children] ::tcltest] == -1} { + package require tcltest + namespace import -force ::tcltest::* +} + +::tcltest::loadTestedCommands +catch [list package require -exact Tcltest [info patchlevel]] # Some tests require the Thread package or exec command testConstraint thread [expr {0 == [catch {package require Thread 2.7-}]}] -- cgit v0.12