Skip to content

Commit

Permalink
Merge pull request #417 from libos-nuse/fix-pipe-test
Browse files Browse the repository at this point in the history
lkl: fix pipe test to avoid long wait
  • Loading branch information
thehajime authored Feb 10, 2018
2 parents cfcfa8f + b5a39e1 commit c2c11e5
Showing 1 changed file with 5 additions and 6 deletions.
11 changes: 5 additions & 6 deletions tools/lkl/tests/net.sh
Original file line number Diff line number Diff line change
Expand Up @@ -58,10 +58,6 @@ setup_backend()
"loopback")
;;
"pipe")
if [ -n "$VALGRIND" ]; then
echo "pipe test with valgrind takes so long: skip"
return $TEST_SKIP
fi
if [ -z $(lkl_test_cmd which mkfifo) ]; then
echo "no mkfifo command"
return $TEST_SKIP
Expand Down Expand Up @@ -126,14 +122,17 @@ run_tests()
lkl_test_exec $script_dir/net-test --backend pipe \
--ifname "$fifo1|$fifo2" \
--ip $(ip_host) --netmask-len $TEST_IP_NETMASK \
--sleep 30 >/dev/null &
--sleep 1800 >/dev/null &
cp $script_dir/net-test $script_dir/net-test2

sleep 10
lkl_test_exec $script_dir/net-test2 --backend pipe \
--ifname "$fifo2|$fifo1" \
--ip $(ip_lkl) --netmask-len $TEST_IP_NETMASK \
--dst $(ip_host)
rm -f $script_dir/net-test2
wait
kill $!
wait $! 2>/dev/null
;;
"tap")
lkl_test_exec $script_dir/net-test --backend tap \
Expand Down

0 comments on commit c2c11e5

Please sign in to comment.