Skip to main content
aboutsummaryrefslogtreecommitdiffstats
blob: f1621112ec1d7225f7962dd35facad74fcdad9d5 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
/*******************************************************************************
 * Copyright (c) 2011, 2012 Anton Gorenkov
 *
 * This program and the accompanying materials
 * are made available under the terms of the Eclipse Public License 2.0
 * which accompanies this distribution, and is available at
 * https://www.eclipse.org/legal/epl-2.0/
 *
 * SPDX-License-Identifier: EPL-2.0
 *
 * Contributors:
 *     Anton Gorenkov  - initial implementation
 *******************************************************************************/
package org.eclipse.cdt.testsrunner.core;

import org.eclipse.cdt.testsrunner.internal.model.TestCase;
import org.eclipse.cdt.testsrunner.internal.model.TestModelManager;
import org.eclipse.cdt.testsrunner.internal.model.TestSuite;
import org.eclipse.cdt.testsrunner.model.ITestSuite;


/**
 * Tests on the test cases reordering in TestModelManager.
 */
@SuppressWarnings("nls")
public class TestModelManagerCasesReorderingTestCase extends TestModelManagerBaseReorderingTestCase {
	
	@Override
	protected ITestSuite createTestsHierarchy() {
		TestSuite rootTestSuite = new TestSuite(TestModelManager.ROOT_TEST_SUITE_NAME, null);
		rootTestSuite.getChildrenList().add(new TestCase("item1", rootTestSuite));
		rootTestSuite.getChildrenList().add(new TestCase("item2", rootTestSuite));
		rootTestSuite.getChildrenList().add(new TestCase("item3", rootTestSuite));
		return rootTestSuite;
	}

	@Override
	protected void visitTestItem(String name) {
		modelManager.enterTestCase(name);
		modelManager.exitTestCase();
	}
	
}

Back to the top