diff --git a/.github/workflows/run_test_cases.yaml b/.github/workflows/run_test_cases.yaml index 76480acc3..591152091 100644 --- a/.github/workflows/run_test_cases.yaml +++ b/.github/workflows/run_test_cases.yaml @@ -105,6 +105,21 @@ jobs: permissions: contents: read + env: + DOCKER_CT_RUNNER_IMAGE: "ghcr.io/emqx/emqx-builder/${{ matrix.builder }}:${{ matrix.elixir }}-${{ matrix.otp }}-ubuntu22.04" + MONGO_TAG: "5" + MYSQL_TAG: "8" + PGSQL_TAG: "13" + REDIS_TAG: "7.0" + INFLUXDB_TAG: "2.5.0" + TDENGINE_TAG: "3.0.2.4" + OPENTS_TAG: "9aa7f88" + MINIO_TAG: "RELEASE.2023-03-20T20-16-18Z" + PROFILE: ${{ matrix.profile }} + SUITEGROUP: ${{ matrix.suitegroup }} + ENABLE_COVER_COMPILE: 1 + CT_COVER_EXPORT_PREFIX: ${{ matrix.profile }}-${{ matrix.otp }}-sg${{ matrix.suitegroup }} + steps: - uses: actions/download-artifact@c850b930e6ba138125429b7e5c93fc707a7f8427 # v4.1.4 with: @@ -112,41 +127,40 @@ jobs: - name: extract artifact run: | unzip -o -q ${{ matrix.profile }}.zip - git config --global --add safe.directory "$GITHUB_WORKSPACE" # produces $PROFILE---sg.coverdata - name: run common tests - env: - DOCKER_CT_RUNNER_IMAGE: "ghcr.io/emqx/emqx-builder/${{ matrix.builder }}:${{ matrix.elixir }}-${{ matrix.otp }}-ubuntu22.04" - MONGO_TAG: "5" - MYSQL_TAG: "8" - PGSQL_TAG: "13" - REDIS_TAG: "7.0" - INFLUXDB_TAG: "2.5.0" - TDENGINE_TAG: "3.0.2.4" - OPENTS_TAG: "9aa7f88" - MINIO_TAG: "RELEASE.2023-03-20T20-16-18Z" - PROFILE: ${{ matrix.profile }} - SUITEGROUP: ${{ matrix.suitegroup }} - ENABLE_COVER_COMPILE: 1 - CT_COVER_EXPORT_PREFIX: ${{ matrix.profile }}-${{ matrix.otp }}-sg${{ matrix.suitegroup }} run: ./scripts/ct/run.sh --ci --app ${{ matrix.app }} - name: make cover - env: - PROFILE: ${{ matrix.profile }} - ENABLE_COVER_COMPILE: 1 - CT_COVER_EXPORT_PREFIX: ${{ matrix.profile }}-${{ matrix.otp }}-sg${{ matrix.suitegroup }} - run: make cover + run: | + ./scripts/ct/run.sh --ci --app ${{ matrix.app }} --only-up + docker exec \ + -e IS_CI="$IS_CI" \ + -e PROFILE="$PROFILE" \ + -e SUITEGROUP="${SUITEGROUP:-}" \ + -e ENABLE_COVER_COMPILE="${ENABLE_COVER_COMPILE:-}" \ + -e CT_COVER_EXPORT_PREFIX="${CT_COVER_EXPORT_PREFIX:-}" \ + -e BUILD_WITHOUT_QUIC=1 \ + -t erlang \ + bash -c "make cover" + ./scripts/ct/run.sh --ci --app ${{ matrix.app }} --stop + - name: send to coveralls if: github.repository == 'emqx/emqx' - env: - PROFILE: ${{ matrix.profile }} - ENABLE_COVER_COMPILE: 1 - CT_COVER_EXPORT_PREFIX: ${{ matrix.profile }}-${{ matrix.otp }}-sg${{ matrix.suitegroup }} - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - run: make coveralls + run: | + ./scripts/ct/run.sh --ci --app ${{ matrix.app }} --only-up + docker exec \ + -e IS_CI="$IS_CI" \ + -e PROFILE="$PROFILE" \ + -e SUITEGROUP="${SUITEGROUP:-}" \ + -e ENABLE_COVER_COMPILE="${ENABLE_COVER_COMPILE:-}" \ + -e CT_COVER_EXPORT_PREFIX="${CT_COVER_EXPORT_PREFIX:-}" \ + -e BUILD_WITHOUT_QUIC=1 \ + -t erlang \ + bash -c "make coveralls" + ./scripts/ct/run.sh --ci --app ${{ matrix.app }} --stop - name: get coveralls logs if: failure() @@ -264,3 +278,4 @@ jobs: uses: coverallsapp/github-action@3dfc5567390f6fa9267c0ee9c251e4c8c3f18949 # v2.2.3 with: parallel-finished: true +