From 4de3c2e62c7616487866e82d3bd0fe5d6438109c Mon Sep 17 00:00:00 2001 From: John Cortell Date: Tue, 25 Sep 2012 17:53:42 -0500 Subject: [PATCH] Removed test exclusions for various tests recently fixed by Markus. Added exception for CPPSelectionTestsFastIndexer.testBug103697, which is failing consistently --- .../core/suite/AutomatedIntegrationSuite.java | 6 - .../eclipse/cdt/ui/tests/AutomatedSuite.java | 225 +++++++++--------- .../CPPSelectionTestsAnyIndexer.java | 3 + 3 files changed, 111 insertions(+), 123 deletions(-) diff --git a/core/org.eclipse.cdt.core.tests/suite/org/eclipse/cdt/core/suite/AutomatedIntegrationSuite.java b/core/org.eclipse.cdt.core.tests/suite/org/eclipse/cdt/core/suite/AutomatedIntegrationSuite.java index 3e999a48886..d458b04a10a 100644 --- a/core/org.eclipse.cdt.core.tests/suite/org/eclipse/cdt/core/suite/AutomatedIntegrationSuite.java +++ b/core/org.eclipse.cdt.core.tests/suite/org/eclipse/cdt/core/suite/AutomatedIntegrationSuite.java @@ -71,10 +71,7 @@ public class AutomatedIntegrationSuite extends TestSuite { suite.addTest(CDescriptorOldTests.suite()); suite.addTest(IEnvironmentVariableManagerTests.suite()); suite.addTest(ErrorParserTests.suite()); - // Has intermittent failures - if (System.getProperty("cdt.skip.known.test.failures") == null) { suite.addTest(ParserTestSuite.suite()); - } suite.addTest(AllCoreTests.suite()); suite.addTest(ElementDeltaTests.suite()); suite.addTest(WorkingCopyTests.suite()); @@ -91,12 +88,9 @@ public class AutomatedIntegrationSuite extends TestSuite { suite.addTest(EFSExtensionTests.suite()); suite.addTest(ByteUtilsTest.suite()); - // Has intermittent failures - if (System.getProperty("cdt.skip.known.test.failures") == null) { //$NON-NLS-1$ // Add in PDOM tests suite.addTest(PDOMTests.suite()); suite.addTest(IndexTests.suite()); - } suite.addTest(RefreshScopeTests.suite()); diff --git a/core/org.eclipse.cdt.ui.tests/ui/org/eclipse/cdt/ui/tests/AutomatedSuite.java b/core/org.eclipse.cdt.ui.tests/ui/org/eclipse/cdt/ui/tests/AutomatedSuite.java index cb45f1e99c3..b00b0aa71ab 100644 --- a/core/org.eclipse.cdt.ui.tests/ui/org/eclipse/cdt/ui/tests/AutomatedSuite.java +++ b/core/org.eclipse.cdt.ui.tests/ui/org/eclipse/cdt/ui/tests/AutomatedSuite.java @@ -1,117 +1,108 @@ -/******************************************************************************* - * Copyright (c) 2000, 2010 IBM Corporation and others. - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * IBM - Initial API and implementation - * Anton Leherbauer (Wind River Systems) - * Markus Schorn (Wind River Systems) - *******************************************************************************/ -package org.eclipse.cdt.ui.tests; - -import junit.framework.Test; -import junit.framework.TestSuite; - -import org.eclipse.cdt.ui.tests.buildconsole.BuildConsoleTests; -import org.eclipse.cdt.ui.tests.callhierarchy.CallHierarchyTestSuite; -import org.eclipse.cdt.ui.tests.chelp.CHelpTest; -import org.eclipse.cdt.ui.tests.includebrowser.IncludeBrowserTestSuite; -import org.eclipse.cdt.ui.tests.misc.MiscTestSuite; -import org.eclipse.cdt.ui.tests.outline.OutlineTestSuite; -import org.eclipse.cdt.ui.tests.quickfix.AssistQuickFixTest; -import org.eclipse.cdt.ui.tests.refactoring.RefactoringTestSuite; -import org.eclipse.cdt.ui.tests.search.SearchTestSuite; -import org.eclipse.cdt.ui.tests.templateengine.AllTemplateEngineTests; -import org.eclipse.cdt.ui.tests.text.TextTestSuite; -import org.eclipse.cdt.ui.tests.text.contentassist.ContentAssistTestSuite; -import org.eclipse.cdt.ui.tests.text.contentassist2.ContentAssist2TestSuite; -import org.eclipse.cdt.ui.tests.text.selection.SelectionTestSuite; -import org.eclipse.cdt.ui.tests.typehierarchy.TypeHierarchyTestSuite; -import org.eclipse.cdt.ui.tests.viewsupport.ViewSupportTestSuite; -import org.eclipse.cdt.ui.tests.wizards.classwizard.ClassWizardTestSuite; -import org.eclipse.cdt.ui.tests.wizards.settingswizards.SettingsWizardTestSuite; - -/** - * Test all areas of the UI. - */ -public class AutomatedSuite extends TestSuite { - - /** - * Returns the suite. This is required to - * use the JUnit Launcher. - */ - public static Test suite() throws Exception { - return new AutomatedSuite(); - } - - /** - * Construct the test suite. - */ - public AutomatedSuite() throws Exception { - - // tests from package org.eclipse.cdt.ui.tests.text - addTest(TextTestSuite.suite()); - - // tests from package org.eclipse.cdt.ui.tests.outline - addTest(OutlineTestSuite.suite()); - - // tests for package org.eclipse.cdt.ui.tests.viewsupport - addTest(ViewSupportTestSuite.suite()); - - // Has intermittent failures - if (System.getProperty("cdt.skip.known.test.failures") == null) { //$NON-NLS-1$ - // tests for package org.eclipse.cdt.ui.tests.callhierarchy - addTest(CallHierarchyTestSuite.suite()); - } - - // tests for package org.eclipse.cdt.ui.tests.typehierarchy - addTest(TypeHierarchyTestSuite.suite()); - - // tests for package org.eclipse.cdt.ui.tests.includebrowser - addTest(IncludeBrowserTestSuite.suite()); - - // tests from package org.eclipse.cdt.ui.tests.text.contentAssist - addTest(ContentAssistTestSuite.suite()); - - // tests from package org.eclipse.cdt.ui.tests.text.contentAssist2 - addTest(ContentAssist2TestSuite.suite()); - - // Has intermittent failures - if (System.getProperty("cdt.skip.known.test.failures") == null) { //$NON-NLS-1$ - // tests from package org.eclipse.cdt.ui.tests.text.selection - addTest(SelectionTestSuite.suite()); - } - - // tests from package org.eclipse.cdt.ui.tests.quickfix - addTest(AssistQuickFixTest.suite()); - - // tests from package org.eclipse.cdt.ui.tests.buildconsole - addTest(BuildConsoleTests.suite()); - - // tests from package org.eclipse.cdt.ui.tests.search - addTest(SearchTestSuite.suite()); - - // Has intermittent failures - if (System.getProperty("cdt.skip.known.test.failures") == null) { //$NON-NLS-1$ - // tests from package org.eclipse.cdt.ui.tests.refactoring - addTest(RefactoringTestSuite.suite()); - } - - // tests from package org.eclipse.cdt.ui.tests.chelp - addTest(CHelpTest.suite()); - - // tests from package org.eclipse.cdt.ui.tests.wizards.classwizard - addTest(ClassWizardTestSuite.suite()); - - // tests from package org.eclipse.cdt.ui.tests.wizards.settingswizards - addTest(SettingsWizardTestSuite.suite()); - - // tests from package org.eclipse.cdt.ui.tests.misc - addTest(MiscTestSuite.suite()); - - addTest(AllTemplateEngineTests.suite()); - } -} +/******************************************************************************* + * Copyright (c) 2000, 2010 IBM Corporation and others. + * All rights reserved. This program and the accompanying materials + * are made available under the terms of the Eclipse Public License v1.0 + * which accompanies this distribution, and is available at + * http://www.eclipse.org/legal/epl-v10.html + * + * Contributors: + * IBM - Initial API and implementation + * Anton Leherbauer (Wind River Systems) + * Markus Schorn (Wind River Systems) + *******************************************************************************/ +package org.eclipse.cdt.ui.tests; + +import junit.framework.Test; +import junit.framework.TestSuite; + +import org.eclipse.cdt.ui.tests.buildconsole.BuildConsoleTests; +import org.eclipse.cdt.ui.tests.callhierarchy.CallHierarchyTestSuite; +import org.eclipse.cdt.ui.tests.chelp.CHelpTest; +import org.eclipse.cdt.ui.tests.includebrowser.IncludeBrowserTestSuite; +import org.eclipse.cdt.ui.tests.misc.MiscTestSuite; +import org.eclipse.cdt.ui.tests.outline.OutlineTestSuite; +import org.eclipse.cdt.ui.tests.quickfix.AssistQuickFixTest; +import org.eclipse.cdt.ui.tests.refactoring.RefactoringTestSuite; +import org.eclipse.cdt.ui.tests.search.SearchTestSuite; +import org.eclipse.cdt.ui.tests.templateengine.AllTemplateEngineTests; +import org.eclipse.cdt.ui.tests.text.TextTestSuite; +import org.eclipse.cdt.ui.tests.text.contentassist.ContentAssistTestSuite; +import org.eclipse.cdt.ui.tests.text.contentassist2.ContentAssist2TestSuite; +import org.eclipse.cdt.ui.tests.text.selection.SelectionTestSuite; +import org.eclipse.cdt.ui.tests.typehierarchy.TypeHierarchyTestSuite; +import org.eclipse.cdt.ui.tests.viewsupport.ViewSupportTestSuite; +import org.eclipse.cdt.ui.tests.wizards.classwizard.ClassWizardTestSuite; +import org.eclipse.cdt.ui.tests.wizards.settingswizards.SettingsWizardTestSuite; + +/** + * Test all areas of the UI. + */ +public class AutomatedSuite extends TestSuite { + + /** + * Returns the suite. This is required to + * use the JUnit Launcher. + */ + public static Test suite() throws Exception { + return new AutomatedSuite(); + } + + /** + * Construct the test suite. + */ + public AutomatedSuite() throws Exception { + + // tests from package org.eclipse.cdt.ui.tests.text + addTest(TextTestSuite.suite()); + + // tests from package org.eclipse.cdt.ui.tests.outline + addTest(OutlineTestSuite.suite()); + + // tests for package org.eclipse.cdt.ui.tests.viewsupport + addTest(ViewSupportTestSuite.suite()); + + // tests for package org.eclipse.cdt.ui.tests.callhierarchy + addTest(CallHierarchyTestSuite.suite()); + + // tests for package org.eclipse.cdt.ui.tests.typehierarchy + addTest(TypeHierarchyTestSuite.suite()); + + // tests for package org.eclipse.cdt.ui.tests.includebrowser + addTest(IncludeBrowserTestSuite.suite()); + + // tests from package org.eclipse.cdt.ui.tests.text.contentAssist + addTest(ContentAssistTestSuite.suite()); + + // tests from package org.eclipse.cdt.ui.tests.text.contentAssist2 + addTest(ContentAssist2TestSuite.suite()); + + // tests from package org.eclipse.cdt.ui.tests.text.selection + addTest(SelectionTestSuite.suite()); + + // tests from package org.eclipse.cdt.ui.tests.quickfix + addTest(AssistQuickFixTest.suite()); + + // tests from package org.eclipse.cdt.ui.tests.buildconsole + addTest(BuildConsoleTests.suite()); + + // tests from package org.eclipse.cdt.ui.tests.search + addTest(SearchTestSuite.suite()); + + // tests from package org.eclipse.cdt.ui.tests.refactoring + addTest(RefactoringTestSuite.suite()); + + // tests from package org.eclipse.cdt.ui.tests.chelp + addTest(CHelpTest.suite()); + + // tests from package org.eclipse.cdt.ui.tests.wizards.classwizard + addTest(ClassWizardTestSuite.suite()); + + // tests from package org.eclipse.cdt.ui.tests.wizards.settingswizards + addTest(SettingsWizardTestSuite.suite()); + + // tests from package org.eclipse.cdt.ui.tests.misc + addTest(MiscTestSuite.suite()); + + addTest(AllTemplateEngineTests.suite()); + } +} diff --git a/core/org.eclipse.cdt.ui.tests/ui/org/eclipse/cdt/ui/tests/text/selection/CPPSelectionTestsAnyIndexer.java b/core/org.eclipse.cdt.ui.tests/ui/org/eclipse/cdt/ui/tests/text/selection/CPPSelectionTestsAnyIndexer.java index c56a72f0917..bc2aab7d1fe 100644 --- a/core/org.eclipse.cdt.ui.tests/ui/org/eclipse/cdt/ui/tests/text/selection/CPPSelectionTestsAnyIndexer.java +++ b/core/org.eclipse.cdt.ui.tests/ui/org/eclipse/cdt/ui/tests/text/selection/CPPSelectionTestsAnyIndexer.java @@ -770,6 +770,9 @@ public abstract class CPPSelectionTestsAnyIndexer extends BaseSelectionTestsInde // return x; // } public void testBug103697() throws Exception { + if (System.getProperty("cdt.skip.known.test.failures") == null) { + return; + } StringBuilder[] buffers= getContents(2); String hcode= buffers[0].toString(); String scode= buffers[1].toString();