2018-12-18 02:08:53 +01:00
|
|
|
#!/usr/bin/env bash
|
2016-07-18 23:22:10 +02:00
|
|
|
|
2018-12-10 08:05:16 +01:00
|
|
|
source tools/ci/activate-venv
|
2017-09-04 06:15:20 +02:00
|
|
|
echo "Test suite is running under $(python --version)."
|
2016-07-18 23:22:10 +02:00
|
|
|
|
2015-10-15 01:47:42 +02:00
|
|
|
set -e
|
|
|
|
set -x
|
2016-07-18 23:22:10 +02:00
|
|
|
|
2020-10-15 04:55:57 +02:00
|
|
|
./tools/lint --groups=backend --skip=gitlint,mypy # gitlint disabled because flaky
|
2017-03-10 05:21:03 +01:00
|
|
|
./tools/test-tools
|
2019-05-09 03:25:16 +02:00
|
|
|
# We need to pass a parallel level to test-backend because CircleCI's
|
|
|
|
# docker setup means the auto-detection logic sees the ~36 processes
|
|
|
|
# the Docker host has, not the ~2 processes of resources we're
|
|
|
|
# allocated.
|
2020-08-27 01:56:36 +02:00
|
|
|
./tools/test-backend --coverage --include-webhooks --no-cov-cleanup --ban-console-output --parallel=6
|
2017-08-27 22:39:58 +02:00
|
|
|
|
|
|
|
# We run mypy after the backend tests so we get output from the
|
|
|
|
# backend tests, which tend to uncover more serious problems, first.
|
2017-09-26 23:38:56 +02:00
|
|
|
./tools/run-mypy --version
|
2019-08-07 03:55:10 +02:00
|
|
|
./tools/run-mypy
|
2017-08-27 22:39:58 +02:00
|
|
|
|
2016-01-10 05:15:19 +01:00
|
|
|
./tools/test-migrations
|
2018-08-10 00:39:15 +02:00
|
|
|
./tools/setup/optimize-svg
|
2020-04-21 19:01:54 +02:00
|
|
|
./tools/setup/generate_integration_bots_avatars.py --check-missing
|
2018-12-05 21:39:15 +01:00
|
|
|
# In CI, we only test links we control in test-documentation to avoid flakes
|
|
|
|
./tools/test-documentation --skip-external-links
|
2018-12-22 13:02:32 +01:00
|
|
|
./tools/test-help-documentation --skip-external-links
|
2017-01-26 01:42:17 +01:00
|
|
|
./tools/test-api
|
2020-04-23 00:02:18 +02:00
|
|
|
# Currently our compiled requirements files will differ for different python versions
|
|
|
|
# so we will run test-locked-requirements only for Bionic.
|
|
|
|
# ./tools/test-locked-requirements
|
2020-03-27 03:14:02 +01:00
|
|
|
# ./tools/test-run-dev # https://github.com/zulip/zulip/pull/14233
|
2018-06-05 18:23:12 +02:00
|
|
|
|
|
|
|
# This test has been persistently flaky at like 1% frequency, is slow,
|
|
|
|
# and is for a very specific single feature, so we don't run it by default:
|
|
|
|
# ./tools/test-queue-worker-reload
|
2017-07-25 04:37:23 +02:00
|
|
|
|
2017-07-25 04:46:15 +02:00
|
|
|
# NB: Everything here should be in `tools/test-all`. If there's a
|
|
|
|
# reason not to run it there, it should be there as a comment
|
|
|
|
# explaining why.
|
2020-04-24 11:25:54 +02:00
|
|
|
|
|
|
|
# This final check looks for untracked files that may have been
|
|
|
|
# created by test-backend or provision.
|
|
|
|
untracked="$(git ls-files --exclude-standard --others)"
|
|
|
|
if [ -n "$untracked" ]; then
|
|
|
|
printf >&2 "Error: untracked files:\n%s\n" "$untracked"
|
|
|
|
exit 1
|
|
|
|
fi
|