lttng: Port unit tests to JUnit4
[deliverable/tracecompass.git] / org.eclipse.linuxtools.lttng2.kernel.core.tests / src / org / eclipse / linuxtools / lttng2 / kernel / core / tests / stateprovider / CtfKernelStateInputTest.java
CommitLineData
efc403bb
AM
1/*******************************************************************************
2 * Copyright (c) 2012 Ericsson
3 * Copyright (c) 2010, 2011 École Polytechnique de Montréal
4 * Copyright (c) 2010, 2011 Alexandre Montplaisir <alexandre.montplaisir@gmail.com>
e743c3b8 5 *
efc403bb
AM
6 * All rights reserved. This program and the accompanying materials are
7 * made available under the terms of the Eclipse Public License v1.0 which
8 * accompanies this distribution, and is available at
9 * http://www.eclipse.org/legal/epl-v10.html
e743c3b8 10 *
efc403bb
AM
11 *******************************************************************************/
12
13package org.eclipse.linuxtools.lttng2.kernel.core.tests.stateprovider;
14
b4f71e4a 15import static org.junit.Assert.assertEquals;
8020be3c 16
dc0f7bfe 17import org.eclipse.linuxtools.internal.lttng2.kernel.core.stateprovider.CtfKernelStateInput;
b4f71e4a 18import org.eclipse.linuxtools.tmf.core.exceptions.TmfTraceException;
18ab1d18 19import org.eclipse.linuxtools.tmf.core.statesystem.IStateChangeInput;
efc403bb
AM
20import org.junit.BeforeClass;
21import org.junit.Test;
efc403bb
AM
22
23/**
24 * Tests for the LTTng 2.0 kernel state provider
e743c3b8 25 *
2ba3d0a1 26 * @author Alexandre Montplaisir
efc403bb 27 */
dc0f7bfe 28public class CtfKernelStateInputTest {
efc403bb 29
ebd67b34 30 static IStateChangeInput input;
efc403bb 31
2ba3d0a1
AM
32 /**
33 * Set-up.
34 *
35 * @throws TmfTraceException
36 * If we can't find the test traces
37 */
efc403bb 38 @BeforeClass
b4f71e4a 39 public static void initialize() throws TmfTraceException {
dc0f7bfe 40 input = new CtfKernelStateInput(CtfTestFiles.getTestTrace());
efc403bb
AM
41
42 }
43
2ba3d0a1
AM
44 /**
45 * Test loading the state provider.
46 */
efc403bb
AM
47 @Test
48 public void testOpening() {
49 long testStartTime;
50 testStartTime = input.getStartTime();
dc0f7bfe 51 assertEquals(testStartTime, CtfTestFiles.startTime);
efc403bb
AM
52 }
53
efc403bb 54}
This page took 0.03284 seconds and 5 git commands to generate.