Skip to content

Commit

Permalink
chore(dev-deps): update jest to 27
Browse files Browse the repository at this point in the history
  • Loading branch information
AriPerkkio committed Nov 7, 2021
1 parent 85f7b10 commit 63a2e04
Show file tree
Hide file tree
Showing 5 changed files with 885 additions and 1,617 deletions.
6 changes: 3 additions & 3 deletions package.json
Expand Up @@ -50,7 +50,7 @@
"@tsconfig/node12": "^1.0.9",
"@types/babel__code-frame": "^7.0.2",
"@types/eslint": "^7.2.2",
"@types/jest": "^26.0.15",
"@types/jest": "^27.0.2",
"@types/node": "^15.0.0",
"@types/object-hash": "^2.1.0",
"@types/react": "^16.9.53",
Expand All @@ -67,13 +67,13 @@
"eslint-remote-tester-repositories": "^0.0.2",
"husky": "^7.0.2",
"ink-testing-library": "^2.1.0",
"jest": "^26.6.1",
"jest": "^27.3.1",
"lint-staged": "^11.1.2",
"node-pty": "^0.10.1",
"prettier": "^2.4.1",
"rimraf": "^3.0.2",
"strip-ansi": "^6.0.0",
"ts-jest": "^26.4.4",
"ts-jest": "^27.0.7",
"tsc-alias": "^1.3.9",
"typescript": "^4.4.3"
},
Expand Down
9 changes: 7 additions & 2 deletions test/unit/config.test.ts
Expand Up @@ -32,8 +32,13 @@ const mockConfig = jest.fn().mockReturnValue(DEFAULT_CONFIGURATION);
jest.mock('../../eslint-remote-tester.config.js', () => mockConfig());

function getConfig(): Config {
jest.resetModules();
return require('../../lib/config/config').default;
let config: Config;

jest.isolateModules(() => {
config = require('../../lib/config/config').default;
});

return config!;
}

describe('config', () => {
Expand Down
1 change: 0 additions & 1 deletion test/unit/file-client.test.ts
Expand Up @@ -101,7 +101,6 @@ function createComparisonResults(): void {
function getCacheLocation() {
let location = '';

jest.resetModuleRegistry();
jest.isolateModules(() => {
location =
require('../../lib/file-client/file-constants').CACHE_LOCATION;
Expand Down
1 change: 0 additions & 1 deletion test/unit/repository-client.test.ts
Expand Up @@ -20,7 +20,6 @@ beforeEach(() => {
}

// Initialize client
jest.resetModuleRegistry();
jest.isolateModules(() => {
require('../../lib/file-client/repository-client');
});
Expand Down

0 comments on commit 63a2e04

Please sign in to comment.