Log stacktrace when container runtime strategy throws #966
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Test | |
on: | |
push: | |
branches: [ main ] | |
paths-ignore: | |
- 'mkdocs.yml' | |
- 'docs/**' | |
- 'README.md' | |
pull_request: | |
branches: [ main ] | |
paths-ignore: | |
- 'mkdocs.yml' | |
- 'docs/**' | |
- 'README.md' | |
concurrency: | |
group: "${{ github.workflow }}-${{ github.head_ref || github.sha }}" | |
cancel-in-progress: true | |
jobs: | |
smoke-test: | |
name: Smoke test | |
runs-on: ${{ matrix.runner }} | |
strategy: | |
matrix: | |
runner: [ ubuntu-22.04 ] | |
node-version: [ 18.x, 20.x ] | |
steps: | |
- name: Code checkout | |
uses: actions/checkout@v3 | |
- name: Install NodeJS ${{ matrix.node-version }} | |
uses: actions/setup-node@v3 | |
with: | |
node-version: ${{ matrix.node-version }} | |
- name: Install dependencies | |
run: npm ci --omit=optional | |
- name: Build workspaces | |
run: npm run build -ws | |
- name: Remove dev dependencies | |
run: npm prune --omit=dev | |
- name: Run CommonJS module smoke test | |
run: node packages/testcontainers/smoke-test.js | |
- name: Run ES module smoke test | |
run: node packages/testcontainers/smoke-test.mjs | |
test-testcontainers: | |
name: Testcontainers | |
needs: smoke-test | |
strategy: | |
matrix: | |
node-version: [ 18.x, 20.x ] | |
container-runtime: [ docker, podman ] | |
include: | |
- container-runtime: docker | |
runner: ubuntu-22.04 | |
- container-runtime: podman | |
runner: ubuntu-22.04 | |
uses: ./.github/workflows/test-template.yml | |
with: | |
runner: ${{ matrix.runner }} | |
node-version: ${{ matrix.node-version }} | |
container-runtime: ${{ matrix.container-runtime }} | |
workspace: packages/testcontainers | |
list-modules: | |
name: List modules | |
runs-on: ubuntu-22.04 | |
needs: test-testcontainers | |
outputs: | |
modules: ${{ steps.list_modules.outputs.modules }} | |
steps: | |
- uses: actions/checkout@v2 | |
- id: list_modules | |
run: echo "modules=$(ls packages/modules | jq -cnR '[inputs | select(length>0) | select(. != "couchbase")]')" >> $GITHUB_OUTPUT | |
test-modules: | |
name: Module (${{ matrix.module }}) | |
needs: [ test-testcontainers, list-modules ] | |
strategy: | |
matrix: | |
node-version: [ 18.x, 20.x ] | |
container-runtime: [ docker, podman ] | |
include: | |
- container-runtime: docker | |
runner: ubuntu-22.04 | |
- container-runtime: podman | |
runner: ubuntu-22.04 | |
module: ${{ fromJson(needs.list-modules.outputs.modules) }} | |
uses: ./.github/workflows/test-template.yml | |
with: | |
runner: ${{ matrix.runner }} | |
node-version: ${{ matrix.node-version }} | |
container-runtime: ${{ matrix.container-runtime }} | |
workspace: packages/modules/${{ matrix.module }} |