mirror of
https://github.com/crazy-max/ghaction-upx.git
synced 2026-04-14 10:32:59 -06:00
update jest config since 30.0
This commit is contained in:
26
jest.config.js
Normal file
26
jest.config.js
Normal file
@@ -0,0 +1,26 @@
|
|||||||
|
/* eslint-disable @typescript-eslint/no-require-imports */
|
||||||
|
const fs = require('fs');
|
||||||
|
const os = require('os');
|
||||||
|
const path = require('path');
|
||||||
|
|
||||||
|
const tmpDir = fs.mkdtempSync(path.join(os.tmpdir(), 'ghaction-upx-'));
|
||||||
|
|
||||||
|
process.env = Object.assign({}, process.env, {
|
||||||
|
TEMP: tmpDir,
|
||||||
|
GITHUB_REPOSITORY: 'crazy-max/ghaction-upx',
|
||||||
|
RUNNER_TEMP: path.join(tmpDir, 'runner-temp'),
|
||||||
|
RUNNER_TOOL_CACHE: path.join(tmpDir, 'runner-tool-cache')
|
||||||
|
});
|
||||||
|
|
||||||
|
module.exports = {
|
||||||
|
clearMocks: true,
|
||||||
|
testEnvironment: 'node',
|
||||||
|
moduleFileExtensions: ['js', 'ts'],
|
||||||
|
testMatch: ['**/*.test.ts'],
|
||||||
|
transform: {
|
||||||
|
'^.+\\.ts$': 'ts-jest'
|
||||||
|
},
|
||||||
|
collectCoverageFrom: ['src/**/{!(main.ts),}.ts'],
|
||||||
|
coveragePathIgnorePatterns: ['dist/', 'node_modules/', '__tests__/'],
|
||||||
|
verbose: true
|
||||||
|
};
|
||||||
@@ -1,12 +0,0 @@
|
|||||||
module.exports = {
|
|
||||||
clearMocks: true,
|
|
||||||
testEnvironment: 'node',
|
|
||||||
moduleFileExtensions: ['js', 'ts'],
|
|
||||||
testMatch: ['**/*.test.ts'],
|
|
||||||
transform: {
|
|
||||||
'^.+\\.ts$': 'ts-jest'
|
|
||||||
},
|
|
||||||
collectCoverageFrom: ['src/**/{!(main.ts),}.ts'],
|
|
||||||
coveragePathIgnorePatterns: ['dist/', 'node_modules/', '__tests__/'],
|
|
||||||
verbose: true
|
|
||||||
};
|
|
||||||
Reference in New Issue
Block a user