syncing up to c4cf4ee14f1f5232eb07a9ad5174b64c901ee813 #67
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: default | |
on: | |
push: | |
branches: | |
- "**" | |
jobs: | |
check: | |
runs-on: blacksmith-2vcpu-ubuntu-2204 | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-go@v5 | |
with: | |
go-version-file: .go-version | |
- uses: bufbuild/[email protected] | |
with: | |
buf_user: frankgrecojr | |
buf_api_token: ${{ secrets.BUF_APIKEY }} | |
github_token: ${{ secrets.GITHUB_TOKEN }} | |
- run: make deps | |
- uses: pre-commit/[email protected] | |
- uses: azure/setup-helm@v4 | |
with: | |
version: "v3.9.0" | |
- run: helm repo add bitnami https://charts.bitnami.com/bitnami | |
- run: make helm-template | |
- uses: actions/setup-node@v4 | |
with: | |
node-version-file: .nvmrc | |
- run: make check | |
working-directory: workers/javascript | |
- uses: actions/setup-python@v5 | |
with: | |
python-version-file: ./workers/python/.python-version | |
- run: | | |
make deps-dev | |
CHECK=true make fmt | |
working-directory: workers/python | |
test-go: | |
runs-on: blacksmith-4vcpu-ubuntu-2204 | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-go@v5 | |
with: | |
go-version-file: .go-version | |
- name: unit tests | |
run: make test-unit GO_TEST_ARGS="-v -cover -covermode atomic -race" | |
- name: integration tests | |
run: make test-integration | |
- name: upload coverage report to codecov | |
uses: codecov/codecov-action@v4 | |
with: | |
name: ${{ github.job }} | |
fail_ci_if_error: true | |
flags: test-go | |
token: ${{ secrets.CODECOV_TOKEN }} | |
test-js: | |
runs-on: blacksmith-8vcpu-ubuntu-2204 | |
timeout-minutes: 30 | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-node@v4 | |
with: | |
node-version-file: .nvmrc | |
- run: | | |
make build | |
npx pnpm --filter @superblocks/worker.js test:unit | |
npx pnpm --no-bail --filter "@superblocksteam/*" --filter "!@superblocksteam/gsheets" test -- --testPathIgnorePatterns "(e2e|integration|local).test.ts" | |
working-directory: workers/javascript | |
- uses: codecov/codecov-action@v4 | |
with: | |
name: ${{ github.job }} | |
fail_ci_if_error: true | |
flags: test-js | |
token: ${{ secrets.CODECOV_TOKEN }} | |
directory: workers/javascript | |
test-py: | |
runs-on: blacksmith-8vcpu-ubuntu-2204 | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-python@v5 | |
with: | |
python-version-file: ./workers/python/.python-version | |
- run: | | |
pip3 install tox | |
make test TOX_EXTRA_ARGS="--cov-report lcov:coverage.out" | |
working-directory: workers/python | |
- uses: codecov/codecov-action@v4 | |
with: | |
name: ${{ github.job }} | |
fail_ci_if_error: true | |
flags: test-py | |
token: ${{ secrets.CODECOV_TOKEN }} | |
directory: workers/python |