forked from AlexsLemonade/refinebio
-
Notifications
You must be signed in to change notification settings - Fork 0
/
run_all_tests.sh
executable file
·27 lines (24 loc) · 953 Bytes
/
run_all_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
#!/bin/bash
# Runs all common and app specific tests.
# End to end tests require Nomad to be running for the test environment.
# This can be done with:
# sudo -E ./run_nomad.sh -e test
# This should mirror what happens in the CircleCI config (.circleci/config).
# Ensure that Nomad is running first
# Double w in `ps` will cause the columns to never be truncated regardless of environment.
if ! ps auxww | grep test_nomad | grep -v grep > /dev/null; then
echo "You must start the nomad test environment first with" >&2
echo "sudo -E ./run_nomad.sh -e test" >&2
exit 1
# Then ensure postgres is running
elif ! docker ps | tail -n +2 | awk '{ print $NF }' | grep drdb > /dev/null; then
echo "You must start Postgres first with:" >&2
echo "./run_postgres.sh" >&2
exit 1
fi
mkdir -p test_volume && chmod -R a+rw test_volume
./update_models.sh
./api/run_tests.sh
./common/run_tests.sh
./foreman/run_tests.sh
./workers/run_tests.sh