tmf: Fix GTK bug when setting top item after changing tree font
[deliverable/tracecompass.git] / lttng / org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests / src / org / eclipse / tracecompass / lttng2 / kernel / ui / swtbot / tests / KernelTest.java
index b7fa743720ef55ab3d300977cbab9d242d4fec4f..5feac5f10079998ebeafe183374d5dbacd902f97 100644 (file)
@@ -27,7 +27,7 @@ import org.eclipse.swtbot.swt.finder.finders.UIThreadRunnable;
 import org.eclipse.swtbot.swt.finder.junit.SWTBotJunit4ClassRunner;
 import org.eclipse.swtbot.swt.finder.results.BoolResult;
 import org.eclipse.swtbot.swt.finder.utils.SWTBotPreferences;
-import org.eclipse.tracecompass.tmf.ctf.core.tests.shared.CtfTmfTestTrace;
+import org.eclipse.tracecompass.ctf.core.tests.shared.LttngKernelTraceGenerator;
 import org.eclipse.tracecompass.tmf.ui.swtbot.tests.shared.ConditionHelpers;
 import org.eclipse.tracecompass.tmf.ui.swtbot.tests.shared.SWTBotUtils;
 import org.eclipse.ui.PlatformUI;
@@ -49,7 +49,6 @@ public class KernelTest {
     private static final String TRACE_TYPE = "org.eclipse.linuxtools.lttng2.kernel.tracetype";
     private static final String KERNEL_PERSPECTIVE_ID = "org.eclipse.linuxtools.lttng2.kernel.ui.perspective";
     private static final String TRACE_PROJECT_NAME = "test";
-    private static final CtfTmfTestTrace CTT = CtfTmfTestTrace.SYNTHETIC_TRACE;
 
     /** The workbench bot */
     protected static SWTWorkbenchBot fBot;
@@ -62,7 +61,7 @@ public class KernelTest {
      */
     @BeforeClass
     public static void beforeClass() {
-        SWTBotUtils.failIfUIThread();
+        SWTBotUtils.initialize();
 
         /* set up for swtbot */
         SWTBotPreferences.TIMEOUT = 20000; /* 20 second timeout */
@@ -80,9 +79,10 @@ public class KernelTest {
         }
         /* Switch perspectives */
         switchKernelPerspective();
+        /* Create the trace project */
+        SWTBotUtils.createProject(TRACE_PROJECT_NAME);
         /* Finish waiting for eclipse to load */
         SWTBotUtils.waitForJobs();
-        SWTBotUtils.createProject(TRACE_PROJECT_NAME);
     }
 
     /**
@@ -119,8 +119,8 @@ public class KernelTest {
      */
     @Before
     public void before() {
-        SWTBotUtils.openTrace(TRACE_PROJECT_NAME, CTT.getPath(), TRACE_TYPE);
-        SWTBotUtils.activateEditor(fBot, CTT.getTrace().getName());
+        SWTBotUtils.openTrace(TRACE_PROJECT_NAME, LttngKernelTraceGenerator.getPath(), TRACE_TYPE);
+        SWTBotUtils.activateEditor(fBot, LttngKernelTraceGenerator.getName());
     }
 
     /**
This page took 0.025035 seconds and 5 git commands to generate.