import java.net.URISyntaxException;
import java.net.URL;
import java.util.Vector;
+import java.util.concurrent.TimeUnit;
import org.eclipse.core.runtime.FileLocator;
import org.eclipse.core.runtime.Path;
/** Time-out tests after 20 seconds */
@Rule
- public TestRule globalTimeout= new Timeout(20000);
+ public TestRule globalTimeout= new Timeout(20, TimeUnit.SECONDS);
// ------------------------------------------------------------------------
// Variables
TmfTraceStub trace = new TmfTraceStub(testfile.toURI().getPath(), ITmfTrace.DEFAULT_TRACE_CACHE_SIZE, false, null);
trace.indexTrace(true);
- assertEquals("getType", ITmfEvent.class, trace.getType());
+ assertEquals("getEventType", ITmfEvent.class, trace.getEventType());
assertNull("getResource", trace.getResource());
assertEquals("getPath", testfile.toURI().getPath(), trace.getPath());
assertEquals("getCacheSize", ITmfTrace.DEFAULT_TRACE_CACHE_SIZE, trace.getCacheSize());
TmfTraceStub trace = new TmfTraceStub(testfile.toURI().getPath(), ITmfTrace.DEFAULT_TRACE_CACHE_SIZE, interval);
trace.indexTrace(true);
- assertEquals("getType", ITmfEvent.class, trace.getType());
+ assertEquals("getEventType", ITmfEvent.class, trace.getEventType());
assertNull("getResource", trace.getResource());
assertEquals("getPath", testfile.toURI().getPath(), trace.getPath());
assertEquals("getCacheSize", ITmfTrace.DEFAULT_TRACE_CACHE_SIZE, trace.getCacheSize());
TmfTraceStub trace = new TmfTraceStub(original);
trace.indexTrace(true);
- assertEquals("getType", ITmfEvent.class, trace.getType());
+ assertEquals("getEventType", ITmfEvent.class, trace.getEventType());
assertNull("getResource", trace.getResource());
assertEquals("getPath", testfile.toURI().getPath(), trace.getPath());
assertEquals("getCacheSize", ITmfTrace.DEFAULT_TRACE_CACHE_SIZE, trace.getCacheSize());
fail("TmfTrace.initialize() - Exception thrown");
}
- assertEquals("getType", ITmfEvent.class, trace.getType());
+ assertEquals("getEventType", ITmfEvent.class, trace.getEventType());
assertNull ("getResource", trace.getResource());
assertEquals("getPath", path, trace.getPath());
assertEquals("getCacheSize", ITmfTrace.DEFAULT_TRACE_CACHE_SIZE, trace.getCacheSize());
fail("TmfTrace.initialize() - Exception thrown");
}
- assertEquals("getType", ITmfEvent.class, trace.getType());
+ assertEquals("getEventType", ITmfEvent.class, trace.getEventType());
assertNull ("getResource", trace.getResource());
assertEquals("getPath", path, trace.getPath());
assertEquals("getCacheSize", ITmfTrace.DEFAULT_TRACE_CACHE_SIZE, trace.getCacheSize());
// Instantiate an "empty" trace
final TmfTraceStub trace = new TmfTraceStub();
- assertNull ("getType", trace.getType());
+ assertNull ("getEventType", trace.getEventType());
assertNull ("getResource", trace.getResource());
assertEquals("getCacheSize", ITmfTrace.DEFAULT_TRACE_CACHE_SIZE, trace.getCacheSize());
assertEquals("getStreamingInterval", 0, trace.getStreamingInterval());
fail("indexing");
}
- assertEquals("getType", ITmfEvent.class, trace.getType());
+ assertEquals("getEventType", ITmfEvent.class, trace.getEventType());
assertNull ("getResource", trace.getResource());
assertEquals("getCacheSize", ITmfTrace.DEFAULT_TRACE_CACHE_SIZE, trace.getCacheSize());
assertEquals("getStreamingInterval", 0, trace.getStreamingInterval());
@Test
public void testDefaultTmfTraceStub() {
assertFalse ("Open trace", fTrace == null);
- assertEquals("getType", ITmfEvent.class, fTrace.getType());
+ assertEquals("getEventType", ITmfEvent.class, fTrace.getEventType());
assertNull ("getResource", fTrace.getResource());
assertEquals("getStreamingInterval", 0, fTrace.getStreamingInterval());
assertEquals("getName", TEST_TRACE.getPath(), fTrace.getName());