mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-06-09 02:36:01 +02:00
parent
b3003b7fa7
commit
542e8b474e
5 changed files with 22 additions and 18 deletions
|
@ -16,6 +16,8 @@ package org.eclipse.cdt.make.builder.tests;
|
|||
import org.eclipse.cdt.core.CCorePlugin;
|
||||
import org.eclipse.cdt.core.settings.model.ICConfigurationDescription;
|
||||
import org.eclipse.cdt.core.settings.model.ICProjectDescription;
|
||||
import org.eclipse.cdt.core.testplugin.util.BaseTestCase;
|
||||
import org.eclipse.cdt.core.testplugin.util.BaseTestCase5;
|
||||
import org.eclipse.cdt.make.core.MakeCorePlugin;
|
||||
import org.eclipse.core.resources.IProject;
|
||||
import org.eclipse.core.resources.IProjectDescription;
|
||||
|
@ -28,11 +30,10 @@ import org.eclipse.core.runtime.IProgressMonitor;
|
|||
import org.eclipse.core.runtime.NullProgressMonitor;
|
||||
|
||||
import junit.framework.Test;
|
||||
import junit.framework.TestCase;
|
||||
import junit.framework.TestSuite;
|
||||
|
||||
@SuppressWarnings("nls")
|
||||
public class CDataProviderTests extends TestCase {
|
||||
public class CDataProviderTests extends BaseTestCase {
|
||||
/**
|
||||
* @param name
|
||||
*/
|
||||
|
@ -41,18 +42,14 @@ public class CDataProviderTests extends TestCase {
|
|||
}
|
||||
|
||||
public static Test suite() {
|
||||
TestSuite suite = new TestSuite(CDataProviderTests.class);
|
||||
return new TestSuite(CDataProviderTests.class);
|
||||
}
|
||||
|
||||
// // Add the relevant tests to the suite
|
||||
// suite.addTest(new StandardBuildTests("testProjectCreation"));
|
||||
// suite.addTest(new StandardBuildTests("testProjectSettings"));
|
||||
// suite.addTest(new StandardBuildTests("testProjectConversion"));
|
||||
// suite.addTest(new StandardBuildTests("testProjectCleanup"));
|
||||
//
|
||||
// suite.addTestSuite(ScannerConfigConsoleParserTests.class);
|
||||
// suite.addTestSuite(ScannerConfigDiscoveryTests.class);
|
||||
@Override
|
||||
protected void tearDown() throws Exception {
|
||||
BaseTestCase5.removeLeftOverProjects();
|
||||
|
||||
return suite;
|
||||
super.tearDown();
|
||||
}
|
||||
|
||||
public void testCData() throws Exception {
|
||||
|
|
|
@ -66,7 +66,6 @@ public class GCCPerFileBOPConsoleParserTests extends BaseBOPConsoleParserTests {
|
|||
|
||||
@Override
|
||||
protected void tearDown() throws Exception {
|
||||
super.tearDown();
|
||||
if (fOutputParser != null) {
|
||||
fOutputParser.shutdown();
|
||||
}
|
||||
|
@ -74,6 +73,7 @@ public class GCCPerFileBOPConsoleParserTests extends BaseBOPConsoleParserTests {
|
|||
if (fCProject != null) {
|
||||
CProjectHelper.delete(fCProject);
|
||||
}
|
||||
super.tearDown();
|
||||
}
|
||||
|
||||
public void testParsingIfStatement_bug197930() throws Exception {
|
||||
|
|
|
@ -46,8 +46,8 @@ public class GCCScannerInfoConsoleParserTests extends BaseBOPConsoleParserTests
|
|||
|
||||
@Override
|
||||
protected void tearDown() throws Exception {
|
||||
super.tearDown();
|
||||
fOutputParser.shutdown();
|
||||
super.tearDown();
|
||||
}
|
||||
|
||||
/*
|
||||
|
|
|
@ -21,6 +21,7 @@ import org.eclipse.cdt.core.CCorePlugin;
|
|||
import org.eclipse.cdt.core.parser.IScannerInfo;
|
||||
import org.eclipse.cdt.core.testplugin.ResourceHelper;
|
||||
import org.eclipse.cdt.core.testplugin.util.BaseTestCase;
|
||||
import org.eclipse.cdt.core.testplugin.util.BaseTestCase5;
|
||||
import org.eclipse.cdt.make.core.MakeCorePlugin;
|
||||
import org.eclipse.cdt.make.core.MakeProjectNature;
|
||||
import org.eclipse.cdt.make.core.scannerconfig.ScannerConfigNature;
|
||||
|
@ -53,9 +54,11 @@ public class ScannerConfigDiscoveryTests extends BaseTestCase {
|
|||
|
||||
@Override
|
||||
protected void setUp() throws Exception {
|
||||
super.setUp();
|
||||
fMonitor = new NullProgressMonitor();
|
||||
|
||||
fCProject = StandardBuildTestHelper.createProject("SCD", (IPath) null, MakeCorePlugin.MAKE_PROJECT_ID);
|
||||
fCProject = StandardBuildTestHelper.createProject("SCD" + getName(), (IPath) null,
|
||||
MakeCorePlugin.MAKE_PROJECT_ID);
|
||||
fCFile = fCProject.getProject().getFile("main.c");
|
||||
if (!fCFile.exists()) {
|
||||
fCFile.create(new ByteArrayInputStream(" \n".getBytes()), false, fMonitor);
|
||||
|
@ -65,7 +68,8 @@ public class ScannerConfigDiscoveryTests extends BaseTestCase {
|
|||
@Override
|
||||
protected void tearDown() throws Exception {
|
||||
ResourceHelper.cleanUp(getName());
|
||||
StandardBuildTestHelper.removeProject("SCDC");
|
||||
fCProject.getProject().delete(true, true, null);
|
||||
super.tearDown();
|
||||
}
|
||||
|
||||
public void testGetCCompilerBuiltins() throws CoreException {
|
||||
|
|
|
@ -38,7 +38,9 @@ public class ScannerConfigProfileTests extends BaseTestCase {
|
|||
|
||||
@Override
|
||||
protected void setUp() throws Exception {
|
||||
fCProject = StandardBuildTestHelper.createProject("SCD", (IPath) null, MakeCorePlugin.MAKE_PROJECT_ID);
|
||||
super.setUp();
|
||||
fCProject = StandardBuildTestHelper.createProject("SCD" + getName(), (IPath) null,
|
||||
MakeCorePlugin.MAKE_PROJECT_ID);
|
||||
fCFile = fCProject.getProject().getFile("main.c");
|
||||
if (!fCFile.exists()) {
|
||||
fCFile.create(new ByteArrayInputStream(" \n".getBytes()), false, new NullProgressMonitor());
|
||||
|
@ -48,7 +50,8 @@ public class ScannerConfigProfileTests extends BaseTestCase {
|
|||
@Override
|
||||
protected void tearDown() throws Exception {
|
||||
ResourceHelper.cleanUp(getName());
|
||||
StandardBuildTestHelper.removeProject("SCDC");
|
||||
fCProject.delete(true, true, null);
|
||||
super.tearDown();
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
Loading…
Add table
Reference in a new issue