EMMA marks package name as not covered
Brought to you by:
vlad_r
I have several source files. One of them starts like this:
package com.abc.def;
public abstract class AbstractDatabase
{
There are other files in that same package.
This file for some reason has the first line marked in red:
package com.abc.def; <<< MARKED RED
No other lines in the file are marked red, and no other files in that package have their first lines marked red.
Why is EMMA doing this?
The only classes I've seen where this happens is for enums. Apparently with enums the Java compiler generates some code and marks it as "line 1", which emma can't distinguish between generated code and code you wrote.
Another bug suggests it has to do with a class that has no default constructor so that the compiler creates one for you. All Java compiler code should be ignored.