kill test bots after some time
This commit is contained in:
parent
464d721af6
commit
19aa4e12d5
14
test/test.sh
14
test/test.sh
@ -15,10 +15,20 @@ docker exec -it xmppbot-test bin/ejabberdctl create_room testroom1 conference.lo
|
|||||||
docker exec -it xmppbot-test bin/ejabberdctl create_room testroom2 conference.localhost localhost
|
docker exec -it xmppbot-test bin/ejabberdctl create_room testroom2 conference.localhost localhost
|
||||||
|
|
||||||
# Run xmpp mirror bot
|
# Run xmpp mirror bot
|
||||||
python3 ../xmppmirror &
|
python3 ../xmppmirror & XMPPMIRRORPID=$!
|
||||||
|
|
||||||
# Run xmpp test bot
|
# Run xmpp test bot
|
||||||
python3 testbot
|
python3 testbot & TESTBOTPID=$!
|
||||||
|
|
||||||
|
# Wait for bots to connect
|
||||||
|
sleep 10
|
||||||
|
|
||||||
|
# Wait certain amount of time for every test message in the file
|
||||||
|
for i in $(cat testmsgs); do sleep 5; done
|
||||||
|
|
||||||
|
# Kill bots
|
||||||
|
kill XMPPMIRRORPID
|
||||||
|
kill TESTBOTPID
|
||||||
|
|
||||||
# Stop and remove containter
|
# Stop and remove containter
|
||||||
docker stop xmppbot-test
|
docker stop xmppbot-test
|
||||||
|
Loading…
Reference in New Issue
Block a user