From 192056900583884bc1f07f371df6478d856ada3b Mon Sep 17 00:00:00 2001 From: Steve Bennett Date: Sat, 30 Oct 2010 15:21:21 +1000 Subject: Overhaul unit test framework Much closer to tcltest now, including constraints. Try to get all appropriate tests running under both Jim and Tcl. Signed-off-by: Steve Bennett --- tests/misc.test | 14 ++++---------- 1 file changed, 4 insertions(+), 10 deletions(-) (limited to 'tests/misc.test') diff --git a/tests/misc.test b/tests/misc.test index 0dc1112..ad9dd35 100644 --- a/tests/misc.test +++ b/tests/misc.test @@ -1,6 +1,6 @@ -source testing.tcl +source [file dirname [info script]]/testing.tcl -section "Regression Testing" +needs constraint jim catch {unset a b} test regr-1.1 "Double dereference arrays" { @@ -20,7 +20,7 @@ test regr-1.2 "Reference count shared literals" { return 1 } {1} -test regr-1.3 "Invalid for expression" { +test regr-1.3 "Invalid for expression" jim { # Crashes with invalid expression catch { for {set i 0} {$i < n} {incr i} { @@ -41,11 +41,9 @@ test regr-1.5 "lassign with empty list" { info exists c } {1} -section "I/O Testing" - test io-1.1 "Read last line with no newline" { set lines 0 - set f [open testio.in] + set f [open $testdir/testio.in] while {[gets $f buf] >= 0} { incr lines } @@ -53,8 +51,6 @@ test io-1.1 "Read last line with no newline" { list $lines } {2} -section "unset" - set g1 1 set g2 2 array set g3 {4 5 6 7} @@ -111,8 +107,6 @@ proc test_unset {} { test_unset -section "lrepeat" - test lrepeat-1.1 "Basic tests" { lrepeat 1 a } {a} -- cgit v1.1