Skip to content

Commit

Permalink
Pin to older version of pixelmatch for browser test compatibility
Browse files Browse the repository at this point in the history
  • Loading branch information
Xon committed Aug 6, 2024
1 parent f8205f2 commit 1ba405b
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion .github/actions-scripts/puppeteer.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ const path = require('path');
const { once } = require('events');

const puppeteer = require('puppeteer');
const pixelmatch = import('pixelmatch');
const pixelmatch = require('pixelmatch');
const { PNG } = require('pngjs');

const server = require('../../server');
Expand Down
2 changes: 1 addition & 1 deletion .github/actions-scripts/selenium.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ const path = require('path');
const { readFileSync, writeFileSync, mkdirSync } = require('fs');
const { once } = require('events');

const pixelmatch = import('pixelmatch');
const pixelmatch = require('pixelmatch')
const { PNG } = require('pngjs');
const {
Builder,
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/browsers.yml
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ jobs:
- run: echo "$env:ChromeWebDriver" >> $GITHUB_PATH
if: matrix.browser == 'chrome' && matrix.os == 'windows-latest'

- run: npm i --no-optional --no-audit selenium-webdriver pixelmatch pngjs
- run: npm i --no-optional --no-audit selenium-webdriver pixelmatch@5.3.0 pngjs
- run: node .github/actions-scripts/selenium.js
env:
BROWSER: ${{ matrix.browser }}
Expand Down Expand Up @@ -118,7 +118,7 @@ jobs:
env:
CYPRESS_INSTALL_BINARY: 0
HUSKY_SKIP_INSTALL: true
- run: npm i --no-optional --no-audit puppeteer pixelmatch pngjs
- run: npm i --no-optional --no-audit puppeteer pixelmatch@5.3.0 pngjs
- run: node .github/actions-scripts/puppeteer.js
env:
PORT: 0
Expand Down

0 comments on commit 1ba405b

Please sign in to comment.