You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@ant.apache.org by bu...@apache.org on 2019/08/27 13:42:35 UTC
[Bug 63702] New: attribute "skipNonTests"
ignores concrete classes that derive from classes with @Test annotated
methods
https://bz.apache.org/bugzilla/show_bug.cgi?id=63702
Bug ID: 63702
Summary: <junit> <batchtest> attribute "skipNonTests" ignores
concrete classes that derive from classes with @Test
annotated methods
Product: Ant
Version: 1.10.6
Hardware: PC
Status: NEW
Severity: normal
Priority: P2
Component: Core tasks
Assignee: notifications@ant.apache.org
Reporter: tonnitielens@gmail.com
Target Milestone: ---
Consider the following files:
build.xml:
...
<batchtest todir="somedir" skipNonTests="true">
<fileset dir="somedir2" includes="**/*.class" />
</batchtest>
...
BaseTest.java:
public abstract Base {
@Test
public void doSomeTest();
}
ChildTest.java:
public class Child extends Base {
@Override
public void doSomeTest() {
assertTrue(false);
}
}
I would expect Ant to run the doSomeTest in Child, as it's base method is
annotated with @Test. When having set skipNonTests to "true", no methods in
ChildTest are considered as test methods, unless explicitly annotated with
@Test too.
When reading the documentation for skipNonTests, I see how this might be
implemented as documented, but the behavior is different than you would expect,
coming from running tests in IDEs, like Eclipse or IntelliJ IDEA, which do
consider Child.doSomeTest to be a test method.
--
You are receiving this mail because:
You are the assignee for the bug.
[Bug 63702] attribute "skipNonTests" ignores
concrete classes that derive from classes with @Test annotated methods
Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=63702
Tonni <to...@gmail.com> changed:
What |Removed |Added
----------------------------------------------------------------------------
OS| |All
CC| |tonnitielens@gmail.com
--
You are receiving this mail because:
You are the assignee for the bug.