Skip to content

Commit

Permalink
Merge pull request #215 from Tradeshift/axios-fix
Browse files Browse the repository at this point in the history
fix(jest): transpile axios by default
  • Loading branch information
tradeshift-larsbojensen authored Nov 20, 2023
2 parents 52b04d4 + 052c94b commit f4b7fcd
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/config/jest.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,11 @@ const jestConfig = {
collectCoverageFrom: ['src/**/*.[jt]s?(x)'],
coveragePathIgnorePatterns: [...ignores, 'src/(umd|cjs|esm)-entry.[jt]s$'],
coverageReporters: ['text', 'cobertura', 'lcov', 'json'],
transformIgnorePatterns: ['[/\\\\]node_modules[/\\\\].+\\.(js|jsx)$'],
transformIgnorePatterns: [
'[/\\\\]node_modules[/\\\\].+\\.(js|jsx)$',
'node_modules/(?!axios)/', // transpile axios because it has es6 modules post v1
// https://github.com/axios/axios/issues/5101#issuecomment-1275242123
],
reporters: ['default', [require.resolve('jest-junit'), junitConfig]],
coverageThreshold: {
global: {
Expand Down

0 comments on commit f4b7fcd

Please sign in to comment.