diff --git a/.github/workflows/lint-and-test.yml b/.github/workflows/lint-and-test.yml index 7c575c3d4..6a8820000 100644 --- a/.github/workflows/lint-and-test.yml +++ b/.github/workflows/lint-and-test.yml @@ -11,7 +11,6 @@ on: jobs: lint: - continue-on-error: true runs-on: ubuntu-latest steps: - uses: actions/checkout@v3 @@ -27,7 +26,7 @@ jobs: - name: Validate commits with commitlint run: npx commitlint --from ${{ inputs.commit-from }} --to ${{ inputs.commit-to }} --verbose - tests: + unit-tests: runs-on: ubuntu-latest needs: lint env: @@ -40,13 +39,21 @@ jobs: - name: Install deps run: npm ci - name: Run unit tests - continue-on-error: true run: npm run test - - name: Install Playwright Browsers - run: npx playwright install chromium --with-deps - - name: Run Playwright tests - continue-on-error: true - run: npm run e2e + + e2e-tests: + runs-on: ubuntu-latest + needs: lint + env: + CI: true + steps: + - uses: actions/checkout@v3 + - uses: actions/setup-node@v3 + with: + node-version: 18 + - run: npm ci + - run: npx playwright install chromium --with-deps + - run: npm run e2e - uses: actions/upload-artifact@v3 if: always() with: diff --git a/.github/workflows/pull-request.yml b/.github/workflows/pull-request.yml index b3b28d453..a8277bcb4 100644 --- a/.github/workflows/pull-request.yml +++ b/.github/workflows/pull-request.yml @@ -2,44 +2,10 @@ name: pull-request on: pull_request: branches: [ "master" ] -jobs: - lint: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v3 - with: - fetch-depth: 0 - - uses: actions/setup-node@v3 - with: - node-version: 18 - - name: Install deps - run: npm ci - - name: Eslint checks - run: npx eslint . - - name: Validate PR commits with commitlint - run: npx commitlint --from ${{ github.event.pull_request.head.sha }}~${{ github.event.pull_request.commits }} --to ${{ github.event.pull_request.head.sha }} --verbose - tests: - runs-on: ubuntu-latest - needs: lint - env: - CI: true - steps: - - uses: actions/checkout@v3 - - uses: actions/setup-node@v3 - with: - node-version: 18 - - name: Install deps - run: npm ci - - name: Run unit tests - run: npm run test - - name: Install Playwright Browsers - run: npx playwright install chromium --with-deps - - name: Run Playwright tests - run: npm run e2e - - uses: actions/upload-artifact@v3 - if: always() - with: - name: playwright-report - path: playwright-report/ - retention-days: 30 \ No newline at end of file +jobs: + lint-and-tests: + uses: ./.github/workflows/lint-and-test.yml + with: + commit-from: ${{ github.event.pull_request.head.sha }}~${{ github.event.pull_request.commits }} + commit-to: ${{ github.event.pull_request.head.sha }} \ No newline at end of file diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index ba52d60da..97b6e1dc4 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -162,6 +162,7 @@ jobs: needs: - build-and-deploy - get-issue-id + - write-result-comment if: always() && needs.build-and-deploy.result != 'skipped' runs-on: ubuntu-latest steps: