Bug 68058 NPE in JUnit view [JUnit]
RC3, probably happens on all platforms - open a JUnit view --> should open empty - right-click in the Failure Trace table at the bottom and the following exception occurs: java.lang.NullPointerException at org.eclipse.jdt.internal.junit.ui.FailureTrace.menuAboutToShow(FailureTrace.java:111) at org.eclipse.jface.action.MenuManager.fireAboutToShow(MenuManager.java:286) at org.eclipse.jface.action.MenuManager.handleAboutToShow(MenuManager.java:370) at org.eclipse.jface.action.MenuManager.access$0(MenuManager.java:367) at org.eclipse.jface.action.MenuManager$2.menuShown(MenuManager.java:383) at org.eclipse.swt.widgets.TypedListener.handleEvent(TypedListener.java:116) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:82) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:731) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:752) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:735) at org.eclipse.swt.widgets.Menu.setVisible(Menu.java:784) at org.eclipse.swt.widgets.Control.showMenu(Control.java:2537) at org.eclipse.swt.widgets.Control.XButtonPress(Control.java:2925) at org.eclipse.swt.widgets.Composite.XButtonPress(Composite.java:812) at org.eclipse.swt.widgets.Widget.windowProc(Widget.java:903) at org.eclipse.swt.widgets.Display.windowProc(Display.java:3478) at org.eclipse.swt.internal.motif.OS.XtDispatchEvent(Native Method) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:2640) at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java:1375) at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:1346) at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:252) at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:141) at org.eclipse.ui.internal.ide.IDEApplication.run(IDEApplication.java:96) at org.eclipse.core.internal.runtime.PlatformActivator$1.run(PlatformActivator.java:335) at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:272) at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:128) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:324) at org.eclipse.core.launcher.Main.basicRun(Main.java:186) at org.eclipse.core.launcher.Main.run(Main.java:647) at org.eclipse.core.launcher.Main.main(Main.java:631)
org.eclipse.jdt.junit/src/org/eclipse/jdt/internal/junit/ui/FailureTrace.java
String pattern;
		int len;
		for (int i= (patterns.length - 1); i >= 0; --i) {
			pattern= patterns[i];
			len= pattern.length() - 1;
			if (pattern.charAt(len) == '*') {
				
				pattern= pattern.substring(0, len);
			} else if (Character.isUpperCase(pattern.charAt(0))) {
				
				pattern= FRAME_PREFIX + pattern + '.';
			} else {
				
				final int lastDotIndex= pattern.lastIndexOf('.');
				if ((lastDotIndex != -1) && (lastDotIndex != len) && Character.isUpperCase(pattern.charAt(lastDotIndex + 1)))
					pattern += '.'; 
			}
			if (line.indexOf(pattern) > 0)
				return true;
		}		
		return false;
	}
    public TestRunInfo getFailedTest() {
        return fFailure;
    }
    public Shell getShell() {
        return fTable.getShell();
    }
}