mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
junit sm: accept null method names in list nodes
This commit is contained in:
+1
@@ -34,6 +34,7 @@ public class JUnitTreeByDescriptionHierarchyTest {
|
||||
@Test
|
||||
public void testEmptySuite() throws Exception {
|
||||
doTest(Description.createSuiteDescription("empty suite"), "##teamcity[enteredTheMatrix]\n" +
|
||||
"##teamcity[suiteTreeNode name='empty suite' locationHint='java:test://empty suite.empty suite']\n" +
|
||||
"##teamcity[treeEnded]\n");
|
||||
}
|
||||
|
||||
|
||||
@@ -220,6 +220,11 @@ public class JUnit4TestListener extends RunListener {
|
||||
if (methodName != null && (parent == null || !isParameter(parent))) {
|
||||
methodName = getShortName(JUnit4ReflectionUtil.getClassName(description)) + "." + methodName;
|
||||
}
|
||||
|
||||
if (methodName == null && description.getChildren().isEmpty()) {
|
||||
methodName = description.getDisplayName();
|
||||
}
|
||||
|
||||
myMethodNames.put(description, methodName);
|
||||
}
|
||||
return methodName;
|
||||
|
||||
Reference in New Issue
Block a user