Skip to content

Run e2e tests during release workflow #312

Run e2e tests during release workflow

Run e2e tests during release workflow #312

Workflow file for this run

name: Run Tests on Pull Request

Check failure on line 1 in .github/workflows/test-on-pr.yml

View workflow run for this annotation

GitHub Actions / .github/workflows/test-on-pr.yml

Invalid workflow file

(Line: 41, Col: 13): Unrecognized named-value: 'secrets'. Located at position 1 within expression: secrets.CONFIGURATOR_E2E_SALEOR_TOKEN != ''
on:
pull_request:
branches:
- main # or the branch you want to target
jobs:
test:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Install pnpm
uses: pnpm/action-setup@v2
with:
run_install: false
- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version-file: ".nvmrc"
cache: "pnpm"
- name: Install dependencies
run: pnpm install
- name: Type check
run: pnpm run check:ci
- name: Run tests
env:
APP_TOKEN: test-token
SALEOR_API_URL: http://test.example.com
LOG_LEVEL: error
run: pnpm test
- name: Run CLI end-to-end tests
if: ${{ secrets.CONFIGURATOR_E2E_SALEOR_TOKEN != '' }}
env:
CONFIGURATOR_E2E_SALEOR_TOKEN: ${{ secrets.CONFIGURATOR_E2E_SALEOR_TOKEN }}
CONFIGURATOR_E2E_SALEOR_URL: ${{ secrets.CONFIGURATOR_E2E_SALEOR_URL || 'https://sandbox-a.staging.saleor.cloud/graphql/' }}
run: pnpm test:e2e:ci