Skip to content

Commit

Permalink
chore: require minimum typescript@3.8 (#9823)
Browse files Browse the repository at this point in the history
  • Loading branch information
SimenB authored May 2, 2020
1 parent d0623eb commit f776624
Show file tree
Hide file tree
Showing 55 changed files with 15 additions and 386 deletions.
2 changes: 0 additions & 2 deletions .github/workflows/nodejs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,8 +41,6 @@ jobs:
run: node scripts/build.js
- name: run tsc
run: yarn build:ts
- name: verify ts 3.4 compatibility
run: yarn verify-old-ts
- name: run eslint
run: yarn lint
- name: run prettier
Expand Down
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@

### Chore & Maintenance

- `[*]` [**BREAKING**] TypeScript definitions requires a minimum of TypeScript v3.8 ([#9823](https://github.com/facebook/jest/pull/9823))
- `[jest-runtime]` [**BREAKING**] Remove long-deprecated `require.requireActual` and `require.requireMock` methods ([#9854](https://github.com/facebook/jest/pull/9854))
- `[expect, jest-mock, pretty-format]` [**BREAKING**] Remove `build-es5` from package ([#9945](https://github.com/facebook/jest/pull/9945))

Expand Down
3 changes: 0 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,6 @@
"codecov": "^3.0.0",
"debug": "^4.0.1",
"dedent": "^0.7.0",
"downlevel-dts": "^0.4.0",
"eslint": "^6.2.2",
"eslint-config-prettier": "^6.1.0",
"eslint-plugin-babel": "^5.1.0",
Expand Down Expand Up @@ -76,7 +75,6 @@
"string-length": "^3.1.0",
"strip-ansi": "^6.0.0",
"tempy": "~0.3.0",
"throat": "^5.0.0",
"typescript": "^3.8.2",
"which": "^2.0.1"
},
Expand All @@ -102,7 +100,6 @@
"test-pretty-format-perf": "node packages/pretty-format/perf/test.js",
"test-leak": "yarn jest -i --detectLeaks jest-mock jest-diff jest-repl",
"test": "yarn lint && yarn jest",
"verify-old-ts": "node ./scripts/verifyOldTs.js",
"watch": "yarn build && node ./scripts/watch.js",
"watch:ts": "yarn build:ts --watch"
},
Expand Down
7 changes: 0 additions & 7 deletions packages/babel-jest/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,13 +10,6 @@
"license": "MIT",
"main": "build/index.js",
"types": "build/index.d.ts",
"typesVersions": {
"<3.8": {
"build/*": [
"build/ts3.4/*"
]
}
},
"dependencies": {
"@jest/transform": "^25.5.1",
"@jest/types": "^25.5.0",
Expand Down
7 changes: 0 additions & 7 deletions packages/babel-plugin-jest-hoist/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,6 @@
"license": "MIT",
"main": "build/index.js",
"types": "build/index.d.ts",
"typesVersions": {
"<3.8": {
"build/*": [
"build/ts3.4/*"
]
}
},
"dependencies": {
"@babel/template": "^7.3.3",
"@babel/types": "^7.3.3",
Expand Down
7 changes: 0 additions & 7 deletions packages/diff-sequences/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,13 +20,6 @@
},
"main": "build/index.js",
"types": "build/index.d.ts",
"typesVersions": {
"<3.8": {
"build/*": [
"build/ts3.4/*"
]
}
},
"scripts": {
"perf": "node --expose-gc perf/index.js"
},
Expand Down
7 changes: 0 additions & 7 deletions packages/expect/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,6 @@
"license": "MIT",
"main": "build/index.js",
"types": "build/index.d.ts",
"typesVersions": {
"<3.8": {
"build/*": [
"build/ts3.4/*"
]
}
},
"dependencies": {
"@jest/types": "^25.5.0",
"ansi-styles": "^4.0.0",
Expand Down
7 changes: 0 additions & 7 deletions packages/jest-changed-files/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,6 @@
"license": "MIT",
"main": "build/index.js",
"types": "build/index.d.ts",
"typesVersions": {
"<3.8": {
"build/*": [
"build/ts3.4/*"
]
}
},
"dependencies": {
"@jest/types": "^25.5.0",
"execa": "^3.2.0",
Expand Down
7 changes: 0 additions & 7 deletions packages/jest-circus/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,6 @@
"license": "MIT",
"main": "build/index.js",
"types": "build/index.d.ts",
"typesVersions": {
"<3.8": {
"build/*": [
"build/ts3.4/*"
]
}
},
"dependencies": {
"@babel/traverse": "^7.1.0",
"@jest/environment": "^25.5.0",
Expand Down
7 changes: 0 additions & 7 deletions packages/jest-cli/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,6 @@
"version": "25.5.4",
"main": "build/index.js",
"types": "build/index.d.ts",
"typesVersions": {
"<3.8": {
"build/*": [
"build/ts3.4/*"
]
}
},
"dependencies": {
"@jest/core": "^25.5.4",
"@jest/test-result": "^25.5.0",
Expand Down
7 changes: 0 additions & 7 deletions packages/jest-config/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,6 @@
"license": "MIT",
"main": "build/index.js",
"types": "build/index.d.ts",
"typesVersions": {
"<3.8": {
"build/*": [
"build/ts3.4/*"
]
}
},
"dependencies": {
"@babel/core": "^7.1.0",
"@jest/test-sequencer": "^25.5.4",
Expand Down
7 changes: 0 additions & 7 deletions packages/jest-console/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,6 @@
"license": "MIT",
"main": "build/index.js",
"types": "build/index.d.ts",
"typesVersions": {
"<3.8": {
"build/*": [
"build/ts3.4/*"
]
}
},
"dependencies": {
"@jest/types": "^25.5.0",
"chalk": "^3.0.0",
Expand Down
3 changes: 1 addition & 2 deletions packages/jest-console/src/CustomConsole.ts
Original file line number Diff line number Diff line change
Expand Up @@ -51,8 +51,7 @@ export default class CustomConsole extends Console {
);
}

// use `asserts` when https://github.com/sandersn/downlevel-dts/issues/32 is fixed
assert(value: unknown, message?: string | Error): void {
assert(value: unknown, message?: string | Error): asserts value {
try {
assert(value, message);
} catch (error) {
Expand Down
7 changes: 0 additions & 7 deletions packages/jest-core/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,6 @@
"version": "25.5.4",
"main": "build/jest.js",
"types": "build/jest.d.ts",
"typesVersions": {
"<3.8": {
"build/*": [
"build/ts3.4/*"
]
}
},
"dependencies": {
"@jest/console": "^25.5.0",
"@jest/reporters": "^25.5.1",
Expand Down
7 changes: 0 additions & 7 deletions packages/jest-diff/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,6 @@
"license": "MIT",
"main": "build/index.js",
"types": "build/index.d.ts",
"typesVersions": {
"<3.8": {
"build/*": [
"build/ts3.4/*"
]
}
},
"dependencies": {
"chalk": "^3.0.0",
"diff-sequences": "^25.2.6",
Expand Down
7 changes: 0 additions & 7 deletions packages/jest-docblock/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,6 @@
"license": "MIT",
"main": "build/index.js",
"types": "build/index.d.ts",
"typesVersions": {
"<3.8": {
"build/*": [
"build/ts3.4/*"
]
}
},
"dependencies": {
"detect-newline": "^3.0.0"
},
Expand Down
7 changes: 0 additions & 7 deletions packages/jest-each/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,6 @@
"description": "Parameterised tests for Jest",
"main": "build/index.js",
"types": "build/index.d.ts",
"typesVersions": {
"<3.8": {
"build/*": [
"build/ts3.4/*"
]
}
},
"repository": {
"type": "git",
"url": "https://github.com/facebook/jest.git",
Expand Down
7 changes: 0 additions & 7 deletions packages/jest-environment-jsdom/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,6 @@
"license": "MIT",
"main": "build/index.js",
"types": "build/index.d.ts",
"typesVersions": {
"<3.8": {
"build/*": [
"build/ts3.4/*"
]
}
},
"dependencies": {
"@jest/environment": "^25.5.0",
"@jest/fake-timers": "^25.5.0",
Expand Down
7 changes: 0 additions & 7 deletions packages/jest-environment-node/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,6 @@
"license": "MIT",
"main": "build/index.js",
"types": "build/index.d.ts",
"typesVersions": {
"<3.8": {
"build/*": [
"build/ts3.4/*"
]
}
},
"dependencies": {
"@jest/environment": "^25.5.0",
"@jest/fake-timers": "^25.5.0",
Expand Down
7 changes: 0 additions & 7 deletions packages/jest-environment/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,6 @@
"license": "MIT",
"main": "build/index.js",
"types": "build/index.d.ts",
"typesVersions": {
"<3.8": {
"build/*": [
"build/ts3.4/*"
]
}
},
"dependencies": {
"@jest/fake-timers": "^25.5.0",
"@jest/types": "^25.5.0",
Expand Down
7 changes: 0 additions & 7 deletions packages/jest-fake-timers/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,6 @@
"license": "MIT",
"main": "build/index.js",
"types": "build/index.d.ts",
"typesVersions": {
"<3.8": {
"build/*": [
"build/ts3.4/*"
]
}
},
"dependencies": {
"@jest/types": "^25.5.0",
"jest-message-util": "^25.5.0",
Expand Down
7 changes: 0 additions & 7 deletions packages/jest-get-type/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,13 +13,6 @@
"license": "MIT",
"main": "build/index.js",
"types": "build/index.d.ts",
"typesVersions": {
"<3.8": {
"build/*": [
"build/ts3.4/*"
]
}
},
"publishConfig": {
"access": "public"
},
Expand Down
7 changes: 0 additions & 7 deletions packages/jest-globals/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,6 @@
"license": "MIT",
"main": "build/index.js",
"types": "build/index.d.ts",
"typesVersions": {
"<3.8": {
"build/*": [
"build/ts3.4/*"
]
}
},
"dependencies": {
"@jest/environment": "^25.5.0",
"@jest/types": "^25.5.0",
Expand Down
7 changes: 0 additions & 7 deletions packages/jest-haste-map/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,6 @@
"license": "MIT",
"main": "build/index.js",
"types": "build/index.d.ts",
"typesVersions": {
"<3.8": {
"build/*": [
"build/ts3.4/*"
]
}
},
"dependencies": {
"@jest/types": "^25.5.0",
"@types/graceful-fs": "^4.1.2",
Expand Down
7 changes: 0 additions & 7 deletions packages/jest-jasmine2/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,6 @@
"license": "MIT",
"main": "build/index.js",
"types": "build/index.d.ts",
"typesVersions": {
"<3.8": {
"build/*": [
"build/ts3.4/*"
]
}
},
"dependencies": {
"@babel/traverse": "^7.1.0",
"@jest/environment": "^25.5.0",
Expand Down
7 changes: 0 additions & 7 deletions packages/jest-leak-detector/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,6 @@
"license": "MIT",
"main": "build/index.js",
"types": "build/index.d.ts",
"typesVersions": {
"<3.8": {
"build/*": [
"build/ts3.4/*"
]
}
},
"dependencies": {
"jest-get-type": "^25.2.6",
"pretty-format": "^25.5.0"
Expand Down
7 changes: 0 additions & 7 deletions packages/jest-matcher-utils/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,13 +13,6 @@
"license": "MIT",
"main": "build/index.js",
"types": "build/index.d.ts",
"typesVersions": {
"<3.8": {
"build/*": [
"build/ts3.4/*"
]
}
},
"dependencies": {
"chalk": "^3.0.0",
"jest-diff": "^25.5.0",
Expand Down
7 changes: 0 additions & 7 deletions packages/jest-message-util/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,6 @@
"license": "MIT",
"main": "build/index.js",
"types": "build/index.d.ts",
"typesVersions": {
"<3.8": {
"build/*": [
"build/ts3.4/*"
]
}
},
"dependencies": {
"@babel/code-frame": "^7.0.0",
"@jest/types": "^25.5.0",
Expand Down
Loading

0 comments on commit f776624

Please sign in to comment.