mirror of
https://gitlab.com/openstapps/openstapps.git
synced 2025-12-13 01:36:22 +00:00
refactor: app deployment
This commit is contained in:
10
coverage.mjs
10
coverage.mjs
@@ -2,8 +2,16 @@
|
||||
import {promisify} from 'node:util';
|
||||
import {glob} from 'glob';
|
||||
import {exec} from 'node:child_process';
|
||||
import {mergeFiles} from 'junit-report-merger';
|
||||
|
||||
const files = await glob('./*/*/coverage/cobertura-coverage.xml');
|
||||
const args = files.map(it => `${it.split('/', 2)[1]}='${it}'`);
|
||||
|
||||
console.log(await promisify(exec)(`cobertura-merge -o ./coverage.xml ${args.join(' ')}`));
|
||||
console.log(
|
||||
'Collecting coverage...',
|
||||
await promisify(exec)(`cobertura-merge -o ./coverage.xml ${args.join(' ')}`),
|
||||
);
|
||||
|
||||
const reportFiles = await glob('./*/*/coverage/report-junit.xml');
|
||||
console.log('Collecting reports...', reportFiles);
|
||||
await mergeFiles('./report-junit.xml', reportFiles);
|
||||
|
||||
Reference in New Issue
Block a user