Skip to content

Commit

Permalink
test: quasar test jest upgrade
Browse files Browse the repository at this point in the history
  • Loading branch information
glorat committed Nov 18, 2022
1 parent 8ceef4b commit 70c1865
Show file tree
Hide file tree
Showing 6 changed files with 17,559 additions and 22,058 deletions.
83 changes: 0 additions & 83 deletions client/jest.config.js

This file was deleted.

39 changes: 39 additions & 0 deletions client/jest.config.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
import { quasarEsModulesPackageNames } from '@quasar/quasar-app-extension-testing-unit-jest/jest-preset.mjs';

/** @type {import('jest').Config} */
export default {
preset: '@quasar/quasar-app-extension-testing-unit-jest',
// collectCoverage: true,
// coverageThreshold: {
// global: {
// branches: 50,
// functions: 50,
// lines: 50,
// statements: 50
// },
// },
transform: {
[`^(${quasarEsModulesPackageNames}).+\\.js$`]: 'babel-jest',
'^.+\\.(ts|js|html)$': [
'ts-jest',
{
// Remove if using `const enums`
// See https://kulshekhar.github.io/ts-jest/docs/getting-started/options/isolatedModules/
isolatedModules: true,
},
],
},
moduleNameMapper: {
'^quasar$': 'quasar/dist/quasar.esm.prod.js',
'^~/(.*)$': '<rootDir>/$1',
'^src/(.*)$': '<rootDir>/src/$1',
'^app/(.*)$': '<rootDir>/$1',
'^components/(.*)$': '<rootDir>/src/components/$1',
'^layouts/(.*)$': '<rootDir>/src/layouts/$1',
'^pages/(.*)$': '<rootDir>/src/pages/$1',
'^assets/(.*)$': '<rootDir>/src/assets/$1',
'^boot/(.*)$': '<rootDir>/src/boot/$1',
'.*css$': '@quasar/quasar-app-extension-testing-unit-jest/stub.css',
},

};
Loading

0 comments on commit 70c1865

Please sign in to comment.