Skip to content

Commit 3d0cfca

Browse files
author
Alex Cory
committed
updated package.json deps, fixed console hack, got testing working for console.error
1 parent b342c1b commit 3d0cfca

File tree

5 files changed

+911
-862
lines changed

5 files changed

+911
-862
lines changed

config/setupTests.ts

-16
Original file line numberDiff line numberDiff line change
@@ -3,19 +3,3 @@ import { GlobalWithFetchMock } from 'jest-fetch-mock'
33
const customGlobal: GlobalWithFetchMock = global as GlobalWithFetchMock
44
customGlobal.fetch = require('jest-fetch-mock')
55
customGlobal.fetchMock = customGlobal.fetch
6-
7-
// this is just a little hack to silence a warning that we'll get until react
8-
// fixes this: https://github.com/facebook/react/pull/14853
9-
const originalError = console.error
10-
beforeAll(() => {
11-
console.error = (...args: any[]) => {
12-
if (/Warning.*not wrapped in act/.test(args[0])) {
13-
return
14-
}
15-
originalError.call(console, ...args)
16-
}
17-
})
18-
19-
afterAll(() => {
20-
console.error = originalError
21-
})

package.json

+24-23
Original file line numberDiff line numberDiff line change
@@ -12,41 +12,42 @@
1212
"use-ssr": "^1.0.22"
1313
},
1414
"peerDependencies": {
15-
"react": "^16.13.0",
16-
"react-dom": "^16.13.0"
15+
"react": "^16.13.1",
16+
"react-dom": "^16.13.1"
1717
},
1818
"devDependencies": {
19-
"@testing-library/react": "^10.0.0",
20-
"@testing-library/react-hooks": "^3.0.0",
21-
"@types/fetch-mock": "^7.2.3",
22-
"@types/jest": "^25.1.0",
23-
"@types/node": "^13.9.0",
24-
"@types/react": "^16.9.23",
25-
"@types/react-dom": "^16.8.4",
26-
"@typescript-eslint/eslint-plugin": "^2.23.0",
27-
"@typescript-eslint/parser": "^2.23.0",
19+
"@testing-library/react": "^10.0.2",
20+
"@testing-library/react-hooks": "^3.2.1",
21+
"@types/fetch-mock": "^7.3.2",
22+
"@types/jest": "^25.1.4",
23+
"@types/node": "^13.9.8",
24+
"@types/react": "^16.9.30",
25+
"@types/react-dom": "^16.9.5",
26+
"@typescript-eslint/eslint-plugin": "^2.26.0",
27+
"@typescript-eslint/parser": "^2.26.0",
2828
"convert-keys": "^1.3.4",
2929
"eslint": "^6.8.0",
30-
"eslint-config-standard": "^14.1.0",
31-
"eslint-plugin-import": "^2.20.1",
32-
"eslint-plugin-jest": "23.8.2",
30+
"eslint-config-standard": "^14.1.1",
31+
"eslint-plugin-import": "^2.20.2",
32+
"eslint-plugin-jest": "^23.8.2",
3333
"eslint-plugin-jest-formatting": "^1.2.0",
34-
"eslint-plugin-jsx-a11y": "^6.2.1",
35-
"eslint-plugin-node": "^11.0.0",
34+
"eslint-plugin-jsx-a11y": "^6.2.3",
35+
"eslint-plugin-node": "^11.1.0",
3636
"eslint-plugin-promise": "^4.2.1",
3737
"eslint-plugin-react": "^7.19.0",
38-
"eslint-plugin-react-hooks": "^2.5.0",
38+
"eslint-plugin-react-hooks": "^3.0.0",
3939
"eslint-plugin-standard": "^4.0.1",
4040
"eslint-watch": "^6.0.1",
41-
"jest": "^25.1.0",
41+
"jest": "^25.2.4",
4242
"jest-fetch-mock": "^3.0.3",
43+
"jest-mock-console": "^1.0.0",
4344
"mockdate": "^2.0.5",
44-
"react": "^16.8.6",
45-
"react-dom": "^16.8.6",
45+
"react": "^16.13.1",
46+
"react-dom": "^16.13.1",
4647
"react-hooks-testing-library": "^0.6.0",
47-
"react-test-renderer": "^16.8.6",
48-
"ts-jest": "^25.2.1",
49-
"typescript": "^3.4.5",
48+
"react-test-renderer": "^16.13.1",
49+
"ts-jest": "^25.3.0",
50+
"typescript": "^3.8.3",
5051
"utility-types": "^3.10.0",
5152
"watch": "^1.0.2"
5253
},

0 commit comments

Comments
 (0)