Skip to content

Commit d085056

Browse files
test: increase timeout (#15)
1 parent 3764776 commit d085056

8 files changed

+2
-12
lines changed

jest.config.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
module.exports = {
22
testEnvironment: 'node',
33
snapshotResolver: './test/helpers/snapshotResolver.js',
4+
setupFilesAfterEnv: ['<rootDir>/setupTest.js'],
45
};

setupTest.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
jest.setTimeout(120000);

test/CssMinimizerPlugin.test.js

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,6 @@ import {
1818
normalizedSourceMap,
1919
} from './helpers';
2020

21-
jest.setTimeout(30000);
22-
2321
describe('CssMinimizerPlugin', () => {
2422
const rawSourceMap = {
2523
version: 3,

test/cache-option.test.js

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,6 @@ const otherOtherOtherCacheDir = findCacheDir({
2525
name: 'other-other-other-cache-directory',
2626
});
2727

28-
jest.setTimeout(30000);
29-
3028
if (getCompiler.isWebpack4()) {
3129
describe('cache option', () => {
3230
let compiler;

test/cssMinimizerOptions-option.test.js

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,6 @@ import CssMinimizerPlugin from '../src/index';
22

33
import { getCompiler, compile, readAsset, removeCache } from './helpers';
44

5-
jest.setTimeout(30000);
6-
75
describe('when applied with "minimizerOptions" option', () => {
86
beforeEach(() => Promise.all([removeCache()]));
97

test/parallel-option.test.js

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -44,8 +44,6 @@ jest.mock('jest-worker', () => {
4444

4545
const workerPath = require.resolve('../src/minify');
4646

47-
jest.setTimeout(30000);
48-
4947
describe('parallel option', () => {
5048
let compiler;
5149

test/sourceMap-option.test.js

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,6 @@ import {
1313
getWarnings,
1414
} from './helpers';
1515

16-
jest.setTimeout(30000);
17-
1816
describe('when applied with "sourceMap" option', () => {
1917
const baseConfig = {
2018
devtool: 'source-map',

test/test-option.test.js

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,6 @@ import CssMinimizerPlugin from '../src/index';
22

33
import { getCompiler, compile, readAsset, removeCache } from './helpers';
44

5-
jest.setTimeout(30000);
6-
75
describe('when applied with "test" option', () => {
86
let compiler;
97

0 commit comments

Comments
 (0)