[jbosstools-issues] [JBoss JIRA] Created: (JBIDE-1734) The JBIDE1479Test test doesn't test jira 1479.
Snjezana Peco (JIRA)
jira-events at lists.jboss.org
Mon Feb 4 15:08:04 EST 2008
The JBIDE1479Test test doesn't test jira 1479.
----------------------------------------------
Key: JBIDE-1734
URL: http://jira.jboss.com/jira/browse/JBIDE-1734
Project: Tools (JBoss Tools)
Issue Type: Bug
Components: QA
Affects Versions: 2.0.0.GA
Reporter: Snjezana Peco
Priority: Minor
The problem in jira 1479 happens because VpeController.notifyChanged is called in non-UI thread. The test calls this method in the UI thread.
The correct test would be as follows:
...
assertNotNull("Editor input is null", input);
TestUtil.waitForJobs();
JSPMultiPageEditor part = openEditor(input);
TestUtil.waitForJobs();
assertNotNull(part);
Job job = new WorkspaceJob("Test"){
public IStatus runInWorkspace(IProgressMonitor monitor) {
try {
new FormatProcessorXML().formatFile(file);
} catch (Exception e) {
e.printStackTrace();
}
finished = true;
return Status.OK_STATUS;
}
};
job.setPriority(Job.SHORT);
job.schedule(0L);
TestUtil.waitForJobs();
while (!finished) {
TestUtil.delay(1000L);
}
TestUtil.delay(15000L);
PlatformUI.getWorkbench().getActiveWorkbenchWindow().getActivePage()
.closeAllEditors(false);
...
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.jboss.com/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
More information about the jbosstools-issues
mailing list