It looks like the class MyProgramis in the same package of yours AbstractTestClass. If so, then it can get access to protectedand publicthe members of the classes in the same package.
Coverage in Java tutorials:
Modifier Class Package Subclass World
public Y Y Y Y
protected Y Y Y N
no modifier Y Y N N
private Y N N N
To fix this, simply move AbstractTestClassto another package. Similarly for other relevant classes.
Additional Information:
source
share