Skip to content

Commit

Permalink
Use Percy to take snapshots in E2E tests (#2532)
Browse files Browse the repository at this point in the history
  • Loading branch information
swissspidy committed Jul 1, 2020
1 parent b1a4a7b commit 5b0c79d
Show file tree
Hide file tree
Showing 11 changed files with 473 additions and 10 deletions.
8 changes: 2 additions & 6 deletions .github/workflows/continuous-integration-e2e.yml
Original file line number Diff line number Diff line change
Expand Up @@ -69,11 +69,6 @@ jobs:
composer install --prefer-dist --no-suggest --no-progress --no-interaction
env:
CI: true
PUPPETEER_SKIP_CHROMIUM_DOWNLOAD: true

- name: Install Puppeteer with correct browser
run: npm install puppeteer
env:
PUPPETEER_PRODUCT: ${{ matrix.browser }}

- name: Build plugin
Expand All @@ -88,8 +83,9 @@ jobs:
COMPOSE_INTERACTIVE_NO_CLI: true

- name: Run E2E tests
run: npm run test:e2e
run: npm run test:e2e:percy
env:
PERCY_TOKEN: ${{ secrets.PERCY_TOKEN_E2E }}
PUPPETEER_PRODUCT: ${{ matrix.browser }}

- name: Stop Docker environment
Expand Down
2 changes: 1 addition & 1 deletion jest-puppeteer.config.cjs
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,6 @@ module.exports = {
headless: PUPPETEER_HEADLESS !== 'false',
slowMo: Number(PUPPETEER_SLOWMO) || 0,
product: PUPPETEER_PRODUCT,
args: ['--window-size=1680,948'],
args: ['--window-size=1600,1000'], // Same as in percy.config.yml.
},
};
Loading

0 comments on commit 5b0c79d

Please sign in to comment.