Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Configure Jest for TypeScript #12167

Merged
merged 67 commits into from Nov 9, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
67 commits
Select commit Hold shift + click to select a range
f7bb798
Install and configure ts-jest
swissspidy Aug 25, 2022
4ee0b17
Convert some test files to TS
swissspidy Aug 25, 2022
a5947e8
Update `testMatch` config
swissspidy Aug 25, 2022
7bc323d
Specifically install Jest types
swissspidy Aug 25, 2022
f2447c6
Downgrade `@jest/types`
swissspidy Aug 25, 2022
8122b13
Merge branch 'main' into add/12097-ts-jest
swissspidy Aug 29, 2022
4053160
Remove `@types/jest`
swissspidy Aug 29, 2022
6e0ea3a
Fix transform & update tests
swissspidy Aug 29, 2022
dd7f2a7
Change `mime/lite` import
swissspidy Aug 30, 2022
da5881c
Merge branch 'main' into add/12097-ts-jest
swissspidy Aug 30, 2022
37b5d10
Enable `jest/unbound-method` for TS tests
swissspidy Aug 30, 2022
fdf484d
Undo some changes
swissspidy Aug 30, 2022
6ea634f
Update `getBoundRect`
swissspidy Aug 30, 2022
1f67412
Update types & typescript
swissspidy Aug 30, 2022
f401a6a
Update deps
swissspidy Aug 30, 2022
700beab
Disable type checking for ts-jest for now
swissspidy Aug 31, 2022
335eaa9
Merge branch 'main' into add/12097-ts-jest
swissspidy Aug 31, 2022
e20af3c
Lint fixes
swissspidy Aug 31, 2022
228152e
Update deps
swissspidy Aug 31, 2022
44e6b62
Remove file
swissspidy Aug 31, 2022
fb3e5cc
Merge branch 'main' into add/12097-ts-jest
swissspidy Sep 2, 2022
8c2a6ff
Move `normalizeResourceSizes` to `wp-story-editor` package
swissspidy Sep 2, 2022
9f8a488
Move `normalizeResourceSizes` to `wp-story-editor`
swissspidy Sep 2, 2022
8eaeb82
Fix incorrect import
swissspidy Sep 2, 2022
87c4cf8
Remove incorrect import
swissspidy Sep 2, 2022
9fe1e96
Convert test to TypeScript
swissspidy Sep 2, 2022
750c424
Update some packages, try to resolve conflicts
swissspidy Sep 2, 2022
469785d
Update ts-jest config
swissspidy Sep 2, 2022
b1be90f
Update more deps
swissspidy Sep 2, 2022
0a49ee2
Update lock file
swissspidy Sep 2, 2022
a7ccd07
Resolve another todo
swissspidy Sep 2, 2022
7f263f4
Merge branch 'main' into add/12097-ts-jest
swissspidy Sep 6, 2022
d501fa3
Convert more tests
swissspidy Sep 6, 2022
bdae5d2
Add reference
swissspidy Sep 6, 2022
5f7b222
More tweaks
swissspidy Sep 6, 2022
1a9948a
Merge branch 'main' into add/12097-ts-jest
swissspidy Sep 10, 2022
b5bdc4d
Merge branch 'main' into add/12097-ts-jest
swissspidy Sep 12, 2022
83e4dbc
Merge branch 'main' into add/12097-ts-jest
swissspidy Sep 14, 2022
f1e6755
Merge branch 'main' into add/12097-ts-jest
swissspidy Sep 14, 2022
0048252
Start converting richt-text tests
swissspidy Sep 14, 2022
b72d4cd
Convert patterns tests
swissspidy Sep 14, 2022
7c6c976
Update date tests & types
swissspidy Sep 14, 2022
bc36baf
Convert wp-utils tests
swissspidy Sep 14, 2022
96af850
Update patterns test
swissspidy Sep 14, 2022
df1e45e
Fix type errors
swissspidy Sep 14, 2022
df6cf35
Update more rich-text tests
swissspidy Sep 14, 2022
cac675e
More adjustments
swissspidy Sep 14, 2022
f11b66e
Try updating test instead
swissspidy Sep 15, 2022
c58d20e
Merge branch 'main' into add/12097-ts-jest
swissspidy Sep 16, 2022
2ea2523
Merge branch 'main' into add/12097-ts-jest
swissspidy Sep 30, 2022
b9afa96
Merge branch 'main' into add/12097-ts-jest
swissspidy Oct 14, 2022
dd41dd3
Update ts-jest
swissspidy Oct 14, 2022
7a6acbd
Merge branch 'main' into add/12097-ts-jest
swissspidy Oct 26, 2022
97bc417
Just use babel-jest
swissspidy Oct 26, 2022
3316566
Update patterns tests
swissspidy Oct 26, 2022
a24d4bf
More fixes
swissspidy Oct 26, 2022
e4ff4f4
More fixes
swissspidy Oct 26, 2022
df9200c
Merge branch 'main' into add/12097-ts-jest
swissspidy Oct 26, 2022
f903b1b
Update resolver
swissspidy Oct 26, 2022
3d350dd
Merge branch 'main' into add/12097-ts-jest
swissspidy Nov 2, 2022
1b5fab2
Undo change to test
swissspidy Nov 2, 2022
86b4e65
Patch types instead
swissspidy Nov 2, 2022
9ed6537
Merge branch 'main' into add/12097-ts-jest
swissspidy Nov 7, 2022
b0ecf2b
Apply suggestions from code review
swissspidy Nov 7, 2022
940f3fe
Merge branch 'main' into add/12097-ts-jest
swissspidy Nov 8, 2022
51d8efd
Update lock file
swissspidy Nov 8, 2022
30dc7a2
lint fix
swissspidy Nov 8, 2022
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
12 changes: 12 additions & 0 deletions .eslintrc
Expand Up @@ -386,7 +386,9 @@
"files": [
"__mocks__/**/*.js",
"**/test/**/*.js",
"**/test/**/*.ts",
"**/testUtils/**/*.js",
"**/testUtils/**/*.ts",
"tests/js/**/*.js"
],
"excludedFiles": [
Expand Down Expand Up @@ -430,6 +432,16 @@
"testing-library/no-dom-import": "error"
}
},
{
"files": [
"**/test/**/*.ts",
"**/testUtils/**/*.ts"
],
"rules": {
"@typescript-eslint/unbound-method": "off",
"jest/unbound-method": "error"
}
},
{
"files": [
"__mocks__/**/*.js"
Expand Down