@Test public void testNavigate_negative() { getComponent(EditSourceUtil.class)._setNavigator(new EditSourceUtil.Navigator() { @Override public void navigate(NavigationItem item, boolean requestFocus, boolean useCurrentWindow) { handler.fail("Not expected"); } }); createTestClazz(); boolean result = new ReadAction<Boolean>() { @Override protected void run(Result<Boolean> result) throws Throwable { result.setResult(new MyRecognizer().navigate(getProject(), "goto:c=test.Clazz2&f=Clazz2&l=3")); } }.execute().getResultObject(); Assert.assertTrue(result); }
public boolean navigate(Project project, String hyperlink) { if(hyperlink.startsWith("goto:")) { openEditor(project, hyperlink.substring(5)); return true; } else { return false; } }
ClassRecognizer implements Recognizer { public boolean navigate(Project project, String hyperlink) { if(hyperlink.startsWith("goto:")) { openEditor(project, hyperlink.substring(5)); return true; } else { return false; } } }
ClassRecognizer implements Recognizer { public boolean navigate(Project project, String hyperlink) { if(hyperlink.startsWith("goto:")) { openEditor(project, hyperlink.substring(5)); return true; } else { return false; } }  }
ClassRecognizer implements Recognizer { public boolean navigate(Project project, String hyperlink) { if(hyperlink.startsWith("goto:")) { openEditor(project, hyperlink.substring(5)); return true; } else { return false; } }  boolean navigate(Project project, String hyperlink); }
ClassRecognizer implements Recognizer { public boolean navigate(Project project, String hyperlink) { if(hyperlink.startsWith("goto:")) { openEditor(project, hyperlink.substring(5)); return true; } else { return false; } }  boolean navigate(Project project, String hyperlink);  }