Eskil

Diff
Login

Differences From Artifact [19ef7788b8]:

To Artifact [4748de2597]:


10
11
12
13
14
15
16
17

18
19
20
21
22
23




24


25



















26
27
28
29
30

31
32
33
10
11
12
13
14
15
16

17
18
19
20
21
22
23
24
25
26
27

28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58







-
+






+
+
+
+
-
+
+

+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+





+




lappend auto_path eskil.vfs/lib

package require tcltest 2.2
namespace import tcltest::*
tcltest::configure -verbose "body error"
#testConstraint knownbug 1
#tcltest::configure -match eskil-1.*
#tcltest::configure -match blocks-*

package require Tk
wm withdraw .

set ::eskil_testsuite 1

if {[file exists src/eskil.tcl_i]} {
    puts "Running with code coverage"
    source src/eskil.tcl_i
} else {
source src/eskil.tcl
    source src/eskil.tcl
}
Init

# Helpers to temporarily stub things out
set ::stubs {}
proc stub {name argv body} {
    if {[info commands _stub_$name] eq ""} {
        rename $name _stub_$name
    }
    proc $name $argv $body
    lappend ::stubs $name
}

proc clearstub {} {
    foreach name $::stubs {
        rename $name {}
        rename _stub_$name $name
    }
    set ::stubs {}
}


puts "Running Tests"

foreach test [glob -nocomplain $testDir/*.test] {
    source $test
    clearstub
}

exit