-
Notifications
You must be signed in to change notification settings - Fork 48
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
test(react-image): add test code for SuspenseImage
#999
test(react-image): add test code for SuspenseImage
#999
Conversation
🦋 Changeset detectedLatest commit: 40f0a91 The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
How about this
// @ts-expect-error: non-string src value for testing purposes | ||
render(<SuspenseImage src={123} alt="Test Image" />) | ||
}).toThrow('Image of @suspensive/react-image requires src') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
// @ts-expect-error: non-string src value for testing purposes | |
render(<SuspenseImage src={123} alt="Test Image" />) | |
}).toThrow('Image of @suspensive/react-image requires src') | |
// @ts-expect-error: non-string src value for testing purposes | |
render(<SuspenseImage src={123} alt="Test Image" />) | |
}).toThrow('<SuspenseImage/> of @suspensive/react-image requires string src') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks great! I've applied the change to SuspenseImage
and its test file :))
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #999 +/- ##
==========================================
+ Coverage 80.88% 87.33% +6.44%
==========================================
Files 38 38
Lines 450 450
Branches 98 98
==========================================
+ Hits 364 393 +29
+ Misses 77 54 -23
+ Partials 9 3 -6
|
CodSpeed Performance ReportMerging #999 will create unknown performance changesComparing Summary
|
…aul-atomrigs/suspensive into test/react-image/SuspenseImage
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Cool! Thanks! 👍
This PR was opened by the [Changesets release](https://github.com/changesets/action) GitHub action. When you're ready to do a release, you can merge this and the packages will be published to npm automatically. If you're not ready to do a release yet, that's fine, whenever you add more changesets to main, this PR will be updated. # Releases ## @suspensive/react-image@0.0.15 ### Patch Changes - [#999](#999) [`8862c2a`](8862c2a) Thanks [@saul-atomrigs](https://github.com/saul-atomrigs)! - test(react-image): add test code for `<SuspenseImage/>` Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
# Overview - Added test code for `SuspenseImage.tsx` in `react-image`. <img width="373" alt="Captura de pantalla 2024-06-28 a las 10 39 23 a m" src="https://github.com/toss/suspensive/assets/82362278/eea53c08-dc45-4ac3-a62f-59b2aa70ae24"> ## PR Checklist - [✅] I did below actions if need 1. I read the [Contributing Guide](https://github.com/toss/suspensive/blob/main/CONTRIBUTING.md) 2. I added documents and tests. --------- Co-authored-by: Jonghyeon Ko <jonghyeon@toss.im>
This PR was opened by the [Changesets release](https://github.com/changesets/action) GitHub action. When you're ready to do a release, you can merge this and the packages will be published to npm automatically. If you're not ready to do a release yet, that's fine, whenever you add more changesets to main, this PR will be updated. # Releases ## @suspensive/react-image@0.0.15 ### Patch Changes - [#999](#999) [`8862c2a`](8862c2a) Thanks [@saul-atomrigs](https://github.com/saul-atomrigs)! - test(react-image): add test code for `<SuspenseImage/>` Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
# Overview - Added test code for `SuspenseImage.tsx` in `react-image`. <img width="373" alt="Captura de pantalla 2024-06-28 a las 10 39 23 a m" src="https://github.com/toss/suspensive/assets/82362278/eea53c08-dc45-4ac3-a62f-59b2aa70ae24"> ## PR Checklist - [✅] I did below actions if need 1. I read the [Contributing Guide](https://github.com/toss/suspensive/blob/main/CONTRIBUTING.md) 2. I added documents and tests. ---------
This PR was opened by the [Changesets release](https://github.com/changesets/action) GitHub action. When you're ready to do a release, you can merge this and the packages will be published to npm automatically. If you're not ready to do a release yet, that's fine, whenever you add more changesets to main, this PR will be updated. # Releases ## @suspensive/react-image@0.0.15 ### Patch Changes - [#999](#999) [`8862c2a`](8862c2a) Thanks [@saul-atomrigs](https://github.com/saul-atomrigs)! - test(react-image): add test code for `<SuspenseImage/>`
# Overview - Added test code for `SuspenseImage.tsx` in `react-image`. <img width="373" alt="Captura de pantalla 2024-06-28 a las 10 39 23 a m" src="https://github.com/toss/suspensive/assets/82362278/eea53c08-dc45-4ac3-a62f-59b2aa70ae24"> ## PR Checklist - [✅] I did below actions if need 1. I read the [Contributing Guide](https://github.com/toss/suspensive/blob/main/CONTRIBUTING.md) 2. I added documents and tests. --------- Co-authored-by: Jonghyeon Ko <jonghyeon@toss.im>
This PR was opened by the [Changesets release](https://github.com/changesets/action) GitHub action. When you're ready to do a release, you can merge this and the packages will be published to npm automatically. If you're not ready to do a release yet, that's fine, whenever you add more changesets to main, this PR will be updated. # Releases ## @suspensive/react-image@0.0.15 ### Patch Changes - [#999](#999) [`8862c2a`](8862c2a) Thanks [@saul-atomrigs](https://github.com/saul-atomrigs)! - test(react-image): add test code for `<SuspenseImage/>`
# Overview - Added test code for `SuspenseImage.tsx` in `react-image`. <img width="373" alt="Captura de pantalla 2024-06-28 a las 10 39 23 a m" src="https://github.com/toss/suspensive/assets/82362278/eea53c08-dc45-4ac3-a62f-59b2aa70ae24"> ## PR Checklist - [✅] I did below actions if need 1. I read the [Contributing Guide](https://github.com/toss/suspensive/blob/main/CONTRIBUTING.md) 2. I added documents and tests. --------- Co-authored-by: Jonghyeon Ko <jonghyeon@toss.im>
This PR was opened by the [Changesets release](https://github.com/changesets/action) GitHub action. When you're ready to do a release, you can merge this and the packages will be published to npm automatically. If you're not ready to do a release yet, that's fine, whenever you add more changesets to main, this PR will be updated. # Releases ## @suspensive/react-image@0.0.15 ### Patch Changes - [#999](#999) [`8862c2a`](8862c2a) Thanks [@saul-atomrigs](https://github.com/saul-atomrigs)! - test(react-image): add test code for `<SuspenseImage/>`
Overview
SuspenseImage.tsx
inreact-image
.PR Checklist