-
Notifications
You must be signed in to change notification settings - Fork 39
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
Tests for sentences/utils.rs #88
base: main
Are you sure you want to change the base?
Conversation
Codecov ReportPatch and project coverage have no change.
Additional details and impacted files@@ Coverage Diff @@
## main #88 +/- ##
=======================================
Coverage 79.60% 79.60%
=======================================
Files 30 30
Lines 1123 1123
=======================================
Hits 894 894
Misses 229 229
Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. ☔ View full report in Codecov by Sentry. |
@@ -200,6 +200,79 @@ mod tests { | |||
assert_eq!(time.nanosecond(), 500_000_000); | |||
} | |||
|
|||
#[test] | |||
#[should_panic] |
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.
Which of the 2 tests here should panic? Maybe you can split them if they both need to panic as this will only check the first one
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.
A good approach would be to check the actual error that is returned that just expect a panic. A panic might be occurring for something different that you are expecting in a specific test case so try to assert a specific error on each test.
This will make sure that your test is failing of the right reasons that you expect it to.
@gflow33 Do you have any progress on these tests? |
@gflow33 have you made any progress on this PR? |
Additional tests for sentences/utils.rs, tests are meant to fail but are written in different ways. Please review and tell me the best way to proceed