-
Notifications
You must be signed in to change notification settings - Fork 3
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
Use TestItems.jl #153
Use TestItems.jl #153
Conversation
change_entropy=-3.1086244689504383e-15) | ||
|
||
@test_allocations(semi, sol, allocs=10_000) | ||
@test_allocations(semi, sol, allocs=2_000) |
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.
I needed to increase the allocations from 1_500
to 2_000
for some reason to make the test pass (the number of allocations was 1_920
). I have no idea why this was necessary. The same holds for the upwind allocations of the next @testitem
.
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.
Interesting. I also have no immediate idea. Could be caused by less effective constant propagation or something like this 🤷
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.
Ok, but I think it's fine. It's only marginal.
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #153 +/- ##
=======================================
Coverage 97.97% 97.97%
=======================================
Files 19 19
Lines 1776 1776
=======================================
Hits 1740 1740
Misses 36 36 ☔ 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.
Sounds reasonable. I didn't read all the code changes in detail.
With the current testing setup it is quite cumbersome to run only certain tests. I usually just commented all the other tests by hand. By using TestItems.jl and TestItemRunner.jl this is much more convenient because single test items can be run separately in VScode. The usual testing workflow using
]test
still works. Additionally, running tests is much faster this way. We also don't need the@trixi_testset
macro anymore.See also https://www.julia-vscode.org/docs/stable/userguide/testitems/.