tmf.core: Introduce TmfTimestamp factory methods
[deliverable/tracecompass.git] / tmf / org.eclipse.tracecompass.tmf.core.tests / src / org / eclipse / tracecompass / tmf / core / tests / trace / indexer / FlatArrayTest.java
index 4774586182b06e34937fd48b205df7e04995e534..13bec30017885762f295b44bc5f625b0e14f67c2 100644 (file)
@@ -51,11 +51,11 @@ public class FlatArrayTest extends AbstractCheckpointCollectionTest {
     @Test
     public void testBinarySearch() {
         for (long i = 0; i < CHECKPOINTS_INSERT_NUM; i++) {
-            TmfCheckpoint checkpoint = new TmfCheckpoint(new TmfTimestamp(i), new TmfLongLocation(i), 0);
+            TmfCheckpoint checkpoint = new TmfCheckpoint(TmfTimestamp.fromSeconds(i), new TmfLongLocation(i), 0);
             fFlatArray.insert(checkpoint);
         }
 
-        TmfCheckpoint expectedCheckpoint = new TmfCheckpoint(new TmfTimestamp(122), new TmfLongLocation(122L), 0);
+        TmfCheckpoint expectedCheckpoint = new TmfCheckpoint(TmfTimestamp.fromSeconds(122), new TmfLongLocation(122L), 0);
         int expectedRank = 122;
 
         long rank = fFlatArray.binarySearch(expectedCheckpoint);
@@ -77,7 +77,7 @@ public class FlatArrayTest extends AbstractCheckpointCollectionTest {
 
         for (int i = 0; i < CHECKPOINTS_INSERT_NUM; i++) {
             int checkpointIndex = list.get(i);
-            TmfCheckpoint checkpoint = new TmfCheckpoint(new TmfTimestamp(12345 + checkpointIndex),
+            TmfCheckpoint checkpoint = new TmfCheckpoint(TmfTimestamp.fromSeconds(12345 + checkpointIndex),
                     new TmfLongLocation(123456L + checkpointIndex), checkpointIndex);
             ITmfCheckpoint found = fFlatArray.get(checkpointIndex);
             assertEquals(checkpoint, found);
This page took 0.026932 seconds and 5 git commands to generate.