-
Notifications
You must be signed in to change notification settings - Fork 47.5k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Jack Pope
committed
Mar 26, 2024
1 parent
f73d11f
commit 31ac7d7
Showing
5 changed files
with
31 additions
and
11 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
/** | ||
* Copyright (c) Meta Platforms, Inc. and affiliates. | ||
* | ||
* This source code is licensed under the MIT license found in the | ||
* LICENSE file in the root directory of this source tree. | ||
* | ||
* @emails react-core | ||
*/ | ||
|
||
'use strict'; | ||
|
||
describe('shallow', () => { | ||
it('throws an error on init', () => { | ||
const ReactShallowRenderer = require('../shallow.js').default; | ||
expect(() => { | ||
// eslint-disable-next-line no-new | ||
new ReactShallowRenderer(); | ||
}).toThrow( | ||
'react-test-renderer/shallow has been removed. See https://react.dev/warnings/react-test-renderer.' | ||
); | ||
}); | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,9 @@ | ||
'use strict'; | ||
|
||
module.exports = require('react-shallow-renderer'); | ||
function ReactShallowRenderer() { | ||
throw new Error( | ||
'react-test-renderer/shallow has been removed. See https://react.dev/warnings/react-test-renderer.' | ||
); | ||
} | ||
|
||
module.exports = ReactShallowRenderer; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -13017,14 +13017,6 @@ [email protected]: | |
prop-types "^15.6.0" | ||
react-timer-mixin "^0.13.4" | ||
|
||
react-shallow-renderer@^16.15.0: | ||
version "16.15.0" | ||
resolved "https://registry.yarnpkg.com/react-shallow-renderer/-/react-shallow-renderer-16.15.0.tgz#48fb2cf9b23d23cde96708fe5273a7d3446f4457" | ||
integrity sha512-oScf2FqQ9LFVQgA73vr86xl2NaOIX73rh+YFqcOp68CWj56tSfgtGKrEbyhCj0rSijyG9M1CYprTh39fBi5hzA== | ||
dependencies: | ||
object-assign "^4.1.1" | ||
react-is "^16.12.0 || ^17.0.0 || ^18.0.0" | ||
|
||
react-timer-mixin@^0.13.4: | ||
version "0.13.4" | ||
resolved "https://registry.yarnpkg.com/react-timer-mixin/-/react-timer-mixin-0.13.4.tgz#75a00c3c94c13abe29b43d63b4c65a88fc8264d3" | ||
|