test: consolidate unit tests (#9588)

All mocha tests have been migrated to Jest tests.

Closes #9564
This commit is contained in:
Vladimír Gorej
2024-02-14 11:39:40 +01:00
committed by GitHub
parent 8b0991c5cc
commit 7addbd0eb5
19 changed files with 27 additions and 331 deletions

View File

@@ -12,16 +12,12 @@ module.exports = {
testPathIgnorePatterns: [
'<rootDir>/node_modules/',
'<rootDir>/test/build-artifacts/',
'<rootDir>/test/mocha',
'<rootDir>/test/unit/jest-shim.js',
'<rootDir>/test/unit/setup.js',
'<rootDir>/test/unit/xss/anchor-target-rel/online-validator-badge.jsx',
'<rootDir>/test/unit/components/online-validator-badge.jsx',
'<rootDir>/test/unit/components/live-response.jsx',
],
moduleNameMapper: {
'^.+\\.svg$': 'jest-transform-stub'
},
transformIgnorePatterns: ['/node_modules/(?!(sinon)/)'],
transformIgnorePatterns: ['/node_modules/(?!(sinon|react-syntax-highlighter)/)'],
silent: true, // set to `false` to allow console.* calls to be printed
};