-
Notifications
You must be signed in to change notification settings - Fork 11
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
rename x to dz in mud_calculator.py
and decrease error tolerance for tests
#147
Conversation
@@ -19,4 +19,4 @@ def test_compute_mud(tmp_path): | |||
|
|||
expected_mud = 3 | |||
actual_mud = compute_mud(file) | |||
assert actual_mud == pytest.approx(expected_mud, rel=0.01, abs=0.1) | |||
assert actual_mud == pytest.approx(expected_mud, rel=1e-4, abs=1e-3) |
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.
decrease the error tolerance. I think previously I changed this to 0.01 and 0.1 because I thought about the edge cases like HfO2 wire data. But for the other better data (pretty much all other real data we ran) the error is much lower. So we can have a smaller tolerance here.
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.
This is a test, not code, so the logic is that we set the tolerance we want for the test, not some worst case scenario I think, right?
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #147 +/- ##
=======================================
Coverage 99.31% 99.31%
=======================================
Files 6 6
Lines 293 293
=======================================
Hits 291 291
Misses 2 2
|
mud_calculator.py
and decrease error range for testsmud_calculator.py
and decrease error tolerance for tests
Yes, great title! Thanks |
addressed comments in #146
@sbillinge ready for review
@bobleesj let me know if this title is more informative!