LTTng: CPU usage analysis from the LTTng kernel trace
[deliverable/tracecompass.git] / org.eclipse.linuxtools.tmf.core.tests / src / org / eclipse / linuxtools / tmf / core / tests / ctfadaptor / CtfLocationDataTest.java
index 2597bda52ca19886babeacb209305d3f5cabcc88..c5cadab591e2d3cbc97ba7f857c048a8a8cb1ee4 100644 (file)
@@ -1,5 +1,5 @@
 /*******************************************************************************
- * Copyright (c) 2012 Ericsson
+ * Copyright (c) 2012, 2013 Ericsson
  *
  * All rights reserved. This program and the accompanying materials are
  * made available under the terms of the Eclipse Public License v1.0 which
@@ -16,47 +16,27 @@ import static org.junit.Assert.assertEquals;
 import static org.junit.Assert.assertFalse;
 import static org.junit.Assert.assertTrue;
 
-import org.eclipse.linuxtools.tmf.core.ctfadaptor.CtfLocationData;
-import org.junit.After;
+import org.eclipse.linuxtools.tmf.core.ctfadaptor.CtfLocationInfo;
 import org.junit.Before;
 import org.junit.Test;
 
 /**
- * Collection of tests for the {@link CtfLocationData}
+ * Collection of tests for the {@link CtfLocationInfo}
  *
  * @author alexmont
  */
 public class CtfLocationDataTest {
 
-    private CtfLocationData fixture;
-
-    /**
-     * Launch the test.
-     *
-     * @param args
-     *            the command line arguments
-     */
-    public static void main(String[] args) {
-        new org.junit.runner.JUnitCore().run(CtfLocationDataTest.class);
-    }
+    private CtfLocationInfo fixture;
 
     /**
      * Perform pre-test initialization.
      */
     @Before
     public void setUp() {
-        fixture = new CtfLocationData(1, 0);
+        fixture = new CtfLocationInfo(1, 0);
     }
 
-    /**
-     * Perform post-test clean-up.
-     */
-    @After
-    public void tearDown() {
-        // Add additional tear down code here
-    }
-
-
     /**
      * Test for the .getTimestamp() and .getIndex() methods
      */
@@ -83,9 +63,9 @@ public class CtfLocationDataTest {
      */
     @Test
     public void testEquals() {
-        CtfLocationData same = new CtfLocationData(1, 0);
-        CtfLocationData diff1 = new CtfLocationData(100, 0);
-        CtfLocationData diff2 = new CtfLocationData(1, 10);
+        CtfLocationInfo same = new CtfLocationInfo(1, 0);
+        CtfLocationInfo diff1 = new CtfLocationInfo(100, 0);
+        CtfLocationInfo diff2 = new CtfLocationInfo(1, 10);
 
         assertTrue(fixture.equals(same));
         assertFalse(fixture.equals(diff1));
@@ -97,10 +77,10 @@ public class CtfLocationDataTest {
      */
     @Test
     public void testCompareTo() {
-        CtfLocationData same = new CtfLocationData(1, 0);
-        CtfLocationData smaller = new CtfLocationData(0, 0);
-        CtfLocationData bigger1 = new CtfLocationData(1000, 500);
-        CtfLocationData bigger2 = new CtfLocationData(1, 1);
+        CtfLocationInfo same = new CtfLocationInfo(1, 0);
+        CtfLocationInfo smaller = new CtfLocationInfo(0, 0);
+        CtfLocationInfo bigger1 = new CtfLocationInfo(1000, 500);
+        CtfLocationInfo bigger2 = new CtfLocationInfo(1, 1);
 
         assertEquals(0, same.compareTo(fixture));
         assertEquals(-1, smaller.compareTo(fixture));
@@ -113,7 +93,7 @@ public class CtfLocationDataTest {
      */
     @Test
     public void testToString() {
-        String expected = "Element [1/0]"; //$NON-NLS-1$
+        String expected = "Element [1/0]";
         assertEquals(expected, fixture.toString());
     }
 }
This page took 0.0279 seconds and 5 git commands to generate.