-
Notifications
You must be signed in to change notification settings - Fork 373
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(gnoclient): Fix a potential bug in the integration test #2558
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #2558 +/- ##
==========================================
- Coverage 54.96% 54.88% -0.08%
==========================================
Files 595 595
Lines 79568 79356 -212
==========================================
- Hits 43734 43557 -177
+ Misses 32527 32506 -21
+ Partials 3307 3293 -14
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
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.
Using assert
will fail the test, but still eventually panic, as asserts don't stop the execution of the test; require
does.
…#2558) ![Screenshot from 2024-07-09 21-48-59](https://github.com/gnolang/gno/assets/167175638/a4429fb7-c277-4296-86fb-f55dfaa924ca) I'm not sure about the root cause, but it seems like the test node isn't ready to handle the request call, so it returns an error. Using the result immediately without asserting that there's no error will cause this section to panic, leading to a CI that fails randomly You can see https://github.com/gnolang/gno/actions/runs/9855164413/job/27209502761?pr=2518 <!-- please provide a detailed description of the changes made in this pull request. --> <details><summary>Contributors' checklist...</summary> - [ ] Added new tests, or not needed, or not feasible - [ ] Provided an example (e.g. screenshot) to aid review or the PR is self-explanatory - [ ] Updated the official documentation or not needed - [ ] No breaking changes were made, or a `BREAKING CHANGE: xxx` message was included in the description - [ ] Added references to related issues and PRs - [ ] Provided any useful hints for running manual tests - [ ] Added new benchmarks to [generated graphs](https://gnoland.github.io/benchmarks), if any. More info [here](https://github.com/gnolang/gno/blob/master/.benchmarks/README.md). </details> --------- Co-authored-by: Morgan <[email protected]>
I'm not sure about the root cause, but it seems like the test node isn't ready to handle the request call, so it returns an error. Using the result immediately without asserting that there's no error will cause this section to panic, leading to a CI that fails randomly
You can see https://github.com/gnolang/gno/actions/runs/9855164413/job/27209502761?pr=2518
Contributors' checklist...
BREAKING CHANGE: xxx
message was included in the description