summaryrefslogtreecommitdiff
path: root/test/script/network.et
blob: 62006adcb5b45f8247fcf0ce3de5f0fbbc7bee98 (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
module network

asset scripts:
    path: ../asset/network


def run_test_from using p (file):
    guard (file /= "") # TODO: forces (file :: String)
    send "" to p # TODO: forces (p :: Process)

    with p:
        send "load $file"
        expect /load-done/

        send "run Test"
        expect /run-test-result Test (.*)/ capture result
        guard (result == "done")
        expect /run-done/


test DisconnectNode:
    spawn as p
    run_test_from using p "${scripts.path}/disconnect_node.et"


test DisconnectNodes:
    spawn as p
    run_test_from using p "${scripts.path}/disconnect_nodes.et"