Skip to content

Commit

Permalink
Chore: make personalization test more robust, report e2e test results…
Browse files Browse the repository at this point in the history
… INTER-320 (#142)

* chore: make personalization test more robust

* ci: add report status job

* ci: add comment
  • Loading branch information
JuroUhlar authored May 24, 2024
1 parent 2e6c42f commit a5da780
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 0 deletions.
11 changes: 11 additions & 0 deletions .github/workflows/production_e2e.yml
Original file line number Diff line number Diff line change
Expand Up @@ -54,3 +54,14 @@ jobs:
name: playwright-report
path: playwright-report/
retention-days: 30
report-status:
needs: e2e
if: always()
# Run always for now to test it out, later we switch to on-failure only
# if: ${{ needs.e2e.result == 'failure' }}
uses: fingerprintjs/dx-team-toolkit/.github/workflows/report-workflow-status.yml@v1
with:
notification_title: 'Production e2e tests on demo.fingerprint.com have {status_message}'
job_status: ${{ needs.e2e.result }}
secrets:
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }}
2 changes: 2 additions & 0 deletions e2e/personalization.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,8 @@ test.describe('Personalization', () => {

await product.getByTestId(PERS_ID.addToCart).click();
await cartItem.getByTestId(CART_ID.cartItemPlusOne).click();
// Confirm the request was successful before reloading the page
await expect(cartItem.getByTestId(CART_ID.cartItemCount)).toHaveText('02');

await page.reload();

Expand Down

0 comments on commit a5da780

Please sign in to comment.