diff --git a/src/__tests__/render-basics.js b/src/__tests__/render-basics.js index 0f3c625..81d84bd 100644 --- a/src/__tests__/render-basics.js +++ b/src/__tests__/render-basics.js @@ -1,16 +1,5 @@ const {resolve} = require('path') const {render} = require('../pure') -const {getConfig, configure} = require("../config"); - -let originalConfig -beforeEach(() => { - originalConfig = getConfig() - configure({asyncUtilTimeout: 15000, renderAwaitTime: 300}) -}) - -afterEach(() => { - configure(originalConfig) -}) test('Should expect error codes when intended', async () => { const instance = await render('node', [resolve(__dirname, './execute-scripts/throw.js')]) diff --git a/tests/setup-env.js b/tests/setup-env.js index fdd4d05..05a7687 100644 --- a/tests/setup-env.js +++ b/tests/setup-env.js @@ -1,5 +1,6 @@ import jestSnapshotSerializerAnsi from 'jest-snapshot-serializer-ansi' import '../src/extend-expect'; +import {configure, getConfig} from "../src/config"; expect.addSnapshotSerializer(jestSnapshotSerializerAnsi) // add serializer for MutationRecord @@ -46,5 +47,14 @@ afterAll(() => { jest.restoreAllMocks() }) +jest.setTimeout(20000) -jest.setTimeout(7000) +let originalConfig +beforeAll(() => { + originalConfig = getConfig() + configure({asyncUtilTimeout: 15000, renderAwaitTime: 800}) +}) + +afterAll(() => { + configure(originalConfig) +})