Project: Eclipse_Platform_UI
Bug 92974 [IDE] (tests) Perf tests generate CCEs and NPEs in perf_301 branch
Reported: 2005-04-27 14:37:49 | Status: verified fixed

build I20050425-1700 When running the performance tests in the perf_301 branch against 3.0.1, several ClassCastExceptions and NullPointerExceptions in the console output, although no tests fail due to this. It's actually the Java browsing views that are failing, but it's due to the tests setting the workspace itself as the workbench page input, instead of the workspace root. The tests have been this way for a long time, but it's only the perf tests that show the problem, not the regular tests, because we iterate over all perspectives and views for the resize and layout tests. I'm adding a static method UITestCase.getPageInput(), which returns the workspace root, and using this in all the tests, in both HEAD and the perf_301 branches. Using the workspace root instead of the workspace itself is consistent with what the IDE does (see IDEWorkbenchAdvisor.getDefaultPageInput()).

Files changed in fix:
tests/org.eclipse.ui.tests/Eclipse UI Tests/org/eclipse/ui/tests/api/IDeprecatedWorkbenchPageTest.java tests/org.eclipse.ui.tests/Eclipse UI Tests/org/eclipse/ui/tests/api/IPageServiceTest.java tests/org.eclipse.ui.tests/Eclipse UI Tests/org/eclipse/ui/tests/api/IWorkbenchPageTest.java tests/org.eclipse.ui.tests/Eclipse UI Tests/org/eclipse/ui/tests/api/IWorkbenchTest.java tests/org.eclipse.ui.tests/Eclipse UI Tests/org/eclipse/ui/tests/api/SessionCreateTest.java tests/org.eclipse.ui.tests/Eclipse UI Tests/org/eclipse/ui/tests/dnd/DragTest.java tests/org.eclipse.ui.tests/Eclipse UI Tests/org/eclipse/ui/tests/performance/layout/EditorWidgetFactory.java tests/org.eclipse.ui.tests/Eclipse UI Tests/org/eclipse/ui/tests/performance/layout/PerspectiveWidgetFactory.java tests/org.eclipse.ui.tests/Eclipse UI Tests/org/eclipse/ui/tests/performance/layout/ViewWidgetFactory.java tests/org.eclipse.ui.tests/Eclipse UI Tests/org/eclipse/ui/tests/stress/OpenCloseTest.java tests/org.eclipse.ui.tests/UI Test Utils/org/eclipse/ui/tests/util/UITestCase.java