From 48954bbd29f9a481ea368d6063e88d39417a2207 Mon Sep 17 00:00:00 2001 From: Anna Kozlova Date: Sun, 3 Jul 2016 12:45:16 +0300 Subject: [PATCH] testDiscovery for TestNG: apply chosen state --- .../testng/model/TestNGConfigurationModel.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/plugins/testng/src/com/theoryinpractice/testng/model/TestNGConfigurationModel.java b/plugins/testng/src/com/theoryinpractice/testng/model/TestNGConfigurationModel.java index db6076395e01..6053686d2f13 100644 --- a/plugins/testng/src/com/theoryinpractice/testng/model/TestNGConfigurationModel.java +++ b/plugins/testng/src/com/theoryinpractice/testng/model/TestNGConfigurationModel.java @@ -112,11 +112,11 @@ public class TestNGConfigurationModel data.MAIN_CLASS_NAME = ""; data.METHOD_NAME = ""; data.SUITE_NAME = ""; - } else if (TestType.METHOD == type || TestType.CLASS == type) { + } else if (TestType.METHOD == type || TestType.CLASS == type || TestType.SOURCE == type) { String className = getText(TestType.CLASS); data.GROUP_NAME = ""; data.SUITE_NAME = ""; - if (TestType.METHOD == type) + if (TestType.METHOD == type || TestType.SOURCE == type) data.METHOD_NAME = getText(TestType.METHOD); PsiClass psiClass = !getProject().isDefault() && !StringUtil.isEmptyOrSpaces(className) ? JUnitUtil.findPsiClass(className, module, getProject()) : null;