Improve timeout error handling and maxFailures behavior #48
Workflow file for this run
This file contains hidden or 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 | |
| pull_request: | |
| workflow_dispatch: | |
| jobs: | |
| check: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - uses: nixbuild/nix-quick-install-action@v34 | |
| - run: nix develop -c deno task check | |
| - run: nix develop -c deno lint | |
| - run: | | |
| nix develop -c deno fmt | |
| git diff --exit-code | |
| test: | |
| runs-on: ubuntu-latest | |
| services: | |
| echo-http: | |
| image: ghcr.io/probitas-test/echo-http:latest | |
| ports: | |
| - 8080:80 | |
| echo-grpc: | |
| image: ghcr.io/probitas-test/echo-grpc:latest | |
| ports: | |
| - 50051:50051 | |
| echo-connectrpc: | |
| image: ghcr.io/probitas-test/echo-connectrpc:latest | |
| ports: | |
| - 8090:8080 | |
| echo-graphql: | |
| image: ghcr.io/probitas-test/echo-graphql:latest | |
| ports: | |
| - 8100:8080 | |
| postgres: | |
| image: postgres:16 | |
| ports: | |
| - 5432:5432 | |
| env: | |
| POSTGRES_DB: testdb | |
| POSTGRES_USER: testuser | |
| POSTGRES_PASSWORD: testpassword | |
| options: >- | |
| --health-cmd "pg_isready -U testuser -d testdb" | |
| --health-interval 10s | |
| --health-timeout 5s | |
| --health-retries 5 | |
| mysql: | |
| image: mysql:8.0 | |
| ports: | |
| - 3306:3306 | |
| env: | |
| MYSQL_ROOT_PASSWORD: rootpassword | |
| MYSQL_DATABASE: testdb | |
| MYSQL_USER: testuser | |
| MYSQL_PASSWORD: testpassword | |
| options: >- | |
| --health-cmd "mysqladmin ping -h localhost -u root -prootpassword" | |
| --health-interval 5s | |
| --health-timeout 5s | |
| --health-retries 10 | |
| denokv: | |
| image: ghcr.io/denoland/denokv | |
| ports: | |
| - 4512:4512 | |
| env: | |
| DENO_KV_SQLITE_PATH: ":memory:" | |
| DENO_KV_ACCESS_TOKEN: testtoken1234 | |
| redis: | |
| image: redis:7 | |
| ports: | |
| - 6379:6379 | |
| options: >- | |
| --health-cmd "redis-cli ping" | |
| --health-interval 5s | |
| --health-timeout 5s | |
| --health-retries 10 | |
| rabbitmq: | |
| image: rabbitmq:3-management | |
| ports: | |
| - 5672:5672 | |
| env: | |
| RABBITMQ_DEFAULT_USER: guest | |
| RABBITMQ_DEFAULT_PASS: guest | |
| options: >- | |
| --health-cmd "rabbitmq-diagnostics check_port_connectivity" | |
| --health-interval 10s | |
| --health-timeout 10s | |
| --health-retries 10 | |
| localstack: | |
| image: localstack/localstack:latest | |
| ports: | |
| - 4566:4566 | |
| env: | |
| SERVICES: sqs | |
| DEBUG: 0 | |
| options: >- | |
| --health-cmd "curl -f http://localhost:4566/_localstack/health || exit 1" | |
| --health-interval 5s | |
| --health-timeout 5s | |
| --health-retries 10 | |
| env: | |
| DENO_KV_ACCESS_TOKEN: testtoken1234 | |
| steps: | |
| # MongoDB is started via action instead of services because: | |
| # - GitHub Actions services don't support custom command options | |
| # - Transactions require replica set mode (--replSet flag) | |
| # - supercharge/mongodb-github-action handles replica set initialization | |
| - uses: supercharge/mongodb-github-action@1.12.0 | |
| with: | |
| mongodb-version: "7.0" | |
| mongodb-replica-set: rs0 | |
| - uses: actions/checkout@v6 | |
| - uses: nixbuild/nix-quick-install-action@v34 | |
| - run: nix develop -c deno task test:coverage | |
| timeout-minutes: 5 | |
| - run: nix develop -c deno task coverage --lcov > coverage.lcov | |
| timeout-minutes: 5 | |
| - uses: codecov/codecov-action@v5 | |
| with: | |
| files: ./coverage.lcov | |
| slug: probitas-test/probitas-packages |