File tree Expand file tree Collapse file tree 3 files changed +6
-3
lines changed
packages/jest-leak-detector Expand file tree Collapse file tree 3 files changed +6
-3
lines changed Original file line number Diff line number Diff line change 22
33### Fixes
44
5+ * ` [jest-leak-detector] ` Removed the reference to ` weak ` . Now, parent projects
6+ must install it by hand for the module to work.
57* ` [expect] ` Fail test when the types of ` stringContaining ` and ` stringMatching `
68 matchers do not match. ([ #5069 ] ( https://github.com/facebook/jest/pull/5069 ) )
79* ` [jest-cli] ` Treat dumb terminals as noninteractive
Original file line number Diff line number Diff line change 1010 "dependencies" : {
1111 "pretty-format" : " ^22.0.3"
1212 },
13- "optionalDependencies " : {
13+ "devDependencies " : {
1414 "weak" : " ^1.0.1"
1515 }
1616}
Original file line number Diff line number Diff line change @@ -37,15 +37,16 @@ export default class {
3737 let weak ;
3838
3939 try {
40+ // eslint-disable-next-line import/no-extraneous-dependencies
4041 weak = require ( 'weak' ) ;
4142 } catch ( err ) {
4243 if ( ! err || err . code !== 'MODULE_NOT_FOUND' ) {
4344 throw err ;
4445 }
4546
4647 throw new Error (
47- 'The leaking detection mechanism requires the "weak" package to work. ' +
48- 'Please make sure that you can install the native dependency on your platform. ' ,
48+ 'The leaking detection mechanism requires the "weak" package to be installed and work. ' +
49+ 'Please install it as a dependency on your main project ' ,
4950 ) ;
5051 }
5152
You can’t perform that action at this time.
0 commit comments