You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If you have a test file that has a typo in it, and accidentally looks like this:
# src/foo_test.jl
@testitem "test 1" begin
...
end
@testiteem "test 2" begin
...
end
You'll notice that there is a typo in the definition of test 2: @testiteem.
But since this file isn't included anywhere, it's never actually executed by anything, and so no one will ever warn you that this test item macro is malformed! 😱
So it seems like we'll need some kind of ability to report on lines in a "test file" that weren't covered.
Maybe this is just integrating with the standard coverage report, and generating code coverage on the test files? Maybe that'll "just work" if you put your testitems in the src/ directory?
The text was updated successfully, but these errors were encountered:
Another option would be to have a "strict test file" option. If that is enabled, if there is a Julia file that has anything other than @testitem or @testsetup in it, then we report an error. Could even be a separate file extension, I guess?
If you have a test file that has a typo in it, and accidentally looks like this:
You'll notice that there is a typo in the definition of
test 2
:@testiteem
.But since this file isn't included anywhere, it's never actually executed by anything, and so no one will ever warn you that this test item macro is malformed! 😱
So it seems like we'll need some kind of ability to report on lines in a "test file" that weren't covered.
Maybe this is just integrating with the standard coverage report, and generating code coverage on the test files? Maybe that'll "just work" if you put your testitems in the
src/
directory?The text was updated successfully, but these errors were encountered: