forked from istresearch/scrapy-cluster
-
Notifications
You must be signed in to change notification settings - Fork 0
/
run_online_tests.sh
executable file
·44 lines (40 loc) · 978 Bytes
/
run_online_tests.sh
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
32
33
34
35
36
37
38
39
40
41
42
43
44
#!/bin/bash
# Script for testing Scrapy Clusters online setup
# If all tests pass, then your all components appear to be working correctly
# and integrated with all other components
HOST='localhost'
PORT=6379
if [ $# -ne 2 ]
then
echo "---- Running utils online test with localhost 6379"
echo "Other usage:"
echo " ./bundle.sh <utils_redis_host> <utils_redis_port>"
else
echo "---- Using custom redis host and port for utils online test"
HOST=$1
PORT=$2
fi
cd utils
python tests/tests_online.py -r $HOST -p $PORT
if [ $? -eq 1 ]; then
echo "utils tests failed"
exit 1
fi
cd ../kafka-monitor
python tests/tests_online.py -v
if [ $? -eq 1 ]; then
echo "kafka-monitor tests failed"
exit 1
fi
cd ../redis-monitor
python tests/tests_online.py -v
if [ $? -eq 1 ]; then
echo "redis-monitor tests failed"
exit 1
fi
cd ../crawler
python tests/tests_online.py -v
if [ $? -eq 1 ]; then
echo "crawler tests failed"
exit 1
fi