test: ✅ add landing snapshot #234
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 & Deploy | |
| on: | |
| push: | |
| branches: | |
| - main | |
| pull_request: | |
| permissions: | |
| actions: read | |
| contents: read | |
| concurrency: | |
| group: ${{ github.workflow }}-${{ github.ref }} | |
| cancel-in-progress: ${{ github.ref == 'refs/heads/main' }} | |
| env: | |
| NX_CLOUD_ACCESS_TOKEN: ${{ secrets.NX_CLOUD_ACCESS_TOKEN }} | |
| jobs: | |
| test-and-deploy: | |
| name: 🚀 Test & Deploy | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| with: | |
| fetch-depth: 0 | |
| - uses: actions/setup-node@v3 | |
| with: | |
| node-version: 21 | |
| - uses: oven-sh/setup-bun@v1 | |
| with: | |
| bun-version: latest | |
| - name: Install Playwright Browsers | |
| run: npx playwright chrome --with-deps | |
| - run: bun install --frozen-lockfile --ignore-scripts | |
| - uses: nrwl/nx-set-shas@v4 | |
| - run: bunx nx-cloud start-ci-run --distribute-on="3 linux-large-js-bun" | |
| - run: bunx nx-cloud record -- nx format:check | |
| - run: bunx nx affected -t build lint test e2e | |
| - name: 🔐 Set up service account | |
| if: github.ref == 'refs/heads/main' | |
| env: | |
| FIREBASE_SERVICE_ACCOUNT_MARMICODE_COOKBOOK: ${{ secrets.FIREBASE_SERVICE_ACCOUNT_MARMICODE_COOKBOOK }} | |
| run: | | |
| echo $FIREBASE_SERVICE_ACCOUNT_MARMICODE_COOKBOOK > ~/.firebase-sa.json | |
| echo "GOOGLE_APPLICATION_CREDENTIALS=$HOME/.firebase-sa.json" >> "$GITHUB_ENV" | |
| - name: 🚀 Deploy | |
| if: github.ref == 'refs/heads/main' | |
| run: bunx nx affected -t deploy --no-agents | |
| - uses: actions/upload-artifact@v4 | |
| if: ${{ !cancelled() }} | |
| with: | |
| name: playwright-report | |
| path: dist/.playwright/apps/cookbook/playwright-report/ | |
| retention-days: 30 |