chore(deps): update all non-major dependencies #2111
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: Cypress Tests | |
on: | |
push: | |
branches: | |
- main | |
pull_request: | |
types: | |
- opened | |
- reopened | |
- synchronize | |
- ready_for_review | |
jobs: | |
build: | |
name: Build UI | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-node@v4 | |
with: | |
node-version: 20 | |
cache: yarn | |
- name: Install Vercel CLI | |
run: npm install --global vercel@latest | |
- run: vercel env pull --yes --environment=development --token=${{ secrets.VERCEL_TOKEN }} .env | |
env: | |
VERCEL_ORG_ID: ${{ secrets.VERCEL_ORG_ID }} | |
VERCEL_PROJECT_ID: ${{ secrets.VERCEL_PROJECT_ID }} | |
# Install yarn dependencies and cache for later | |
# pass runTests: false to the Cypress GitHub Action to instruct it only to install and cache Cypress and npm dependencies without running the tests | |
# https://docs.cypress.io/guides/continuous-integration/github-actions#Parallelization | |
- uses: cypress-io/github-action@v4 | |
with: | |
runTests: false | |
- run: yarn build | |
- name: Save build folder | |
uses: actions/upload-artifact@v4 | |
with: | |
name: build | |
if-no-files-found: error | |
include-hidden-files: true | |
path: .next | |
tests: | |
name: Run Cypress Tests | |
timeout-minutes: 15 | |
runs-on: ubuntu-latest | |
needs: build | |
strategy: | |
fail-fast: false | |
matrix: | |
containers: [1, 2, 3, 4, 5] | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-node@v4 | |
with: | |
node-version: 20 | |
cache: yarn | |
- name: Download the build folders | |
uses: actions/download-artifact@v4 | |
with: | |
name: build | |
path: .next | |
- name: Install Vercel CLI | |
run: npm install --global vercel@latest | |
- run: vercel env pull --yes --environment=development --token=${{ secrets.VERCEL_TOKEN }} .env | |
env: | |
VERCEL_ORG_ID: ${{ secrets.VERCEL_ORG_ID }} | |
VERCEL_PROJECT_ID: ${{ secrets.VERCEL_PROJECT_ID }} | |
- name: Load environment variables from .env | |
uses: xom9ikk/dotenv@v2 | |
- name: Cypress tests | |
uses: cypress-io/github-action@v4 | |
with: | |
start: yarn start | |
wait-on: "http://localhost:3000" | |
wait-on-timeout: 120 | |
browser: chrome | |
record: true | |
parallel: true | |
config-file: cypress.config.ts | |
command-prefix: ${{ github.event.pull_request.draft == false && 'percy exec --parallel -- npx' || '' }} | |
group: "Skylark UI" | |
env: | |
CYPRESS_RECORD_KEY: ${{ secrets.CYPRESS_RECORD_KEY }} | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
PERCY_TOKEN: ${{ secrets.PERCY_TOKEN }} | |
PERCY_PARALLEL_TOTAL: 5 | |
# overwrite commit message sent to Dashboard | |
COMMIT_INFO_MESSAGE: ${{ github.event.pull_request.title }} | |
# re-enable PR comment bot | |
COMMIT_INFO_SHA: ${{ github.event.pull_request.head.sha }} |