Add running turn tests
This commit is contained in:
parent
afbe6868ff
commit
ff1952033f
5
.github/workflows/tests.yml
vendored
5
.github/workflows/tests.yml
vendored
@ -29,6 +29,5 @@ jobs:
|
||||
run: make
|
||||
- name: make check
|
||||
run: make check
|
||||
- name: run
|
||||
run: turnserver &
|
||||
|
||||
- name: apps tests
|
||||
run: cd examples && ./run_tests.sh
|
||||
|
||||
26
examples/run_tests.sh
Executable file
26
examples/run_tests.sh
Executable file
@ -0,0 +1,26 @@
|
||||
#!/bin/bash
|
||||
|
||||
echo 'Running turnserver'
|
||||
../bin/turnserver --use-auth-secret --static-auth-secret=secret --realm=north.gov --allow-loopback-peers --no-cli > /dev/null &
|
||||
echo 'Running peer client'
|
||||
../bin/turnutils_peer -L 127.0.0.1 -L ::1 -L 0.0.0.0 > /dev/null &
|
||||
|
||||
sleep 2
|
||||
|
||||
echo 'Running turn client TCP'
|
||||
../bin/turnutils_uclient -t -e 127.0.0.1 -X -g -u user -W secret -t 127.0.0.1 | grep "start_mclient: tot_send_bytes ~ 1000, tot_recv_bytes ~ 1000" > /dev/null
|
||||
if [ $? -eq 0 ]; then
|
||||
echo OK
|
||||
else
|
||||
echo FAIL
|
||||
exit $?
|
||||
fi
|
||||
|
||||
echo 'Running turn client UDP'
|
||||
../bin/turnutils_uclient -e 127.0.0.1 -X -g -u user -W secret -t 127.0.0.1 | grep "start_mclient: tot_send_bytes ~ 1000, tot_recv_bytes ~ 1000" > /dev/null
|
||||
if [ $? -eq 0 ]; then
|
||||
echo OK
|
||||
else
|
||||
echo FAIL
|
||||
exit $?
|
||||
fi
|
||||
Loading…
Reference in New Issue
Block a user