From d928e6e6af7d092f48d640cf6a23eecf7e0e0113 Mon Sep 17 00:00:00 2001 From: Sergey Ignatov Date: Tue, 27 Mar 2018 16:56:30 +0300 Subject: [PATCH] test discovery: show tests for methods from anonymous classes, fix UI --- .../testDiscovery/actions/ShowDiscoveredTestsAction.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/java/execution/impl/src/com/intellij/execution/testDiscovery/actions/ShowDiscoveredTestsAction.java b/java/execution/impl/src/com/intellij/execution/testDiscovery/actions/ShowDiscoveredTestsAction.java index d5a3d73cc019..c93dd295c52e 100644 --- a/java/execution/impl/src/com/intellij/execution/testDiscovery/actions/ShowDiscoveredTestsAction.java +++ b/java/execution/impl/src/com/intellij/execution/testDiscovery/actions/ShowDiscoveredTestsAction.java @@ -104,7 +104,7 @@ public class ShowDiscoveredTestsAction extends AnAction { String fqn = couple != null ? couple.first : null; if (fqn == null || c == null) return; String methodName = couple.second; - String methodPresentationName = c.getName() + "." + methodName; + String methodPresentationName = ClassUtil.extractClassName(fqn) + "." + methodName; DataContext dataContext = DataManager.getInstance().getDataContext(e.getRequiredData(EDITOR).getContentComponent()); FeatureUsageTracker.getInstance().triggerFeatureUsed("test.discovery");