blob: 9f91e2afeb79944962b1f5d0c74ada8ad3f90319 (
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
|
package main
import (
"fmt"
"github.com/edwarnicke/exechelper"
)
func (s *VethsSuite) TestEchoBuiltin() {
srvInstance := "echo-srv-internal"
clnInstance := "echo-cln-internal"
s.assertNil(dockerRun(srvInstance, ""), "failed to start docker (srv)")
defer func() { exechelper.Run("docker stop " + srvInstance) }()
s.assertNil(dockerRun(clnInstance, ""), "failed to start docker (cln)")
defer func() { exechelper.Run("docker stop " + clnInstance) }()
_, err := hstExec("Configure2Veths srv", srvInstance)
s.assertNil(err)
_, err = hstExec("Configure2Veths cln", clnInstance)
s.assertNil(err)
_, err = hstExec("RunEchoSrvInternal private-segment-size 1g fifo-size 4 no-echo", srvInstance)
s.assertNil(err)
o, err := hstExec("RunEchoClnInternal nclients 10000 bytes 1 syn-timeout 100 test-timeout 100 no-return private-segment-size 1g fifo-size 4", clnInstance)
s.assertNil(err)
fmt.Println(o)
}
|