52 lines
1.4 KiB
YAML
52 lines
1.4 KiB
YAML
name: Tests
|
|
|
|
on:
|
|
push:
|
|
branches: ["develop", "release-*"]
|
|
pull_request:
|
|
|
|
concurrency:
|
|
group: ${{ github.workflow }}-${{ github.ref }}
|
|
cancel-in-progress: true
|
|
|
|
jobs:
|
|
# XXX When complement with workers is stable, move this back into the standard
|
|
# "complement" matrix above.
|
|
#
|
|
# See https://github.com/matrix-org/synapse/issues/13161
|
|
complement-workers:
|
|
if: "${{ !failure() && !cancelled() }}"
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
- name: Run actions/checkout@v2 for synapse
|
|
uses: actions/checkout@v2
|
|
with:
|
|
path: synapse
|
|
|
|
- name: Prepare Complement's Prerequisites
|
|
run: synapse/.ci/scripts/setup_complement_prerequisites.sh
|
|
|
|
- run: |
|
|
set -o pipefail
|
|
synapse/scripts-dev/complement.sh --build-only
|
|
while :; do
|
|
(POSTGRES=1 WORKERS=1 SYNAPSE_TEST_LOG_LEVEL=DEBUG COMPLEMENT_DIR=`pwd`/complement synapse/scripts-dev/complement.sh -f -json 2>&1 | gotestfmt | tee /tmp/xxx) || true
|
|
if grep "❌ TestWriteMDirectAccountData" /tmp/xxx; then
|
|
break
|
|
fi
|
|
done
|
|
shell: bash
|
|
name: Run Complement Tests
|
|
|
|
# a job which marks all the other jobs as complete, thus allowing PRs to be merged.
|
|
tests-done:
|
|
if: ${{ always() }}
|
|
needs:
|
|
- complement-workers
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: matrix-org/done-action@v2
|
|
with:
|
|
needs: ${{ toJSON(needs) }}
|