summaryrefslogtreecommitdiff
path: root/test/network.test
diff options
context:
space:
mode:
Diffstat (limited to 'test/network.test')
-rw-r--r--test/network.test15
1 files changed, 13 insertions, 2 deletions
diff --git a/test/network.test b/test/network.test
index 0f49a1e..a670f35 100644
--- a/test/network.test
+++ b/test/network.test
@@ -189,8 +189,8 @@ test ServiceStreams:
spawn as p2
send "create-identity Device1" to p1
send "create-identity Device2" to p2
- send "start-server services $services" to p1
- send "start-server services $services" to p2
+ send "start-server services $services test-log" to p1
+ send "start-server services $services test-log" to p2
expect from p1:
/peer 1 addr ${p2.node.ip} 29665/
/peer 1 id Device2/
@@ -202,6 +202,8 @@ test ServiceStreams:
expect /test-stream-open-done 1 ([0-9]+)/ from p1 capture stream1
expect /test-stream-open-from 1 $stream1/ from p2
+ expect /net-ostream-open ${p2.node.ip} 29665 1 1/ from p1
+
send "test-stream-send 1 $stream1 hello" to p1
expect /test-stream-send-done 1 $stream1/ from p1
expect /test-stream-received 1 $stream1 0 hello/ from p2
@@ -210,12 +212,18 @@ test ServiceStreams:
expect /test-stream-close-done 1 $stream1/ from p1
expect /test-stream-closed-from 1 $stream1 1/ from p2
+ expect /net-ostream-close-send ${p2.node.ip} 29665 1/ from p1
+ expect /net-ostream-close-ack ${p2.node.ip} 29665 1 0/ from p1
+
send "test-stream-open 1 8" to p2
expect /test-stream-open-done 1 ([0-9]+) ([0-9]+) ([0-9]+) ([0-9]+) ([0-9]+) ([0-9]+) ([0-9]+) ([0-9]+)/ from p2 capture stream2_1, stream2_2, stream2_3, stream2_4, stream2_5, stream2_6, stream2_7, stream2_8
expect /test-stream-open-from 1 $stream2_1 $stream2_2 $stream2_3 $stream2_4 $stream2_5 $stream2_6 $stream2_7 $stream2_8/ from p1
let streams2 = [ stream2_1, stream2_2, stream2_3, stream2_4, stream2_5, stream2_6, stream2_7, stream2_8 ]
with p2:
+ expect /net-ostream-open ${p1.node.ip} 29665 . 8/
+ flush matching /net-ostream-open ${p1.node.ip} 29665.*/
+
for i in [ 1..20 ]:
for s in streams2:
send "test-stream-send 1 $s hello$i"
@@ -226,6 +234,9 @@ test ServiceStreams:
send "test-stream-close 1 $s"
for s in streams2:
expect /test-stream-close-done 1 $s/
+
+ expect /net-ostream-close-ack ${p1.node.ip} 29665 . 0/
+ flush matching /net-ostream-close-[a-z]* ${p1.node.ip} 29665.*/
with p1:
for i in [ 1..20 ]:
for s in streams2: