mirror of
https://github.com/docker/setup-buildx-action.git
synced 2024-11-18 01:55:41 +01:00
987520896f
Signed-off-by: CrazyMax <crazy-max@users.noreply.github.com>
30 lines
926 B
TypeScript
30 lines
926 B
TypeScript
import fs from 'fs';
|
|
import os from 'os';
|
|
import path from 'path';
|
|
|
|
const tmpDir = fs.mkdtempSync(path.join(os.tmpdir(), 'docker-setup-buildx-action-')).split(path.sep).join(path.posix.sep);
|
|
|
|
process.env = Object.assign({}, process.env, {
|
|
TEMP: tmpDir,
|
|
GITHUB_REPOSITORY: 'docker/setup-buildx-action',
|
|
RUNNER_TEMP: path.join(tmpDir, 'runner-temp').split(path.sep).join(path.posix.sep),
|
|
RUNNER_TOOL_CACHE: path.join(tmpDir, 'runner-tool-cache').split(path.sep).join(path.posix.sep)
|
|
}) as {
|
|
[key: string]: string;
|
|
};
|
|
|
|
module.exports = {
|
|
clearMocks: true,
|
|
moduleFileExtensions: ['js', 'ts'],
|
|
testMatch: ['**/*.test.ts'],
|
|
transform: {
|
|
'^.+\\.ts$': 'ts-jest'
|
|
},
|
|
moduleNameMapper: {
|
|
'^csv-parse/sync': '<rootDir>/node_modules/csv-parse/dist/cjs/sync.cjs'
|
|
},
|
|
collectCoverageFrom: ['src/**/{!(main.ts),}.ts'],
|
|
coveragePathIgnorePatterns: ['lib/', 'node_modules/', '__tests__/'],
|
|
verbose: true
|
|
};
|