Closed alixlahuec closed 7 months ago
New and removed dependencies detected. Learn more about Socket for GitHub ↗︎
Package | New capabilities | Transitives | Size | Publisher |
---|---|---|---|---|
npm/@storybook/test@7.6.14 | environment, eval Transitive: filesystem, network, shell, unsafe | +370 |
36.1 MB | shilman |
npm/@types/jest@29.5.12 | Transitive: environment, filesystem, unsafe | +40 |
3.31 MB | types |
🚮 Removed packages: npm/@storybook/jest@0.2.3, npm/@storybook/testing-library@0.1.0
All modified and coverable lines are covered by tests :white_check_mark:
Comparison is base (
bb94cd4
) 85.72% compared to head (2ce9e7f
) 85.56%.:exclamation: Current head 2ce9e7f differs from pull request most recent head 0301398. Consider uploading reports for the commit 0301398 to get more accurate results
Description
Update Storybook testing dependencies, from the SB team's latest recommendations:
@storybook/jest
should be replaced by@storybook/test
@storybook/testing-library
should be replaced by@storybook/test
The switch to
@storybook/test
has a few implications:jest
object, but instead exports methods likefn
directly;@types/jest
as a dependency, even though it hasn't been needed up until now, and explicitly tells TSC to take into account typings from@testing-library/jest-dom
even though it's a transitive dependency; this isn't a very robust fix, but will get us through the migration here), and broke some tests that rely on matcher methods liketoBeInTheDocument
which don't come with Jest (which is why the PR importsexpect
from@storybook/test
in those specific test files, renames it tosbExpect
to avoid cross-use, and adds an ESLint pragma on lines where it's used)Validation
✅ All tests & stories are passing