Skip to content

Commit

Permalink
Setup image snapshot testing with puppeteer and jest-image-snapshot
Browse files Browse the repository at this point in the history
  • Loading branch information
mauriciopoppe committed Dec 15, 2023
1 parent 21966d5 commit 2e50501
Show file tree
Hide file tree
Showing 14 changed files with 8,071 additions and 8,287 deletions.
6 changes: 6 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,12 @@
/site/partials/recipes.html
/site/docs/

# puppeteer cache
.cache

# jest-image-snapshot diff output
__diff_output__

# ignore yarn files (this repo uses npm)
yarn-error.log
yarn.log
Expand Down
6 changes: 6 additions & 0 deletions jest-puppeteer.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
module.exports = {
server: {
command: 'webpack-dev-server --port 4444',
port: 4444
}
}
6 changes: 6 additions & 0 deletions jest.config.cjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
const config = {
preset: 'jest-puppeteer',
transformIgnorePatterns: ['<rootDir>/node_modules/(?!d3-\\.*|internmap)']
}

module.exports = config
Loading

0 comments on commit 2e50501

Please sign in to comment.