summaryrefslogtreecommitdiff
path: root/test/script/output.et
blob: d3f0eea285a87a39bbb59449ff28fe20defdc646 (plain)
1
2
3
4
5
6
7
8
9
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
module output

asset scripts:
    path: ../asset/output

test FlushOutput:
    spawn as p 
    with p:
        send "load ${scripts.path}/flush.et"
        expect /load-done/

        send "run Test"
        expect /child-stdout p a/
        expect /child-stdout p b/
        expect /child-stdout p c/
        expect /child-stdout p d/
        expect /child-stdout p e/
        expect /match p e/
        expect /ignored p b/
        expect /ignored p c/
        expect /ignored p d/
        expect /match p a/
        expect /match-fail expect.*/

        expect /(run-.*)/ capture done
        guard (done == "run-failed")

test IgnoreOutput:
    spawn as p 
    with p:
        send "load ${scripts.path}/ignore.et"
        expect /load-done/

        send "run Test"
        expect /child-stdout p a/
        expect /child-stdout p b/
        expect /child-stdout p c/
        expect /child-stdout p d/
        expect /child-stdin p x/
        expect /child-stdout p e/
        expect /child-stdout p F/
        expect /child-stdout p g/
        expect /child-stdout p H/
        expect /match p d/
        expect /ignored p b/
        expect /ignored p c/
        expect /match p a/
        expect /ignored p e/
        expect /match p H/
        expect /ignored p g/
        expect /match p F/
        expect /match-fail expect.*/

        expect /(run-.*)/ capture done
        guard (done == "run-failed")