Bug 127203 AssertionFailedException double-clicking on test failure in JUnit view
build I20060208-0848 - running the performance tests, one of the tests had an error - double-clicked on the item in the JUnit view - it did not open (source for the test was in my workspace) - log got: org.eclipse.jdt.internal.core.Assert$AssertionFailedException: Assertion failed; at org.eclipse.jdt.internal.core.Assert.isTrue(Assert.java:89) at org.eclipse.jdt.internal.core.Assert.isTrue(Assert.java:76) at org.eclipse.jdt.internal.core.SourceMethod.<init>(SourceMethod.java:33) at org.eclipse.jdt.internal.core.SourceType.getMethod(SourceType.java:368) at org.eclipse.jdt.internal.junit.ui.OpenTestAction.findMethod(OpenTestAction.java:82) at org.eclipse.jdt.internal.junit.ui.OpenTestAction.findElement(OpenTestAction.java:61) at org.eclipse.jdt.internal.junit.ui.OpenEditorAction.run(OpenEditorAction.java:56) at org.eclipse.jdt.internal.junit.ui.FailureTab.handleDefaultSelected(FailureTab.java:305) at org.eclipse.jdt.internal.junit.ui.FailureTab$2.widgetDefaultSelected(FailureTab.java:283) at org.eclipse.swt.widgets.TypedListener.handleEvent(TypedListener.java:97) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:66) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:925) at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:3287) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:2907) at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java:1793) at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:1757) at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:402) at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:143) at org.eclipse.ui.internal.ide.IDEApplication.run(IDEApplication.java:106) at org.eclipse.core.internal.runtime.PlatformActivator$1.run(PlatformActivator.java:109) at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:92) at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:68) at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:374) at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:169) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:64) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:615) at org.eclipse.core.launcher.Main.invokeFramework(Main.java:338) at org.eclipse.core.launcher.Main.basicRun(Main.java:282) at org.eclipse.core.launcher.Main.run(Main.java:977) at org.eclipse.core.launcher.Main.main(Main.java:952)
org.eclipse.jdt.junit/src/org/eclipse/jdt/internal/junit/ui/OpenTestAction.java
/*******************************************************************************
 * Copyright (c) 2000, 2005 IBM Corporation and others.
 * All rights reserved. This program and the accompanying materials
 * are made available under the terms of the Eclipse Public License v1.0
 * which accompanies this distribution, and is available at
 * http://www.eclipse.org/legal/epl-v10.html
 *
 * Contributors:
 *     IBM Corporation - initial API and implementation
 *******************************************************************************/
package org.eclipse.jdt.internal.junit.ui;
import org.eclipse.ui.PlatformUI;
import org.eclipse.ui.texteditor.ITextEditor;
import org.eclipse.jdt.core.IJavaElement;
import org.eclipse.jdt.core.IJavaProject;
import org.eclipse.jdt.core.IMethod;
import org.eclipse.jdt.core.ISourceRange;
import org.eclipse.jdt.core.IType;
import org.eclipse.jdt.core.ITypeHierarchy;
import org.eclipse.jdt.core.JavaModelException;
import org.eclipse.jdt.internal.junit.Messages;
import org.eclipse.jface.dialogs.MessageDialog;
/**
 * Open a class on a Test method.
 */
public class OpenTestAction extends OpenEditorAction {