import java.util.List;
import java.util.UUID;
+import org.eclipse.tracecompass.ctf.core.CTFException;
import org.eclipse.tracecompass.ctf.core.event.IEventDeclaration;
import org.eclipse.tracecompass.ctf.core.tests.shared.CtfTestTrace;
-import org.eclipse.tracecompass.ctf.core.trace.CTFReaderException;
import org.eclipse.tracecompass.ctf.core.trace.CTFStream;
import org.eclipse.tracecompass.ctf.core.trace.CTFTrace;
import org.eclipse.tracecompass.ctf.core.trace.Metadata;
/**
* Perform pre-test initialization.
*
- * @throws CTFReaderException
+ * @throws CTFException
*/
@Before
- public void setUp() throws CTFReaderException {
+ public void setUp() throws CTFException {
assumeTrue(testTrace.exists());
fixture = new Metadata(testTrace.getTrace());
}
}
@Test
- public void testTextMD() throws CTFReaderException {
+ public void testTextMD() throws CTFException {
testSingleFragment();
}
- protected CTFTrace testSingleFragment() throws CTFReaderException {
+ protected CTFTrace testSingleFragment() throws CTFException {
fixture = new Metadata();
CTFTrace trace = fixture.getTrace();
for (CTFStream s : trace.getStreams()) {
}
@Test
- public void testStreamTextMD() throws CTFReaderException {
+ public void testStreamTextMD() throws CTFException {
CTFTrace trace = testSingleFragment();
fixture.parseTextFragment(mdSecond);
final List<IEventDeclaration> eventDeclarations = new ArrayList<>(trace.getEventDeclarations(0L));
/**
* Run the ByteOrder getDetectedByteOrder() method test.
*
- * @throws CTFReaderException
+ * @throws CTFException
*/
@Test
- public void testGetDetectedByteOrder() throws CTFReaderException {
+ public void testGetDetectedByteOrder() throws CTFException {
setUp();
ByteOrder result = fixture.getDetectedByteOrder();
assertNull(result);
/**
* Test toString
*
- * @throws CTFReaderException
+ * @throws CTFException
*/
@Test
- public void testToString() throws CTFReaderException {
+ public void testToString() throws CTFException {
setUp();
String result = fixture.toString();
assertNotNull(result);
/**
* Run the void parse() method test.
*
- * @throws CTFReaderException
+ * @throws CTFException
*/
@Test
- public void testParse() throws CTFReaderException {
+ public void testParse() throws CTFException {
setUp();
assertEquals(new UUID(0xd18e637435a1cd42L, 0x8e70a9cffa712793L), testTrace.getTrace().getUUID());
assertEquals(1332166405241713920.0, testTrace.getTrace().getClock().getClockOffset(), 200.0);