mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2026-09-09 18:03:21 +00:00
[ACS-10740] Adjust Karma and Jest config (#11365)
This commit is contained in:
Vendored
-1
@@ -5,7 +5,6 @@
|
|||||||
"**/.svn": true,
|
"**/.svn": true,
|
||||||
"**/.hg": true,
|
"**/.hg": true,
|
||||||
"**/.DS_Store": true,
|
"**/.DS_Store": true,
|
||||||
"**/coverage": true,
|
|
||||||
"**/.happypack": true
|
"**/.happypack": true
|
||||||
},
|
},
|
||||||
"markdownlint.config": {
|
"markdownlint.config": {
|
||||||
|
|||||||
@@ -66,9 +66,9 @@ module.exports = function (config) {
|
|||||||
},
|
},
|
||||||
|
|
||||||
coverageReporter: {
|
coverageReporter: {
|
||||||
dir: join(__dirname, './coverage/content-services'),
|
dir: join(__dirname, '../../coverage/content-services'),
|
||||||
subdir: '.',
|
subdir: '.',
|
||||||
reporters: [{ type: 'html' }, { type: 'text-summary' }],
|
reporters: [{ type: 'html' }, { type: 'text-summary' }, { type: 'text-summary', subdir: '.', file: 'summary.txt' }],
|
||||||
check: {
|
check: {
|
||||||
global: {
|
global: {
|
||||||
statements: 75,
|
statements: 75,
|
||||||
|
|||||||
@@ -78,9 +78,9 @@ module.exports = function (config) {
|
|||||||
},
|
},
|
||||||
|
|
||||||
coverageReporter: {
|
coverageReporter: {
|
||||||
dir: join(__dirname, './coverage/core'),
|
dir: join(__dirname, '../../coverage/core'),
|
||||||
subdir: '.',
|
subdir: '.',
|
||||||
reporters: [{ type: 'html' }, { type: 'text-summary' }],
|
reporters: [{ type: 'html' }, { type: 'text-summary' }, { type: 'text-summary', subdir: '.', file: 'summary.txt' }],
|
||||||
check: {
|
check: {
|
||||||
global: {
|
global: {
|
||||||
statements: 75,
|
statements: 75,
|
||||||
|
|||||||
@@ -1,5 +1,6 @@
|
|||||||
// Karma configuration file, see link for more information
|
// Karma configuration file, see link for more information
|
||||||
// https://karma-runner.github.io/1.0/config/configuration-file.html
|
// https://karma-runner.github.io/1.0/config/configuration-file.html
|
||||||
|
/* eslint-env es6 */
|
||||||
const { join } = require('path');
|
const { join } = require('path');
|
||||||
const { constants } = require('karma');
|
const { constants } = require('karma');
|
||||||
|
|
||||||
@@ -19,16 +20,16 @@ module.exports = function (config) {
|
|||||||
clearContext: false // leave Jasmine Spec Runner output visible in browser
|
clearContext: false // leave Jasmine Spec Runner output visible in browser
|
||||||
},
|
},
|
||||||
jasmineHtmlReporter: {
|
jasmineHtmlReporter: {
|
||||||
suppressAll: true, // removes the duplicated traces
|
suppressAll: true // removes the duplicated traces
|
||||||
},
|
},
|
||||||
mochaReporter: {
|
mochaReporter: {
|
||||||
ignoreSkipped: process.env?.KARMA_IGNORE_SKIPPED === 'true'
|
ignoreSkipped: process.env.KARMA_IGNORE_SKIPPED === 'true'
|
||||||
},
|
},
|
||||||
|
|
||||||
coverageReporter: {
|
coverageReporter: {
|
||||||
dir: join(__dirname, './coverage/extensions'),
|
dir: join(__dirname, '../../coverage/extensions'),
|
||||||
subdir: '.',
|
subdir: '.',
|
||||||
reporters: [{type: 'html'}, {type: 'text-summary'}],
|
reporters: [{ type: 'html' }, { type: 'text-summary' }, { type: 'text-summary', subdir: '.', file: 'summary.txt' }],
|
||||||
check: {
|
check: {
|
||||||
global: {
|
global: {
|
||||||
statements: 75,
|
statements: 75,
|
||||||
@@ -47,12 +48,7 @@ module.exports = function (config) {
|
|||||||
customLaunchers: {
|
customLaunchers: {
|
||||||
ChromeHeadless: {
|
ChromeHeadless: {
|
||||||
base: 'Chrome',
|
base: 'Chrome',
|
||||||
flags: [
|
flags: ['--no-sandbox', '--headless', '--disable-gpu', '--remote-debugging-port=9222']
|
||||||
'--no-sandbox',
|
|
||||||
'--headless',
|
|
||||||
'--disable-gpu',
|
|
||||||
'--remote-debugging-port=9222'
|
|
||||||
]
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
singleRun: true
|
singleRun: true
|
||||||
|
|||||||
@@ -1,5 +1,6 @@
|
|||||||
// Karma configuration file, see link for more information
|
// Karma configuration file, see link for more information
|
||||||
// https://karma-runner.github.io/1.0/config/configuration-file.html
|
// https://karma-runner.github.io/1.0/config/configuration-file.html
|
||||||
|
/* eslint-env es6 */
|
||||||
const { join } = require('path');
|
const { join } = require('path');
|
||||||
const { constants } = require('karma');
|
const { constants } = require('karma');
|
||||||
|
|
||||||
@@ -49,13 +50,13 @@ module.exports = function (config) {
|
|||||||
},
|
},
|
||||||
|
|
||||||
mochaReporter: {
|
mochaReporter: {
|
||||||
ignoreSkipped: process.env?.KARMA_IGNORE_SKIPPED === 'true'
|
ignoreSkipped: process.env.KARMA_IGNORE_SKIPPED === 'true'
|
||||||
},
|
},
|
||||||
|
|
||||||
coverageReporter: {
|
coverageReporter: {
|
||||||
dir: join(__dirname, './coverage/insights'),
|
dir: join(__dirname, '../../coverage/insights'),
|
||||||
subdir: '.',
|
subdir: '.',
|
||||||
reporters: [{ type: 'html' }, { type: 'text-summary' }],
|
reporters: [{ type: 'html' }, { type: 'text-summary' }, { type: 'text-summary', subdir: '.', file: 'summary.txt' }],
|
||||||
check: {
|
check: {
|
||||||
global: {
|
global: {
|
||||||
statements: 75,
|
statements: 75,
|
||||||
|
|||||||
@@ -4,7 +4,9 @@ export default {
|
|||||||
preset: '../../jest.preset.js',
|
preset: '../../jest.preset.js',
|
||||||
testEnvironment: 'jsdom',
|
testEnvironment: 'jsdom',
|
||||||
setupFilesAfterEnv: ['<rootDir>/src/test-setup.ts'],
|
setupFilesAfterEnv: ['<rootDir>/src/test-setup.ts'],
|
||||||
coverageDirectory: '../../../coverage/libs/js-api',
|
collectCoverage: true,
|
||||||
|
coverageReporters: ['html', ['text-summary', { file: 'summary.txt' }], 'text-summary'],
|
||||||
|
coverageDirectory: '../../coverage/js-api',
|
||||||
moduleNameMapper: {
|
moduleNameMapper: {
|
||||||
'^pdfjs-dist$': 'pdfjs-dist/legacy/build/pdf'
|
'^pdfjs-dist$': 'pdfjs-dist/legacy/build/pdf'
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -55,9 +55,9 @@ module.exports = function (config) {
|
|||||||
},
|
},
|
||||||
|
|
||||||
coverageReporter: {
|
coverageReporter: {
|
||||||
dir: join(__dirname, './coverage/process-service-cloud'),
|
dir: join(__dirname, '../../coverage/process-services-cloud'),
|
||||||
subdir: '.',
|
subdir: '.',
|
||||||
reporters: [{ type: 'html' }, { type: 'text-summary' }],
|
reporters: [{ type: 'html' }, { type: 'text-summary' }, { type: 'text-summary', subdir: '.', file: 'summary.txt' }],
|
||||||
check: {
|
check: {
|
||||||
global: {
|
global: {
|
||||||
statements: 75,
|
statements: 75,
|
||||||
|
|||||||
@@ -50,9 +50,9 @@ module.exports = function (config) {
|
|||||||
ignoreSkipped: process.env.KARMA_IGNORE_SKIPPED === 'true'
|
ignoreSkipped: process.env.KARMA_IGNORE_SKIPPED === 'true'
|
||||||
},
|
},
|
||||||
coverageReporter: {
|
coverageReporter: {
|
||||||
dir: join(__dirname, './coverage/process-services'),
|
dir: join(__dirname, '../../coverage/process-services'),
|
||||||
subdir: '.',
|
subdir: '.',
|
||||||
reporters: [{ type: 'html' }, { type: 'text-summary' }],
|
reporters: [{ type: 'html' }, { type: 'text-summary' }, { type: 'text-summary', subdir: '.', file: 'summary.txt' }],
|
||||||
check: {
|
check: {
|
||||||
global: {
|
global: {
|
||||||
statements: 75,
|
statements: 75,
|
||||||
|
|||||||
Reference in New Issue
Block a user