ci: clearer check labels and split lint jobs #5
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: tests | |
| on: | |
| push: | |
| branches: [main] | |
| pull_request: {} | |
| jobs: | |
| test: | |
| name: node ${{ matrix.node-version }} | |
| strategy: | |
| matrix: | |
| node-version: [20, 22] | |
| runs-on: ubuntu-22.04 | |
| services: | |
| postgres: | |
| image: postgres:13 | |
| env: | |
| POSTGRES_DB: indexer_tests | |
| POSTGRES_USER: testuser | |
| POSTGRES_PASSWORD: testpass | |
| ports: | |
| - 5432:5432 | |
| options: >- | |
| --health-cmd pg_isready | |
| --health-interval 10s | |
| --health-timeout 5s | |
| --health-retries 5 | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: update OS | |
| run: | | |
| sudo apt-get update | |
| sudo apt install -y --no-install-recommends gcc g++ make build-essential | |
| - name: Use Node.js ${{ matrix.node-version }} | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: ${{ matrix.node-version }} | |
| registry-url: https://registry.npmjs.org/ | |
| cache: 'yarn' | |
| - run: yarn install --frozen-lockfile | |
| env: | |
| NODE_AUTH_TOKEN: ${{ secrets.npm_token }} | |
| - run: yarn test:ci | |
| env: | |
| POSTGRES_TEST_HOST: localhost | |
| POSTGRES_TEST_DATABASE: indexer_tests | |
| POSTGRES_TEST_USERNAME: testuser | |
| POSTGRES_TEST_PASSWORD: testpass | |
| NODE_OPTIONS: "--dns-result-order=ipv4first" | |
| INDEXER_TEST_JRPC_PROVIDER_URL: ${{ secrets.TESTS_RPC_PROVIDER }} | |
| INDEXER_TEST_API_KEY: ${{ secrets.TESTS_API_KEY }} |