test: bump up Jest to v27 introducing new defaults

https://jestjs.io/blog/2021/05/25/jest-27
This commit is contained in:
Kengo TODA 2021-07-20 20:48:16 +08:00
parent 370105cb75
commit 5e787a2abc
7 changed files with 2741 additions and 2973 deletions

View file

@ -1,5 +1,6 @@
import * as checksums from '../src/checksums'
import nock from 'nock'
import {afterEach, describe, expect, test} from '@jest/globals'
test('fetches wrapper jars checksums', async () => {
const validChecksums = await checksums.fetchValidChecksums(false)

View file

@ -1,5 +1,6 @@
import * as path from 'path'
import * as find from '../src/find'
import {expect, test} from '@jest/globals'
test('finds test data wrapper jars', async () => {
const repoRoot = path.resolve('.')

View file

@ -1,5 +1,6 @@
import * as path from 'path'
import * as hash from '../src/hash'
import {expect, test} from '@jest/globals'
test('can sha256 files', async () => {
const sha = await hash.sha256File(

View file

@ -1,5 +1,6 @@
import * as path from 'path'
import * as validate from '../src/validate'
import {expect, test} from '@jest/globals'
const baseDir = path.resolve('.')

View file

@ -1,12 +1,8 @@
module.exports = {
clearMocks: true,
moduleFileExtensions: ['js', 'ts', 'json'],
testEnvironment: 'node',
testMatch: ['**/*.test.ts'],
testRunner: 'jest-circus/runner',
transform: {
'^.+\\.ts$': 'ts-jest'
},
preset: 'ts-jest',
verbose: true,
setupFilesAfterEnv: ['./jest.setup.js']
}

5696
package-lock.json generated

File diff suppressed because it is too large Load diff

View file

@ -30,19 +30,17 @@
"unhomoglyph": "1.0.6"
},
"devDependencies": {
"@types/jest": "26.0.14",
"@types/node": "12.12.62",
"@typescript-eslint/parser": "4.2.0",
"@vercel/ncc": "^0.29.0",
"eslint": "7.9.0",
"eslint-plugin-github": "4.1.1",
"eslint-plugin-jest": "24.0.2",
"jest": "26.4.2",
"jest-circus": "26.4.2",
"jest": "^27.0.6",
"js-yaml": "3.14.0",
"nock": "^13.0.11",
"prettier": "2.1.2",
"ts-jest": "26.4.0",
"ts-jest": "^27.0.3",
"typescript": "4.0.3"
}
}