-
Notifications
You must be signed in to change notification settings - Fork 553
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
Blank lines and comments showing as "uncovered"? #92
Comments
Also, I tried pulling Spork out completely to make sure that's not contributing to the issue, and the results are still the same... |
Very awkward. There is issue #60, but that seems unrelated as it regards covered lines that are reported as uncovered, obviously caused by some double-require magic in Rails or Rspec. From what you say you're doing everything fine. If the odd behaviour always crops up only on subsequent runs, it might be a big in the result merger. I'll have to look further into this. Could you please try and to delete the coverage folder when this crops up, then re-run your suite and check if things are ok again? This would be somewhat of a proof that the merging code has some issue. |
Hmm...looks like I may have found the issue, and it's looking like you guys are in the clear and the problem is related to something hacky my team did to work around another issue. I'll close this issue if that turns out to be the cause. |
Idle timeout, closing because of issues spring cleaning :) @andyhite Please follow this one up when you find the time, and if the problem persists and seems to be SimpleCov's fault don't hesitate to re-open. |
I just came across this same issue but deleting the coverage folder and re-running tests seems to have fixed it. Maybe something to be added to the documentation? |
+1 deleting the coverage folder and running again fixed for me too. |
had the same issue. and worked for me aswell! |
It's strange, but removing coverage directory didn't work for me |
I've been using SimpleCov for two separate projects, and this problem seems to pop up in both of them for no apparent reason...
In some classes I get "missed lines" for blank lines (usually the whitespace between two methods - between the first method's end and the next method's def). This also seems to pop up (on occasion) for comment lines and the actual "end" of a method definition.
It seems like the blank lines are being counted as "relevant lines" when they shouldn't be.
I've had a few instances where on the first run of the report it shows everything at 100%, then on a subsequent run (without any change to the code) these blank lines show up.
Is this a known issue? Is caused by something I'm doing wrong or an issue with SimpleCov?
I'm using SimpleCov with Test::Unit (along with shoulda-context and shoulda-matchers). I use Spork for tests while developing, but run my test suite without Spork when I need a coverage report. The SimpleCov require and initialization are at the very top of my test_helper.rb and not inside the Spork.prefork or Spork.each_run blocks.
The text was updated successfully, but these errors were encountered: