Debian Codegraph @

scripts/travis-runtest

raw
1 #!/bin/bash
2
3 PATH=/home/`whoami`/.local/bin:$PATH
4 DIR=$(readlink -f .)
5 # Stop on error
6 set -e
7 # Echo all commands to Travis log
8 set -x
9
10 ./ibsim/ibsim -s net-examples/net --no-console &
11 IBSIM_PID=$!
12 # Give some time for the network to start
13 sleep 2
14
15 TMPDIR=$(mktemp -d)
16 LD_PRELOAD=$DIR/umad2sim/libumad2sim.so OSM_TMP_DIR=$TMPDIR OSM_CACHE_DIR=$TMPDIR opensm -f osm.log &
17 OSM_PID=$!
18 # Give time for the SM to start
19 sleep 2
20
21 LD_PRELOAD=$DIR/umad2sim/libumad2sim.so $DIR/tests/subnet_discover
22 LD_PRELOAD=$DIR/umad2sim/libumad2sim.so $DIR/tests/mcast_storm rereg joins leave
23
24 # Kill all pending processes
25 kill -9 $OSM_PID $IBSIM_PID