From: simonbrandhof Date: Mon, 7 Feb 2011 13:22:42 +0000 (+0100) Subject: Move integration & volume tests X-Git-Tag: 2.6~37 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=ebee9e8be46ed85227fb4ded4afb34f12d6d465f;p=sonarqube.git Move integration & volume tests --- diff --git a/tests/integration/checkstyle-extensions/checkstyle-extensions.xml b/tests/integration/checkstyle-extensions/checkstyle-extensions.xml deleted file mode 100644 index 3419181c828..00000000000 --- a/tests/integration/checkstyle-extensions/checkstyle-extensions.xml +++ /dev/null @@ -1,16 +0,0 @@ - - - org.sonar.it.checkstyle.MethodsCountCheck - Methods Count Check - Checker/TreeWalker/org.sonar.it.checkstyle.MethodsCountCheck - - Count methods. - - minMethodsCount - Le nombre minimum de méthodes. 10 par défaut. - - - 10 - - - \ No newline at end of file diff --git a/tests/integration/checkstyle-extensions/pom.xml b/tests/integration/checkstyle-extensions/pom.xml deleted file mode 100644 index 6b5d4ed9342..00000000000 --- a/tests/integration/checkstyle-extensions/pom.xml +++ /dev/null @@ -1,32 +0,0 @@ - - - 4.0.0 - - org.codehaus.sonar.tests - integration - 2.6-SNAPSHOT - - checkstyle-extensions - Sonar :: Integration Tests :: Checkstyle Extensions - - - - checkstyle - checkstyle - 5.1 - - - - commons-logging - commons-logging - 1.1 - test - - - junit - junit - 4.7 - test - - - \ No newline at end of file diff --git a/tests/integration/checkstyle-extensions/src/main/java/org/sonar/it/checkstyle/MethodsCountCheck.java b/tests/integration/checkstyle-extensions/src/main/java/org/sonar/it/checkstyle/MethodsCountCheck.java deleted file mode 100644 index b82a6a98d17..00000000000 --- a/tests/integration/checkstyle-extensions/src/main/java/org/sonar/it/checkstyle/MethodsCountCheck.java +++ /dev/null @@ -1,43 +0,0 @@ -package org.sonar.it.checkstyle; - -import com.puppycrawl.tools.checkstyle.api.Check; -import com.puppycrawl.tools.checkstyle.api.DetailAST; -import com.puppycrawl.tools.checkstyle.api.TokenTypes; - -public class MethodsCountCheck extends Check { - - private int minMethodsCount = 1; - - private int methodsCount = 0; - private DetailAST classAST = null; - - public void setMinMethodsCount(int minMethodsCount) { - this.minMethodsCount = minMethodsCount; - } - - public int[] getDefaultTokens() { - return new int[]{TokenTypes.CLASS_DEF, TokenTypes.METHOD_DEF}; - } - - public void beginTree(DetailAST rootAST) { - methodsCount = 0; - classAST = null; - } - - public void visitToken(DetailAST ast) { - //ensure this is an unit test. - if ( ast.getType() == TokenTypes.CLASS_DEF ) { - classAST = ast; - - } else if ( ast.getType() == TokenTypes.METHOD_DEF ) { - methodsCount++; - } - } - - public void finishTree(DetailAST rootAST) { - super.finishTree(rootAST); - if (classAST != null && methodsCount < minMethodsCount) { - log(classAST.getLineNo(), classAST.getColumnNo(), "Too few methods (" + methodsCount + ") in class" ); - } - } -} diff --git a/tests/integration/pmd-extensions/pmd-extensions.xml b/tests/integration/pmd-extensions/pmd-extensions.xml deleted file mode 100644 index 720108e5d2b..00000000000 --- a/tests/integration/pmd-extensions/pmd-extensions.xml +++ /dev/null @@ -1,38 +0,0 @@ - - - MaximumMethodsCountCheck - Maximum Methods Count Check - rulesets/extensions.xml/MaximumMethodsCountCheck - - Maximum number of methods authorised - - maxAuthorisedMethodsCount - Maximum number of methods authorised. Default is 2. - - - - AvoidIfWithoutBrace - Avoid if without using brace - rulesets/extensions.xml/AvoidIfWithoutBrace - - - - - PreventUseOfEmptyClass - MAJOR - - - - - - xpath - - //VariableDeclarator[../Type/ReferenceType/ClassOrInterfaceType[@Image='EmptyClass']] - - - message - - Prevent use of EmptyClass class - - - \ No newline at end of file diff --git a/tests/integration/pmd-extensions/pom.xml b/tests/integration/pmd-extensions/pom.xml deleted file mode 100644 index 36da9e00a54..00000000000 --- a/tests/integration/pmd-extensions/pom.xml +++ /dev/null @@ -1,34 +0,0 @@ - - - 4.0.0 - - org.codehaus.sonar.tests - integration - 2.6-SNAPSHOT - - - pmd-extensions - Sonar :: Integration Tests :: PMD Extensions - Samples of PMD extensions - - - - pmd - pmd - 4.1 - - - - - - - org.apache.maven.plugins - maven-compiler-plugin - - 1.5 - 1.5 - - - - - \ No newline at end of file diff --git a/tests/integration/pmd-extensions/src/main/java/org/sonar/it/pmd/MaximumMethodsCountCheck.java b/tests/integration/pmd-extensions/src/main/java/org/sonar/it/pmd/MaximumMethodsCountCheck.java deleted file mode 100644 index 2d8abb00f49..00000000000 --- a/tests/integration/pmd-extensions/src/main/java/org/sonar/it/pmd/MaximumMethodsCountCheck.java +++ /dev/null @@ -1,25 +0,0 @@ -package org.sonar.it.pmd; - -import java.util.ArrayList; -import java.util.List; -import net.sourceforge.pmd.AbstractRule; -import net.sourceforge.pmd.ast.ASTClassOrInterfaceBody; -import net.sourceforge.pmd.ast.ASTMethodDeclaration; -import net.sourceforge.pmd.properties.IntegerProperty; - -public class MaximumMethodsCountCheck extends AbstractRule { - - private static final IntegerProperty propertyDescriptor = new IntegerProperty( - "maxAuthorisedMethodsCount", "Maximum number of methods authorised", 2, 1.0f); - - public Object visit(ASTClassOrInterfaceBody node, Object data) { - List methods = new ArrayList(); - methods = (List)node.findChildrenOfType(ASTMethodDeclaration.class); - - if (methods.size() > getIntProperty(propertyDescriptor)) { - addViolation(data, node); - } - return super.visit(node,data); - } - -} diff --git a/tests/integration/pmd-extensions/src/main/resources/rulesets/extensions.xml b/tests/integration/pmd-extensions/src/main/resources/rulesets/extensions.xml deleted file mode 100644 index 6997ed4406b..00000000000 --- a/tests/integration/pmd-extensions/src/main/resources/rulesets/extensions.xml +++ /dev/null @@ -1,51 +0,0 @@ - - - - - Avoid too many methods - - 3 - - - - - - - - - - Avoid if without using brace - - - - - - - - - - - - - \ No newline at end of file diff --git a/tests/integration/pom.xml b/tests/integration/pom.xml deleted file mode 100644 index 4b48d4b1682..00000000000 --- a/tests/integration/pom.xml +++ /dev/null @@ -1,32 +0,0 @@ - - - 4.0.0 - - org.codehaus.sonar - sonar - 2.6-SNAPSHOT - ../.. - - org.codehaus.sonar.tests - integration - pom - Sonar :: Integration Tests - - - sonar-it-reference-plugin - checkstyle-extensions - pmd-extensions - tests - - - - - maven-deploy-plugin - - true - - - - - - \ No newline at end of file diff --git a/tests/integration/sonar-it-reference-plugin/pom.xml b/tests/integration/sonar-it-reference-plugin/pom.xml deleted file mode 100644 index 27d50c1734b..00000000000 --- a/tests/integration/sonar-it-reference-plugin/pom.xml +++ /dev/null @@ -1,139 +0,0 @@ - - - 4.0.0 - - org.codehaus.sonar.tests - integration - 2.6-SNAPSHOT - - - sonar-it-reference-plugin - Sonar :: Integration Tests :: Reference Plugin - sonar-plugin - My Sonar plugin - - - - LGPL 3 - - - - - SonarSource - http://www.sonarsource.org - - - - - org.codehaus.sonar - sonar-plugin-api - ${project.version} - - - org.codehaus.sonar - sonar-gwt-api - ${project.version} - provided - - - - - - commons-i18n - commons-i18n - 0.5 - - - - - org.apache.maven - maven-project - 2.0.7 - provided - - - org.apache.maven - maven-plugin-api - 2.0.7 - provided - - - org.apache.maven - maven-core - 2.0.7 - provided - - - - - com.google.gwt - gwt-user - 2.0.3 - provided - - - com.google.gwt - gwt-incubator - 2.0.1 - provided - - - - - org.codehaus.sonar - sonar-testing-harness - ${project.version} - test - - - - - - - org.codehaus.sonar - sonar-packaging-maven-plugin - 1.0 - true - - itests.ITestsPlugin - - - - - - org.codehaus.mojo - gwt-maven-plugin - 1.2 - - - - - itests.resourcetab.GwtSampleResourceTab - itests.page.GwtModule - - ${project.build.directory}/classes - - - -Xmx512m -Dgwt.jjs.permutationWorkerFactory=com.google.gwt.dev.ThreadedPermutationWorkerFactory - - - compile - - - - - - - - org.apache.maven.plugins - maven-compiler-plugin - - 1.5 - 1.5 - UTF-8 - - - - - - diff --git a/tests/integration/sonar-it-reference-plugin/src/main/java/itests/ExcludedResourceFilter.java b/tests/integration/sonar-it-reference-plugin/src/main/java/itests/ExcludedResourceFilter.java deleted file mode 100644 index 4c045cdb3b9..00000000000 --- a/tests/integration/sonar-it-reference-plugin/src/main/java/itests/ExcludedResourceFilter.java +++ /dev/null @@ -1,13 +0,0 @@ -package itests; - -import org.apache.commons.lang.StringUtils; -import org.sonar.api.batch.ResourceFilter; -import org.sonar.api.resources.Resource; -import org.sonar.api.resources.Scopes; - -public final class ExcludedResourceFilter implements ResourceFilter { - - public boolean isIgnored(Resource resource) { - return Scopes.isFile(resource) && StringUtils.contains(resource.getName(), "ExcludedByFilter"); - } -} diff --git a/tests/integration/sonar-it-reference-plugin/src/main/java/itests/ITestsPlugin.java b/tests/integration/sonar-it-reference-plugin/src/main/java/itests/ITestsPlugin.java deleted file mode 100644 index 3d727a9ce01..00000000000 --- a/tests/integration/sonar-it-reference-plugin/src/main/java/itests/ITestsPlugin.java +++ /dev/null @@ -1,71 +0,0 @@ -/* - * Sonar, open source software quality management tool. - * Copyright (C) 2008-2011 SonarSource - * mailto:contact AT sonarsource DOT com - * - * Sonar is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 3 of the License, or (at your option) any later version. - * - * Sonar is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with Sonar; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02 - */ -package itests; - -import itests.footer.SampleFooter; -import itests.languages.LanguageWithoutRulesEngine; -import itests.page.GwtSamplePage; -import itests.page.RubyApiTestsPage; -import itests.resourcetab.SampleResourceTab; -import itests.ws.RubyWebService; -import org.sonar.api.Plugin; - -import java.util.ArrayList; -import java.util.List; - -public class ITestsPlugin implements Plugin { - - public String getKey() { - return "it"; - } - - public String getName() { - return "Integration tests"; - } - - public String getDescription() { - return "Integration tests"; - } - - public List getExtensions() { - List extensions = new ArrayList(); - - extensions.add(SampleSensor.class); - extensions.add(LanguageWithoutRulesEngine.class); - extensions.add(ServerSideExtensionUsingExternalDependency.class); - extensions.add(ExcludedResourceFilter.class); - - // web - extensions.add(SampleResourceTab.class); - extensions.add(SampleFooter.class); - extensions.add(GwtSamplePage.class); - extensions.add(RubyApiTestsPage.class); - - // web service - extensions.add(RubyWebService.class); - - return extensions; - } - - @Override - public String toString() { - return getKey(); - } -} diff --git a/tests/integration/sonar-it-reference-plugin/src/main/java/itests/SampleSensor.java b/tests/integration/sonar-it-reference-plugin/src/main/java/itests/SampleSensor.java deleted file mode 100644 index 0ec5c71953b..00000000000 --- a/tests/integration/sonar-it-reference-plugin/src/main/java/itests/SampleSensor.java +++ /dev/null @@ -1,54 +0,0 @@ -/* - * Sonar, open source software quality management tool. - * Copyright (C) 2008-2011 SonarSource - * mailto:contact AT sonarsource DOT com - * - * Sonar is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 3 of the License, or (at your option) any later version. - * - * Sonar is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with Sonar; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02 - */ -package itests; - -import org.apache.commons.i18n.bundles.MessageBundle; -import org.sonar.api.batch.Sensor; -import org.sonar.api.batch.SensorContext; -import org.sonar.api.resources.Project; - -public class SampleSensor implements Sensor { - public boolean shouldExecuteOnProject(Project project) { - return true; - } - - public void analyse(Project project, SensorContext context) { - System.out.println(" Check usage of plugin dependencies (new feature since sonar 2.2)"); - - - System.out.print("Loading external dependency from " + getClass().getName() + ": "); - MessageBundle bundle = new MessageBundle("12345"); - System.out.println("OK"); - - System.out.print(" Plugin isolation (can not access other plugin classes): "); - try { - Class.forName("org.sonar.plugins.checkstyle.CheckstyleSensor"); - System.out.println("KO"); - - } catch (ClassNotFoundException e) { - System.out.println("OK"); - } - } - - @Override - public String toString() { - return getClass().getSimpleName(); - } -} diff --git a/tests/integration/sonar-it-reference-plugin/src/main/java/itests/ServerSideExtensionUsingExternalDependency.java b/tests/integration/sonar-it-reference-plugin/src/main/java/itests/ServerSideExtensionUsingExternalDependency.java deleted file mode 100644 index 53d241c0651..00000000000 --- a/tests/integration/sonar-it-reference-plugin/src/main/java/itests/ServerSideExtensionUsingExternalDependency.java +++ /dev/null @@ -1,32 +0,0 @@ -/* - * Sonar, open source software quality management tool. - * Copyright (C) 2008-2011 SonarSource - * mailto:contact AT sonarsource DOT com - * - * Sonar is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 3 of the License, or (at your option) any later version. - * - * Sonar is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with Sonar; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02 - */ -package itests; - -import org.apache.commons.i18n.bundles.MessageBundle; -import org.sonar.api.ServerExtension; - -public class ServerSideExtensionUsingExternalDependency implements ServerExtension { - - public ServerSideExtensionUsingExternalDependency() { - System.out.print("Loading external dependency from " + getClass().getName() + ": "); - MessageBundle bundle = new MessageBundle("12345"); - System.out.println("OK"); - } -} diff --git a/tests/integration/sonar-it-reference-plugin/src/main/java/itests/footer/SampleFooter.java b/tests/integration/sonar-it-reference-plugin/src/main/java/itests/footer/SampleFooter.java deleted file mode 100644 index 32895e87e11..00000000000 --- a/tests/integration/sonar-it-reference-plugin/src/main/java/itests/footer/SampleFooter.java +++ /dev/null @@ -1,28 +0,0 @@ -/* - * Sonar, open source software quality management tool. - * Copyright (C) 2008-2011 SonarSource - * mailto:contact AT sonarsource DOT com - * - * Sonar is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 3 of the License, or (at your option) any later version. - * - * Sonar is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with Sonar; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02 - */ -package itests.footer; - -import org.sonar.api.web.Footer; - -public class SampleFooter implements Footer { - public String getHtml() { - return "
Sample footer
"; - } -} diff --git a/tests/integration/sonar-it-reference-plugin/src/main/java/itests/languages/LanguageWithoutRulesEngine.java b/tests/integration/sonar-it-reference-plugin/src/main/java/itests/languages/LanguageWithoutRulesEngine.java deleted file mode 100644 index b4951db60ba..00000000000 --- a/tests/integration/sonar-it-reference-plugin/src/main/java/itests/languages/LanguageWithoutRulesEngine.java +++ /dev/null @@ -1,43 +0,0 @@ -/* - * Sonar, open source software quality management tool. - * Copyright (C) 2008-2011 SonarSource - * mailto:contact AT sonarsource DOT com - * - * Sonar is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 3 of the License, or (at your option) any later version. - * - * Sonar is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with Sonar; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02 - */ -package itests.languages; - -import org.sonar.api.database.model.ResourceModel; -import org.sonar.api.resources.AbstractLanguage; - -public class LanguageWithoutRulesEngine extends AbstractLanguage { - private static final String[] SUFFIXES = new String[]{"unknown"}; - - public LanguageWithoutRulesEngine() { - super("lwre", "Language without rules engine"); - } - - public ResourceModel getParent(ResourceModel resource) { - return null; - } - - public boolean matchExclusionPattern(ResourceModel resource, String wildcardPattern) { - return false; - } - - public String[] getFileSuffixes() { - return SUFFIXES; - } -} diff --git a/tests/integration/sonar-it-reference-plugin/src/main/java/itests/page/GwtSamplePage.java b/tests/integration/sonar-it-reference-plugin/src/main/java/itests/page/GwtSamplePage.java deleted file mode 100644 index 9b208ef9682..00000000000 --- a/tests/integration/sonar-it-reference-plugin/src/main/java/itests/page/GwtSamplePage.java +++ /dev/null @@ -1,36 +0,0 @@ -/* - * Sonar, open source software quality management tool. - * Copyright (C) 2008-2011 SonarSource - * mailto:contact AT sonarsource DOT com - * - * Sonar is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 3 of the License, or (at your option) any later version. - * - * Sonar is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with Sonar; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02 - */ -package itests.page; - -import itests.page.client.GwtModule; -import org.sonar.api.web.GwtPage; -import org.sonar.api.web.NavigationSection; - -@NavigationSection({NavigationSection.HOME}) -public class GwtSamplePage extends GwtPage { - - public String getGwtId() { - return GwtModule.GWT_ID; - } - - public String getTitle() { - return "GWT sample"; - } -} diff --git a/tests/integration/sonar-it-reference-plugin/src/main/java/itests/page/RubyApiTestsPage.java b/tests/integration/sonar-it-reference-plugin/src/main/java/itests/page/RubyApiTestsPage.java deleted file mode 100644 index f39c949411a..00000000000 --- a/tests/integration/sonar-it-reference-plugin/src/main/java/itests/page/RubyApiTestsPage.java +++ /dev/null @@ -1,43 +0,0 @@ -/* - * Sonar, open source software quality management tool. - * Copyright (C) 2008-2011 SonarSource - * mailto:contact AT sonarsource DOT com - * - * Sonar is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 3 of the License, or (at your option) any later version. - * - * Sonar is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with Sonar; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02 - */ -package itests.page; - -import org.sonar.api.web.AbstractRubyTemplate; -import org.sonar.api.web.NavigationSection; -import org.sonar.api.web.RubyRailsPage; -import org.sonar.api.web.UserRole; - -@NavigationSection({NavigationSection.HOME}) -@UserRole(UserRole.USER) -public class RubyApiTestsPage extends AbstractRubyTemplate implements RubyRailsPage { - - public String getTitle() { - return "Ruby API tests"; - } - - @Override - public String getTemplatePath() { - return "/itests/page/ruby_api_tests_page.html.erb"; - } - - public String getId() { - return this.getClass().getName(); - } -} diff --git a/tests/integration/sonar-it-reference-plugin/src/main/java/itests/page/client/GwtModule.java b/tests/integration/sonar-it-reference-plugin/src/main/java/itests/page/client/GwtModule.java deleted file mode 100644 index 19aa9c2e820..00000000000 --- a/tests/integration/sonar-it-reference-plugin/src/main/java/itests/page/client/GwtModule.java +++ /dev/null @@ -1,34 +0,0 @@ -/* - * Sonar, open source software quality management tool. - * Copyright (C) 2008-2011 SonarSource - * mailto:contact AT sonarsource DOT com - * - * Sonar is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 3 of the License, or (at your option) any later version. - * - * Sonar is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with Sonar; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02 - */ -package itests.page.client; - -import com.google.gwt.user.client.ui.Label; -import com.google.gwt.user.client.ui.Widget; -import org.sonar.gwt.ui.Page; - -public class GwtModule extends Page { - - public static final String GWT_ID = "itests.page.GwtModule"; - - @Override - protected Widget doOnModuleLoad() { - return new Label("this is a GWT sample"); - } -} diff --git a/tests/integration/sonar-it-reference-plugin/src/main/java/itests/resourcetab/SampleResourceTab.java b/tests/integration/sonar-it-reference-plugin/src/main/java/itests/resourcetab/SampleResourceTab.java deleted file mode 100644 index 5e875599f6a..00000000000 --- a/tests/integration/sonar-it-reference-plugin/src/main/java/itests/resourcetab/SampleResourceTab.java +++ /dev/null @@ -1,37 +0,0 @@ -/* - * Sonar, open source software quality management tool. - * Copyright (C) 2008-2011 SonarSource - * mailto:contact AT sonarsource DOT com - * - * Sonar is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 3 of the License, or (at your option) any later version. - * - * Sonar is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with Sonar; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02 - */ -package itests.resourcetab; - -import itests.resourcetab.client.GwtSampleResourceTab; -import org.sonar.api.web.GwtPage; -import org.sonar.api.web.NavigationSection; -import org.sonar.api.web.UserRole; - -@UserRole(UserRole.USER) -@NavigationSection(NavigationSection.RESOURCE_TAB) -public class SampleResourceTab extends GwtPage { - public String getTitle() { - return "Tab Sample"; - } - - public String getGwtId() { - return GwtSampleResourceTab.GWT_ID; - } -} \ No newline at end of file diff --git a/tests/integration/sonar-it-reference-plugin/src/main/java/itests/resourcetab/client/GwtSampleResourceTab.java b/tests/integration/sonar-it-reference-plugin/src/main/java/itests/resourcetab/client/GwtSampleResourceTab.java deleted file mode 100644 index efeb007d801..00000000000 --- a/tests/integration/sonar-it-reference-plugin/src/main/java/itests/resourcetab/client/GwtSampleResourceTab.java +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Sonar, open source software quality management tool. - * Copyright (C) 2008-2011 SonarSource - * mailto:contact AT sonarsource DOT com - * - * Sonar is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 3 of the License, or (at your option) any later version. - * - * Sonar is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with Sonar; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02 - */ -package itests.resourcetab.client; - -import com.google.gwt.user.client.ui.HTML; -import com.google.gwt.user.client.ui.Widget; -import org.sonar.gwt.ui.Page; -import org.sonar.wsclient.services.Resource; - -public class GwtSampleResourceTab extends Page { - public static final String GWT_ID = "itests.resourcetab.GwtSampleResourceTab"; - - @Override - protected Widget doOnResourceLoad(Resource resource) { - return new HTML("This is a sample of viewer"); - } - -} \ No newline at end of file diff --git a/tests/integration/sonar-it-reference-plugin/src/main/java/itests/ws/RubyWebService.java b/tests/integration/sonar-it-reference-plugin/src/main/java/itests/ws/RubyWebService.java deleted file mode 100644 index 9cd876435b0..00000000000 --- a/tests/integration/sonar-it-reference-plugin/src/main/java/itests/ws/RubyWebService.java +++ /dev/null @@ -1,36 +0,0 @@ -/* - * Sonar, open source software quality management tool. - * Copyright (C) 2008-2011 SonarSource - * mailto:contact AT sonarsource DOT com - * - * Sonar is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 3 of the License, or (at your option) any later version. - * - * Sonar is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with Sonar; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02 - */ -package itests.ws; - -import org.sonar.api.web.AbstractRubyTemplate; -import org.sonar.api.web.RubyRailsWebservice; - -public class RubyWebService extends AbstractRubyTemplate implements RubyRailsWebservice { - - @Override - public String getTemplatePath() { - return "/itests/ws/ruby_ws_controller.rb"; - } - - public String getId() { - return "RubyWebService"; - } - -} diff --git a/tests/integration/sonar-it-reference-plugin/src/main/resources/itests/page/GwtModule.gwt.xml b/tests/integration/sonar-it-reference-plugin/src/main/resources/itests/page/GwtModule.gwt.xml deleted file mode 100644 index 9046f23e85e..00000000000 --- a/tests/integration/sonar-it-reference-plugin/src/main/resources/itests/page/GwtModule.gwt.xml +++ /dev/null @@ -1,10 +0,0 @@ - - - - - - - - - - diff --git a/tests/integration/sonar-it-reference-plugin/src/main/resources/itests/page/ruby_api_tests_page.html.erb b/tests/integration/sonar-it-reference-plugin/src/main/resources/itests/page/ruby_api_tests_page.html.erb deleted file mode 100644 index 8326ef10ebf..00000000000 --- a/tests/integration/sonar-it-reference-plugin/src/main/resources/itests/page/ruby_api_tests_page.html.erb +++ /dev/null @@ -1,34 +0,0 @@ -

Ruby API tests

- - -<% success=true %> - -<% if logged_in? %> -

User Properties

-
    - <% - current_user.set_property({:prop_key => 'foo', :text_value => 'bar'}) - test=current_user.property_value('foo')=='bar' - success&=test - %> -
  • create: <%= 'OK' if test -%>
  • - - <% - current_user.delete_property('foo') - test=current_user.property('foo').nil? - success&=test - %> -
  • delete: <%= 'OK' if test -%>
  • - - <% - current_user.set_property({:prop_key => 'foo', :text_value => 'bar'}) - current_user.set_property({:prop_key => 'foo', :text_value => 'newbar'}) - test=current_user.property_value('foo')=='newbar' - success&=test - %> -
  • update: <%= 'OK' if test -%>
  • -
-<% end %> - -
-

Result: <%= success ? 'OK' : 'FAIL' %>

\ No newline at end of file diff --git a/tests/integration/sonar-it-reference-plugin/src/main/resources/itests/resourcetab/GwtSampleResourceTab.gwt.xml b/tests/integration/sonar-it-reference-plugin/src/main/resources/itests/resourcetab/GwtSampleResourceTab.gwt.xml deleted file mode 100644 index 5c6f660ab10..00000000000 --- a/tests/integration/sonar-it-reference-plugin/src/main/resources/itests/resourcetab/GwtSampleResourceTab.gwt.xml +++ /dev/null @@ -1,10 +0,0 @@ - - - - - - - - - - diff --git a/tests/integration/sonar-it-reference-plugin/src/main/resources/itests/resourcetab/public/sample.html b/tests/integration/sonar-it-reference-plugin/src/main/resources/itests/resourcetab/public/sample.html deleted file mode 100644 index 6aecf69f757..00000000000 --- a/tests/integration/sonar-it-reference-plugin/src/main/resources/itests/resourcetab/public/sample.html +++ /dev/null @@ -1,37 +0,0 @@ - - - - - - Metrics - - - - - - - - - - - - - - - -load source - - -
- - - \ No newline at end of file diff --git a/tests/integration/sonar-it-reference-plugin/src/main/resources/itests/ws/ruby_ws_controller.rb b/tests/integration/sonar-it-reference-plugin/src/main/resources/itests/ws/ruby_ws_controller.rb deleted file mode 100644 index 40ad00c5424..00000000000 --- a/tests/integration/sonar-it-reference-plugin/src/main/resources/itests/ws/ruby_ws_controller.rb +++ /dev/null @@ -1,32 +0,0 @@ -# -# Sonar, open source software quality management tool. -# Copyright (C) 2008-2011 SonarSource -# mailto:contact AT sonarsource DOT com -# -# Sonar is free software; you can redistribute it and/or -# modify it under the terms of the GNU Lesser General Public -# License as published by the Free Software Foundation; either -# version 3 of the License, or (at your option) any later version. -# -# Sonar is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -# Lesser General Public License for more details. -# -# You should have received a copy of the GNU Lesser General Public -# License along with Sonar; if not, write to the Free Software -# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02 -# -class Api::RubyWebServiceController < Api::RestController - - def custom_method - render :text => "Custom method output" - end - - private - - def rest_call - render :text => "Rest method output" - end - -end \ No newline at end of file diff --git a/tests/integration/sonar-it-reference-plugin/src/main/resources/static/file.html b/tests/integration/sonar-it-reference-plugin/src/main/resources/static/file.html deleted file mode 100644 index 5ae990c1af3..00000000000 --- a/tests/integration/sonar-it-reference-plugin/src/main/resources/static/file.html +++ /dev/null @@ -1,5 +0,0 @@ - - -Text from static resource - - diff --git a/tests/integration/tests/build.xml b/tests/integration/tests/build.xml deleted file mode 100644 index 75bad16d20f..00000000000 --- a/tests/integration/tests/build.xml +++ /dev/null @@ -1,194 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - Executing ${maven.home}/bin/mvn @{args} - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/tests/integration/tests/custom-projects/.gitignore b/tests/integration/tests/custom-projects/.gitignore deleted file mode 100644 index d3a4bc7c1de..00000000000 --- a/tests/integration/tests/custom-projects/.gitignore +++ /dev/null @@ -1,10 +0,0 @@ -ant-dynamic-clover/.clover/ -ant-dynamic-clover/build/ -ant-dynamic-cobertura/build/ -ant-dynamic-cobertura/cobertura.ser -ant-dynamic-cobertura/reports/ -ant-dynamic-junit/build/ -ant-dynamic-junit/reports/ -ant-static/build/ -deprecated-sonar-light/build/ -struts-1.3.9/ diff --git a/tests/integration/tests/custom-projects/ant-dynamic-clover/build.xml b/tests/integration/tests/custom-projects/ant-dynamic-clover/build.xml deleted file mode 100644 index 6b6be48f764..00000000000 --- a/tests/integration/tests/custom-projects/ant-dynamic-clover/build.xml +++ /dev/null @@ -1,83 +0,0 @@ - - - money build file - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/tests/integration/tests/custom-projects/ant-dynamic-clover/lib/clover/clover.jar b/tests/integration/tests/custom-projects/ant-dynamic-clover/lib/clover/clover.jar deleted file mode 100644 index a4ea600ee64..00000000000 Binary files a/tests/integration/tests/custom-projects/ant-dynamic-clover/lib/clover/clover.jar and /dev/null differ diff --git a/tests/integration/tests/custom-projects/ant-dynamic-clover/lib/clover/clover.license b/tests/integration/tests/custom-projects/ant-dynamic-clover/lib/clover/clover.license deleted file mode 100644 index d0adeaf4c93..00000000000 --- a/tests/integration/tests/custom-projects/ant-dynamic-clover/lib/clover/clover.license +++ /dev/null @@ -1,5 +0,0 @@ -opmOXvoSTwRurJtdPUPnnqXUoPxgewBKvhvFsQghghMpHN -mi2KCHwAl26X>gPZJcsdXAvR2KEZT5o>pDZqs>VNq7CbJD -OomqxtmMpmQQorqpnOqWVrrrQONpmONrNRUVuWTtSWSoop -qqnmqmUUnooqqonommmmmUUnooqqonommmmmUUJlkXoUUn -mmmm diff --git a/tests/integration/tests/custom-projects/ant-dynamic-clover/lib/cpl-v10.html b/tests/integration/tests/custom-projects/ant-dynamic-clover/lib/cpl-v10.html deleted file mode 100644 index 36aa208d4a2..00000000000 --- a/tests/integration/tests/custom-projects/ant-dynamic-clover/lib/cpl-v10.html +++ /dev/null @@ -1,125 +0,0 @@ - - - -Common Public License - v 1.0 - - - - - - -

Common Public License - v 1.0 -

-

THE ACCOMPANYING PROGRAM IS PROVIDED UNDER THE TERMS OF THIS COMMON PUBLIC LICENSE ("AGREEMENT"). ANY USE, REPRODUCTION OR DISTRIBUTION OF THE PROGRAM CONSTITUTES RECIPIENT'S ACCEPTANCE OF THIS AGREEMENT. -

-

1. DEFINITIONS -

"Contribution" means: - -

    a) in the case of the initial Contributor, the initial code and documentation distributed under this Agreement, and
    -b) in the case of each subsequent Contributor:
- - -
    i) changes to the Program, and
- - -
    ii) additions to the Program;
- - -
    where such changes and/or additions to the Program originate from and are distributed by that particular Contributor. A Contribution 'originates' from a Contributor if it was added to the Program by such Contributor itself or anyone acting on such Contributor's behalf. Contributions do not include additions to the Program which: (i) are separate modules of software distributed in conjunction with the Program under their own license agreement, and (ii) are not derivative works of the Program.
- -

-

"Contributor" means any person or entity that distributes the Program. -

-

"Licensed Patents " mean patent claims licensable by a Contributor which are necessarily infringed by the use or sale of its Contribution alone or when combined with the Program. -

-

"Program" means the Contributions distributed in accordance with this Agreement. -

-

"Recipient" means anyone who receives the Program under this Agreement, including all Contributors. -

-

2. GRANT OF RIGHTS - -

    a) Subject to the terms of this Agreement, each Contributor hereby grants Recipient a non-exclusive, worldwide, royalty-free copyright license to reproduce, prepare derivative works of, publicly display, publicly perform, distribute and sublicense the Contribution of such Contributor, if any, and such derivative works, in source code and object code form.
- - -
- - -
    b) Subject to the terms of this Agreement, each Contributor hereby grants Recipient a non-exclusive, worldwide, royalty-free patent license under Licensed Patents to make, use, sell, offer to sell, import and otherwise transfer the Contribution of such Contributor, if any, in source code and object code form. This patent license shall apply to the combination of the Contribution and the Program if, at the time the Contribution is added by the Contributor, such addition of the Contribution causes such combination to be covered by the Licensed Patents. The patent license shall not apply to any other combinations which include the Contribution. No hardware per se is licensed hereunder.
- - -
- - -
    c) Recipient understands that although each Contributor grants the licenses to its Contributions set forth herein, no assurances are provided by any Contributor that the Program does not infringe the patent or other intellectual property rights of any other entity. Each Contributor disclaims any liability to Recipient for claims brought by any other entity based on infringement of intellectual property rights or otherwise. As a condition to exercising the rights and licenses granted hereunder, each Recipient hereby assumes sole responsibility to secure any other intellectual property rights needed, if any. For example, if a third party patent license is required to allow Recipient to distribute the Program, it is Recipient's responsibility to acquire that license before distributing the Program.
- - -
- - -
    d) Each Contributor represents that to its knowledge it has sufficient copyright rights in its Contribution, if any, to grant the copyright license set forth in this Agreement.
- - -
- -

3. REQUIREMENTS -

A Contributor may choose to distribute the Program in object code form under its own license agreement, provided that: - -

    a) it complies with the terms and conditions of this Agreement; and
- - -
    b) its license agreement:
- - -
    i) effectively disclaims on behalf of all Contributors all warranties and conditions, express and implied, including warranties or conditions of title and non-infringement, and implied warranties or conditions of merchantability and fitness for a particular purpose;
- - -
    ii) effectively excludes on behalf of all Contributors all liability for damages, including direct, indirect, special, incidental and consequential damages, such as lost profits;
- - -
    iii) states that any provisions which differ from this Agreement are offered by that Contributor alone and not by any other party; and
- - -
    iv) states that source code for the Program is available from such Contributor, and informs licensees how to obtain it in a reasonable manner on or through a medium customarily used for software exchange.
- - -
- -

When the Program is made available in source code form: - -

    a) it must be made available under this Agreement; and
- - -
    b) a copy of this Agreement must be included with each copy of the Program.
- -

-

Contributors may not remove or alter any copyright notices contained within the Program. -

-

Each Contributor must identify itself as the originator of its Contribution, if any, in a manner that reasonably allows subsequent Recipients to identify the originator of the Contribution. -

-

4. COMMERCIAL DISTRIBUTION -

Commercial distributors of software may accept certain responsibilities with respect to end users, business partners and the like. While this license is intended to facilitate the commercial use of the Program, the Contributor who includes the Program in a commercial product offering should do so in a manner which does not create potential liability for other Contributors. Therefore, if a Contributor includes the Program in a commercial product offering, such Contributor ("Commercial Contributor") hereby agrees to defend and indemnify every other Contributor ("Indemnified Contributor") against any losses, damages and costs (collectively "Losses") arising from claims, lawsuits and other legal actions brought by a third party against the Indemnified Contributor to the extent caused by the acts or omissions of such Commercial Contributor in connection with its distribution of the Program in a commercial product offering. The obligations in this section do not apply to any claims or Losses relating to any actual or alleged intellectual property infringement. In order to qualify, an Indemnified Contributor must: a) promptly notify the Commercial Contributor in writing of such claim, and b) allow the Commercial Contributor to control, and cooperate with the Commercial Contributor in, the defense and any related settlement negotiations. The Indemnified Contributor may participate in any such claim at its own expense. -

-

For example, a Contributor might include the Program in a commercial product offering, Product X. That Contributor is then a Commercial Contributor. If that Commercial Contributor then makes performance claims, or offers warranties related to Product X, those performance claims and warranties are such Commercial Contributor's responsibility alone. Under this section, the Commercial Contributor would have to defend claims against the other Contributors related to those performance claims and warranties, and if a court requires any other Contributor to pay any damages as a result, the Commercial Contributor must pay those damages. -

-

5. NO WARRANTY -

EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, THE PROGRAM IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED INCLUDING, WITHOUT LIMITATION, ANY WARRANTIES OR CONDITIONS OF TITLE, NON-INFRINGEMENT, MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. Each Recipient is solely responsible for determining the appropriateness of using and distributing the Program and assumes all risks associated with its exercise of rights under this Agreement, including but not limited to the risks and costs of program errors, compliance with applicable laws, damage to or loss of data, programs or equipment, and unavailability or interruption of operations. -

-

6. DISCLAIMER OF LIABILITY -

EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, NEITHER RECIPIENT NOR ANY CONTRIBUTORS SHALL HAVE ANY LIABILITY FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING WITHOUT LIMITATION LOST PROFITS), HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OR DISTRIBUTION OF THE PROGRAM OR THE EXERCISE OF ANY RIGHTS GRANTED HEREUNDER, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. -

-

7. GENERAL -

If any provision of this Agreement is invalid or unenforceable under applicable law, it shall not affect the validity or enforceability of the remainder of the terms of this Agreement, and without further action by the parties hereto, such provision shall be reformed to the minimum extent necessary to make such provision valid and enforceable. -

-

If Recipient institutes patent litigation against a Contributor with respect to a patent applicable to software (including a cross-claim or counterclaim in a lawsuit), then any patent licenses granted by that Contributor to such Recipient under this Agreement shall terminate as of the date such litigation is filed. In addition, if Recipient institutes patent litigation against any entity (including a cross-claim or counterclaim in a lawsuit) alleging that the Program itself (excluding combinations of the Program with other software or hardware) infringes such Recipient's patent(s), then such Recipient's rights granted under Section 2(b) shall terminate as of the date such litigation is filed. -

-

All Recipient's rights under this Agreement shall terminate if it fails to comply with any of the material terms or conditions of this Agreement and does not cure such failure in a reasonable period of time after becoming aware of such noncompliance. If all Recipient's rights under this Agreement terminate, Recipient agrees to cease use and distribution of the Program as soon as reasonably practicable. However, Recipient's obligations under this Agreement and any licenses granted by Recipient relating to the Program shall continue and survive. -

-

Everyone is permitted to copy and distribute copies of this Agreement, but in order to avoid inconsistency the Agreement is copyrighted and may only be modified in the following manner. The Agreement Steward reserves the right to publish new versions (including revisions) of this Agreement from time to time. No one other than the Agreement Steward has the right to modify this Agreement. IBM is the initial Agreement Steward. IBM may assign the responsibility to serve as the Agreement Steward to a suitable separate entity. Each new version of the Agreement will be given a distinguishing version number. The Program (including Contributions) may always be distributed subject to the version of the Agreement under which it was received. In addition, after a new version of the Agreement is published, Contributor may elect to distribute the Program (including its Contributions) under the new version. Except as expressly stated in Sections 2(a) and 2(b) above, Recipient receives no rights or licenses to the intellectual property of any Contributor under this Agreement, whether expressly, by implication, estoppel or otherwise. All rights in the Program not expressly granted under this Agreement are reserved. -

-

This Agreement is governed by the laws of the State of New York and the intellectual property laws of the United States of America. No party to this Agreement will bring a legal action under this Agreement more than one year after the cause of action arose. Each party waives its rights to a jury trial in any resulting litigation. -

-

- - - - \ No newline at end of file diff --git a/tests/integration/tests/custom-projects/ant-dynamic-clover/lib/junit-3.8.2.jar b/tests/integration/tests/custom-projects/ant-dynamic-clover/lib/junit-3.8.2.jar deleted file mode 100644 index c8f711d050e..00000000000 Binary files a/tests/integration/tests/custom-projects/ant-dynamic-clover/lib/junit-3.8.2.jar and /dev/null differ diff --git a/tests/integration/tests/custom-projects/ant-dynamic-clover/pom.xml b/tests/integration/tests/custom-projects/ant-dynamic-clover/pom.xml deleted file mode 100644 index f580e840ddc..00000000000 --- a/tests/integration/tests/custom-projects/ant-dynamic-clover/pom.xml +++ /dev/null @@ -1,55 +0,0 @@ - - - - 4.0.0 - org.sonar.tests - ant-dynamic-clover - ant-dynamic-clover - 1.0 - - - reuseReports - clover - build/reports/coverage.xml - build/testresult - - - - src/main/java - - - build/app - - - - org.apache.maven.plugins - maven-compiler-plugin - - 1.5 - 1.5 - false - - **/* - - - - - - - - - - deps - dep1 - 0.1 - system - ${basedir}/lib/junit-3.8.2.jar - - - \ No newline at end of file diff --git a/tests/integration/tests/custom-projects/ant-dynamic-clover/src/main/java/com/cenqua/samples/money/IMoney.java b/tests/integration/tests/custom-projects/ant-dynamic-clover/src/main/java/com/cenqua/samples/money/IMoney.java deleted file mode 100644 index 21aab99bacd..00000000000 --- a/tests/integration/tests/custom-projects/ant-dynamic-clover/src/main/java/com/cenqua/samples/money/IMoney.java +++ /dev/null @@ -1,49 +0,0 @@ -//package junit.samples.money; -package com.cenqua.samples.money; - -/** - * The common interface for simple Monies and MoneyBags - */ -public interface IMoney { - /** - * Adds a money to this money. - */ - public abstract IMoney add(IMoney m); - - /** - * Adds a simple Money to this money. This is a helper method for - * implementing double dispatch - */ - public abstract IMoney addMoney(Money m); - - /** - * Adds a MoneyBag to this money. This is a helper method for - * implementing double dispatch - */ - public abstract IMoney addMoneyBag(MoneyBag s); - - /** - * Tests whether this money is zero - */ - public abstract boolean isZero(); - - /** - * Multiplies a money by the given factor. - */ - public abstract IMoney multiply(int factor); - - /** - * Negates this money. - */ - public abstract IMoney negate(); - - /** - * Subtracts a money from this money. - */ - public abstract IMoney subtract(IMoney m); - - /** - * Append this to a MoneyBag m. - */ - public abstract void appendTo(MoneyBag m); -} \ No newline at end of file diff --git a/tests/integration/tests/custom-projects/ant-dynamic-clover/src/main/java/com/cenqua/samples/money/Money.java b/tests/integration/tests/custom-projects/ant-dynamic-clover/src/main/java/com/cenqua/samples/money/Money.java deleted file mode 100644 index 7e41cf5aa52..00000000000 --- a/tests/integration/tests/custom-projects/ant-dynamic-clover/src/main/java/com/cenqua/samples/money/Money.java +++ /dev/null @@ -1,86 +0,0 @@ -//package junit.samples.money; -package com.cenqua.samples.money; - -/** - * A simple Money. - */ -public class Money implements IMoney { - - private int fAmount; - private String fCurrency; - - /** - * Constructs a money from the given amount and currency. - */ - public Money(int amount, String currency) { - fAmount = amount; - fCurrency = currency; - } - - /** - * Adds a money to this money. Forwards the request to the addMoney helper. - */ - public IMoney add(IMoney m) { - return m.addMoney(this); - } - - public IMoney addMoney(Money m) { - if (m.currency().equals(currency())) - return new Money(amount() + m.amount(), currency()); - return MoneyBag.create(this, m); - } - - public IMoney addMoneyBag(MoneyBag s) { - return s.addMoney(this); - } - - public int amount() { - return fAmount; - } - - public String currency() { - return fCurrency; - } - - public boolean equals(Object anObject) { - if (isZero()) - if (anObject instanceof IMoney) - return ((IMoney) anObject).isZero(); - if (anObject instanceof Money) { - Money aMoney = (Money) anObject; - return aMoney.currency().equals(currency()) - && amount() == aMoney.amount(); - } - return false; - } - - public int hashCode() { - return fCurrency.hashCode() + fAmount; - } - - public boolean isZero() { - return amount() == 0; - } - - public IMoney multiply(int factor) { - return new Money(amount() * factor, currency()); - } - - public IMoney negate() { - return new Money(-amount(), currency()); - } - - public IMoney subtract(IMoney m) { - return add(m.negate()); - } - - public String toString() { - StringBuffer buffer = new StringBuffer(); - buffer.append("[" + amount() + " " + currency() + "]"); - return buffer.toString(); - } - - public /*this makes no sense*/ void appendTo(MoneyBag m) { - m.appendMoney(this); - } -} \ No newline at end of file diff --git a/tests/integration/tests/custom-projects/ant-dynamic-clover/src/main/java/com/cenqua/samples/money/MoneyBag.java b/tests/integration/tests/custom-projects/ant-dynamic-clover/src/main/java/com/cenqua/samples/money/MoneyBag.java deleted file mode 100644 index 354f1d7c32e..00000000000 --- a/tests/integration/tests/custom-projects/ant-dynamic-clover/src/main/java/com/cenqua/samples/money/MoneyBag.java +++ /dev/null @@ -1,148 +0,0 @@ -//package junit.samples.money; -package com.cenqua.samples.money; - -import java.util.*; - -/** - * A MoneyBag defers exchange rate conversions. For example adding - * 12 Swiss Francs to 14 US Dollars is represented as a bag - * containing the two Monies 12 CHF and 14 USD. Adding another - * 10 Swiss francs gives a bag with 22 CHF and 14 USD. Due to - * the deferred exchange rate conversion we can later value a - * MoneyBag with different exchange rates. - *

- * A MoneyBag is represented as a list of Monies and provides - * different constructors to create a MoneyBag. - */ -class MoneyBag implements IMoney { - private Vector fMonies = new Vector(5); - - static IMoney create(IMoney m1, IMoney m2) { - MoneyBag result = new MoneyBag(); - m1.appendTo(result); - m2.appendTo(result); - return result.simplify(); - } - - public IMoney add(IMoney m) { - return m.addMoneyBag(this); - } - - public IMoney addMoney(Money m) { - return MoneyBag.create(m, this); - } - - public IMoney addMoneyBag(MoneyBag s) { - return MoneyBag.create(s, this); - } - - void appendBag(MoneyBag aBag) { - for (Enumeration e = aBag.fMonies.elements(); e.hasMoreElements();) - appendMoney((Money) e.nextElement()); - } - - void appendMoney(Money aMoney) { - if (aMoney.isZero()) return; - IMoney old = findMoney(aMoney.currency()); - if (old == null) { - fMonies.addElement(aMoney); - return; - } - fMonies.removeElement(old); - IMoney sum = old.add(aMoney); - if (sum.isZero()) - return; - fMonies.addElement(sum); - } - - public boolean equals(Object anObject) { - if (isZero()) - if (anObject instanceof IMoney) - return ((IMoney) anObject).isZero(); - - if (anObject instanceof MoneyBag) { - MoneyBag aMoneyBag = (MoneyBag) anObject; - if (aMoneyBag.fMonies.size() != fMonies.size()) - return false; - - for (Enumeration e = fMonies.elements(); e.hasMoreElements();) { - Money m = (Money) e.nextElement(); - if (!aMoneyBag.contains(m)) - return false; - } - return true; - } - return false; - } - - private Money findMoney(String currency) { - for (Enumeration e = fMonies.elements(); e.hasMoreElements();) { - Money m = (Money) e.nextElement(); - if (m.currency().equals(currency)) - return m; - } - return null; - } - - private boolean contains(Money m) { - Money found = findMoney(m.currency()); - if (found == null) return false; - return found.amount() == m.amount(); - } - - public int hashCode() { - int hash = 0; - for (Enumeration e = fMonies.elements(); e.hasMoreElements();) { - Object m = e.nextElement(); - hash ^= m.hashCode(); - } - return hash; - } - - public boolean isZero() { - return fMonies.size() == 0; - } - - public IMoney multiply(int factor) { - MoneyBag result = new MoneyBag(); - if (factor != 0) { - for (Enumeration e = fMonies.elements(); e.hasMoreElements();) { - Money m = (Money) e.nextElement(); - result.appendMoney((Money) m.multiply(factor)); - } - } - return result; - } - - public IMoney negate() { - MoneyBag result = new MoneyBag(); - for (Enumeration e = fMonies.elements(); e.hasMoreElements();) { - Money m = (Money) e.nextElement(); - result.appendMoney((Money) m.negate()); - } - return result; - } - - private IMoney simplify() { - if (fMonies.size() == 1) - return (IMoney) fMonies.elements().nextElement(); - return this; - } - - public IMoney subtract(IMoney m) { - return add(m.negate()); - } - - public String toString() { - StringBuffer buffer = new StringBuffer(); - buffer.append("{"); - for (Enumeration e = fMonies.elements(); e.hasMoreElements();) - buffer.append(e.nextElement()); - buffer.append("}"); - return buffer.toString(); - } - - public void appendTo(MoneyBag m) { - m.appendBag(this); - } -} \ No newline at end of file diff --git a/tests/integration/tests/custom-projects/ant-dynamic-clover/src/test/java/com/cenqua/samples/money/MoneyBagTest.java b/tests/integration/tests/custom-projects/ant-dynamic-clover/src/test/java/com/cenqua/samples/money/MoneyBagTest.java deleted file mode 100644 index 1da75a987f1..00000000000 --- a/tests/integration/tests/custom-projects/ant-dynamic-clover/src/test/java/com/cenqua/samples/money/MoneyBagTest.java +++ /dev/null @@ -1,174 +0,0 @@ -//package junit.samples.money; -package com.cenqua.samples.money; - -import junit.framework.TestCase; - - -public class MoneyBagTest extends TestCase { - private Money f12CHF; - private Money f14CHF; - private Money f7USD; - private Money f21USD; - - private IMoney fMB1; - private IMoney fMB2; - - public static void main(String args[]) { - junit.textui.TestRunner.run(MoneyBagTest.class); - } - - protected void setUp() { - f12CHF = new Money(12, "CHF"); - f14CHF = new Money(14, "CHF"); - f7USD = new Money(7, "USD"); - f21USD = new Money(21, "USD"); - - fMB1 = MoneyBag.create(f12CHF, f7USD); - fMB2 = MoneyBag.create(f14CHF, f21USD); - } - - protected void tearDown() throws Exception { - // call toString, guranteed to be only called from here. - // this is for testing, coverage by test. - fMB1.toString(); - } - - public void testBagMultiply() { - // {[12 CHF][7 USD]} *2 == {[24 CHF][14 USD]} - IMoney expected = MoneyBag.create(new Money(24, "CHF"), new Money(14, "USD")); - assertEquals(expected, fMB1.multiply(2)); - assertEquals(fMB1, fMB1.multiply(1)); - assertTrue(fMB1.multiply(0).isZero()); - } - - public void testBagNegate() { - // {[12 CHF][7 USD]} negate == {[-12 CHF][-7 USD]} - IMoney expected = MoneyBag.create(new Money(-12, "CHF"), new Money(-7, "USD")); - assertEquals(expected, fMB1.negate()); - } - - public void testBagSimpleAdd() { - // {[12 CHF][7 USD]} + [14 CHF] == {[26 CHF][7 USD]} - IMoney expected = MoneyBag.create(new Money(26, "CHF"), new Money(7, "USD")); - assertEquals(expected, fMB1.add(f14CHF)); - } - - public void testBagSubtract() { - // {[12 CHF][7 USD]} - {[14 CHF][21 USD] == {[-2 CHF][-14 USD]} - IMoney expected = MoneyBag.create(new Money(-2, "CHF"), new Money(-14, "USD")); - assertEquals(expected, fMB1.subtract(fMB2)); - } - - public void testBagSumAdd() { - // {[12 CHF][7 USD]} + {[14 CHF][21 USD]} == {[26 CHF][28 USD]} - IMoney expected = MoneyBag.create(new Money(26, "CHF"), new Money(28, "USD")); - assertEquals(expected, fMB1.add(fMB2)); - } - - public void testIsZero() { - assertTrue(fMB1.subtract(fMB1).isZero()); - assertTrue(MoneyBag.create(new Money(0, "CHF"), new Money(0, "USD")).isZero()); - } - - public void testMixedSimpleAdd() { - // [12 CHF] + [7 USD] == {[12 CHF][7 USD]} - IMoney expected = MoneyBag.create(f12CHF, f7USD); - assertEquals(expected, f12CHF.add(f7USD)); - } - - public void testBagNotEquals() { - IMoney bag = MoneyBag.create(f12CHF, f7USD); - assertFalse(bag.equals(new Money(12, "DEM").add(f7USD))); - } - - public void testMoneyBagEquals() { - assertTrue(!fMB1.equals(null)); - - assertEquals(fMB1, fMB1); - IMoney equal = MoneyBag.create(new Money(12, "CHF"), new Money(7, "USD")); - assertTrue(fMB1.equals(equal)); - assertTrue(!fMB1.equals(f12CHF)); - assertTrue(!f12CHF.equals(fMB1)); - assertTrue(!fMB1.equals(fMB2)); - } - - public void testMoneyBagHash() { - IMoney equal = MoneyBag.create(new Money(12, "CHF"), new Money(7, "USD")); - assertEquals(fMB1.hashCode(), equal.hashCode()); - } - - public void testMoneyEquals() { - assertTrue(!f12CHF.equals(null)); - Money equalMoney = new Money(12, "CHF"); - assertEquals(f12CHF, f12CHF); - assertEquals(f12CHF, equalMoney); - assertEquals(f12CHF.hashCode(), equalMoney.hashCode()); - assertTrue(!f12CHF.equals(f14CHF)); - } - - public void testMoneyHash() { - assertTrue(!f12CHF.equals(null)); - Money equal = new Money(12, "CHF"); - assertEquals(f12CHF.hashCode(), equal.hashCode()); - } - - public void testSimplify() { - IMoney money = MoneyBag.create(new Money(26, "CHF"), new Money(28, "CHF")); - assertEquals(new Money(54, "CHF"), money); - } - - public void testNormalize2() { - // {[12 CHF][7 USD]} - [12 CHF] == [7 USD] - Money expected = new Money(7, "USD"); - assertEquals(expected, fMB1.subtract(f12CHF)); - } - - public void testNormalize3() { - // {[12 CHF][7 USD]} - {[12 CHF][3 USD]} == [4 USD] - IMoney ms1 = MoneyBag.create(new Money(12, "CHF"), new Money(3, "USD")); - Money expected = new Money(4, "USD"); - assertEquals(expected, fMB1.subtract(ms1)); - } - - public void testNormalize4() { - // [12 CHF] - {[12 CHF][3 USD]} == [-3 USD] - IMoney ms1 = MoneyBag.create(new Money(12, "CHF"), new Money(3, "USD")); - Money expected = new Money(-3, "USD"); - assertEquals(expected, f12CHF.subtract(ms1)); - } - - public void testPrint() { - assertEquals("[12 CHF]", f12CHF.toString()); - } - - public void testSimpleAdd() { - // [12 CHF] + [14 CHF] == [26 CHF] - Money expected = new Money(26, "CHF"); - assertEquals(expected, f12CHF.add(f14CHF)); - } - - public void testSimpleBagAdd() { - // [14 CHF] + {[12 CHF][7 USD]} == {[26 CHF][7 USD]} - IMoney expected = MoneyBag.create(new Money(26, "CHF"), new Money(7, "USD")); - assertEquals(expected, f14CHF.add(fMB1)); - } - - public void testSimpleMultiply() { - // [14 CHF] *2 == [28 CHF] - Money expected = new Money(28, "CHF"); - assertEquals(expected, f14CHF.multiply(2)); - } - - public void testSimpleNegate() { - // [14 CHF] negate == [-14 CHF] - Money expected = new Money(-14, "CHF"); - assertEquals(expected, f14CHF.negate()); - } - - public void testSimpleSubtract() { - // [14 CHF] - [12 CHF] == [2 CHF] - Money expected = new Money(2, "CHF"); - assertEquals(expected, f14CHF.subtract(f12CHF)); - } - -} \ No newline at end of file diff --git a/tests/integration/tests/custom-projects/ant-dynamic-clover/src/test/java/com/cenqua/samples/money/MoneyTest.java b/tests/integration/tests/custom-projects/ant-dynamic-clover/src/test/java/com/cenqua/samples/money/MoneyTest.java deleted file mode 100644 index e352457a0fa..00000000000 --- a/tests/integration/tests/custom-projects/ant-dynamic-clover/src/test/java/com/cenqua/samples/money/MoneyTest.java +++ /dev/null @@ -1,19 +0,0 @@ -package com.cenqua.samples.money; - -import junit.framework.TestCase; - -/** - * This is a trivial test which only tests the Money class. - * If you modify the MoneyBag class, and run Clover with optimization, this test will not be run. - */ -public class MoneyTest extends TestCase { - - public void testAdd() throws InterruptedException { - Money tenEuro = new Money(10, "EURO"); - assertEquals(10, tenEuro.amount()); - assertEquals("EURO", tenEuro.currency()); - System.out.println("Tests taking too long? Try clover's test optimization."); - Thread.sleep(3000); - } - -} diff --git a/tests/integration/tests/custom-projects/ant-dynamic-cobertura/build.xml b/tests/integration/tests/custom-projects/ant-dynamic-cobertura/build.xml deleted file mode 100644 index 1415ca282cf..00000000000 --- a/tests/integration/tests/custom-projects/ant-dynamic-cobertura/build.xml +++ /dev/null @@ -1,140 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/tests/integration/tests/custom-projects/ant-dynamic-cobertura/lib/cobertura/asm-3.0.jar b/tests/integration/tests/custom-projects/ant-dynamic-cobertura/lib/cobertura/asm-3.0.jar deleted file mode 100644 index 112f5bd4aec..00000000000 Binary files a/tests/integration/tests/custom-projects/ant-dynamic-cobertura/lib/cobertura/asm-3.0.jar and /dev/null differ diff --git a/tests/integration/tests/custom-projects/ant-dynamic-cobertura/lib/cobertura/asm-tree-3.0.jar b/tests/integration/tests/custom-projects/ant-dynamic-cobertura/lib/cobertura/asm-tree-3.0.jar deleted file mode 100644 index 2a4b20856c0..00000000000 Binary files a/tests/integration/tests/custom-projects/ant-dynamic-cobertura/lib/cobertura/asm-tree-3.0.jar and /dev/null differ diff --git a/tests/integration/tests/custom-projects/ant-dynamic-cobertura/lib/cobertura/cobertura.jar b/tests/integration/tests/custom-projects/ant-dynamic-cobertura/lib/cobertura/cobertura.jar deleted file mode 100644 index 5cabbf258cf..00000000000 Binary files a/tests/integration/tests/custom-projects/ant-dynamic-cobertura/lib/cobertura/cobertura.jar and /dev/null differ diff --git a/tests/integration/tests/custom-projects/ant-dynamic-cobertura/lib/cobertura/jakarta-oro-2.0.8.jar b/tests/integration/tests/custom-projects/ant-dynamic-cobertura/lib/cobertura/jakarta-oro-2.0.8.jar deleted file mode 100644 index 23488d2600f..00000000000 Binary files a/tests/integration/tests/custom-projects/ant-dynamic-cobertura/lib/cobertura/jakarta-oro-2.0.8.jar and /dev/null differ diff --git a/tests/integration/tests/custom-projects/ant-dynamic-cobertura/lib/cobertura/jakarta-oro-license.txt b/tests/integration/tests/custom-projects/ant-dynamic-cobertura/lib/cobertura/jakarta-oro-license.txt deleted file mode 100644 index 100f86b44d2..00000000000 --- a/tests/integration/tests/custom-projects/ant-dynamic-cobertura/lib/cobertura/jakarta-oro-license.txt +++ /dev/null @@ -1,53 +0,0 @@ -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2000-2002 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation", "Jakarta-Oro" - * must not be used to endorse or promote products derived from this - * software without prior written permission. For written - * permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache" - * or "Jakarta-Oro", nor may "Apache" or "Jakarta-Oro" appear in their - * name, without prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ diff --git a/tests/integration/tests/custom-projects/ant-dynamic-cobertura/lib/cobertura/log4j-1.2.9.jar b/tests/integration/tests/custom-projects/ant-dynamic-cobertura/lib/cobertura/log4j-1.2.9.jar deleted file mode 100644 index a6568b01a21..00000000000 Binary files a/tests/integration/tests/custom-projects/ant-dynamic-cobertura/lib/cobertura/log4j-1.2.9.jar and /dev/null differ diff --git a/tests/integration/tests/custom-projects/ant-dynamic-cobertura/lib/cobertura/log4j-license.txt b/tests/integration/tests/custom-projects/ant-dynamic-cobertura/lib/cobertura/log4j-license.txt deleted file mode 100644 index 030564fc133..00000000000 --- a/tests/integration/tests/custom-projects/ant-dynamic-cobertura/lib/cobertura/log4j-license.txt +++ /dev/null @@ -1,48 +0,0 @@ -/* - * ============================================================================ - * The Apache Software License, Version 1.1 - * ============================================================================ - * - * Copyright (C) 1999 The Apache Software Foundation. All rights reserved. - * - * Redistribution and use in source and binary forms, with or without modifica- - * tion, are permitted provided that the following conditions are met: - * - * 1. Redistributions of source code must retain the above copyright notice, - * this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright notice, - * this list of conditions and the following disclaimer in the documentation - * and/or other materials provided with the distribution. - * - * 3. The end-user documentation included with the redistribution, if any, must - * include the following acknowledgment: "This product includes software - * developed by the Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, if - * and wherever such third-party acknowledgments normally appear. - * - * 4. The names "log4j" and "Apache Software Foundation" must not be used to - * endorse or promote products derived from this software without prior - * written permission. For written permission, please contact - * apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", nor may - * "Apache" appear in their name, without prior written permission of the - * Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED WARRANTIES, - * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND - * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE - * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, - * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU- - * DING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS - * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON - * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT - * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF - * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * - * This software consists of voluntary contributions made by many individuals - * on behalf of the Apache Software Foundation. For more information on the - * Apache Software Foundation, please see . - * - */ diff --git a/tests/integration/tests/custom-projects/ant-dynamic-cobertura/lib/junit-3.8.2.jar b/tests/integration/tests/custom-projects/ant-dynamic-cobertura/lib/junit-3.8.2.jar deleted file mode 100644 index c8f711d050e..00000000000 Binary files a/tests/integration/tests/custom-projects/ant-dynamic-cobertura/lib/junit-3.8.2.jar and /dev/null differ diff --git a/tests/integration/tests/custom-projects/ant-dynamic-cobertura/lib/log4j-1.2.13.jar b/tests/integration/tests/custom-projects/ant-dynamic-cobertura/lib/log4j-1.2.13.jar deleted file mode 100644 index dde9972109d..00000000000 Binary files a/tests/integration/tests/custom-projects/ant-dynamic-cobertura/lib/log4j-1.2.13.jar and /dev/null differ diff --git a/tests/integration/tests/custom-projects/ant-dynamic-cobertura/pom.xml b/tests/integration/tests/custom-projects/ant-dynamic-cobertura/pom.xml deleted file mode 100644 index f22d23ff120..00000000000 --- a/tests/integration/tests/custom-projects/ant-dynamic-cobertura/pom.xml +++ /dev/null @@ -1,62 +0,0 @@ - - - - 4.0.0 - org.sonar.tests - ant-dynamic-cobertura - ant-dynamic-cobertura - 1.0 - - - src - - - build/classes - - - - org.apache.maven.plugins - maven-compiler-plugin - - 1.5 - 1.5 - false - - **/* - - - - - - - - - - deps - dep1 - 0.1 - system - ${basedir}/lib/log4j-1.2.13.jar - - - deps - dep2 - 0.1 - system - ${basedir}/lib/junit-3.8.2.jar - - - - - reuseReports - **/*Test.java - reports/cobertura/xml/coverage.xml - reports/junit/xml - - \ No newline at end of file diff --git a/tests/integration/tests/custom-projects/ant-dynamic-cobertura/src/FailTest.java b/tests/integration/tests/custom-projects/ant-dynamic-cobertura/src/FailTest.java deleted file mode 100644 index d75067caf7f..00000000000 --- a/tests/integration/tests/custom-projects/ant-dynamic-cobertura/src/FailTest.java +++ /dev/null @@ -1,10 +0,0 @@ -public class FailTest extends junit.framework.TestCase { - - public void testNothing() { - } - - public void testWillAlwaysFail() { - fail("An error message"); - } - -} \ No newline at end of file diff --git a/tests/integration/tests/custom-projects/ant-dynamic-cobertura/src/ant/HelloWorld.java b/tests/integration/tests/custom-projects/ant-dynamic-cobertura/src/ant/HelloWorld.java deleted file mode 100644 index 6c9c7a9be3a..00000000000 --- a/tests/integration/tests/custom-projects/ant-dynamic-cobertura/src/ant/HelloWorld.java +++ /dev/null @@ -1,28 +0,0 @@ -package ant; - -import org.apache.log4j.Logger; -import org.apache.log4j.BasicConfigurator; -import java.util.Vector; - -public class HelloWorld { - static Logger logger = Logger.getLogger(HelloWorld.class); - - public static void main(String[] args) { - BasicConfigurator.configure(); - logger.info("Hello World"); // the old SysO-statement - - String temp = new String(); - Vector v = new Vector(); - } - - public Object clone() { - return new HelloWorld(); - } - public boolean equals(Object o) { - return true; - } - - public boolean Equals(Object o) { - return true; - } -} \ No newline at end of file diff --git a/tests/integration/tests/custom-projects/ant-dynamic-cobertura/src/ant/HelloWorldTest.java b/tests/integration/tests/custom-projects/ant-dynamic-cobertura/src/ant/HelloWorldTest.java deleted file mode 100644 index 891a5bd9962..00000000000 --- a/tests/integration/tests/custom-projects/ant-dynamic-cobertura/src/ant/HelloWorldTest.java +++ /dev/null @@ -1,14 +0,0 @@ -package ant; - -public class HelloWorldTest extends junit.framework.TestCase { - - public void testClone() { - HelloWorld hello = new HelloWorld(); - assertEquals(hello, hello.clone()); - } - - public void testWillAlwaysFail() { - fail("An error message"); - } - -} \ No newline at end of file diff --git a/tests/integration/tests/custom-projects/ant-dynamic-junit/build.xml b/tests/integration/tests/custom-projects/ant-dynamic-junit/build.xml deleted file mode 100644 index 72a7217740a..00000000000 --- a/tests/integration/tests/custom-projects/ant-dynamic-junit/build.xml +++ /dev/null @@ -1,81 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/tests/integration/tests/custom-projects/ant-dynamic-junit/lib/junit-3.8.2.jar b/tests/integration/tests/custom-projects/ant-dynamic-junit/lib/junit-3.8.2.jar deleted file mode 100644 index c8f711d050e..00000000000 Binary files a/tests/integration/tests/custom-projects/ant-dynamic-junit/lib/junit-3.8.2.jar and /dev/null differ diff --git a/tests/integration/tests/custom-projects/ant-dynamic-junit/lib/log4j-1.2.13.jar b/tests/integration/tests/custom-projects/ant-dynamic-junit/lib/log4j-1.2.13.jar deleted file mode 100644 index dde9972109d..00000000000 Binary files a/tests/integration/tests/custom-projects/ant-dynamic-junit/lib/log4j-1.2.13.jar and /dev/null differ diff --git a/tests/integration/tests/custom-projects/ant-dynamic-junit/pom.xml b/tests/integration/tests/custom-projects/ant-dynamic-junit/pom.xml deleted file mode 100644 index cda311eeedf..00000000000 --- a/tests/integration/tests/custom-projects/ant-dynamic-junit/pom.xml +++ /dev/null @@ -1,59 +0,0 @@ - - - - 4.0.0 - org.sonar.tests - ant-dynamic-junit - ant-dynamic-junit - 1.0 - - - src - test - - - build/classes - build/test - - - - org.apache.maven.plugins - maven-compiler-plugin - - 1.5 - 1.5 - false - **/* - - - - - - - - - deps - dep1 - 0.1 - system - ${basedir}/lib/log4j-1.2.13.jar - - - deps - dep2 - 0.1 - system - ${basedir}/lib/junit-3.8.2.jar - - - - - reuseReports - reports/junit/xml - - \ No newline at end of file diff --git a/tests/integration/tests/custom-projects/ant-dynamic-junit/src/ant/HelloWorld.java b/tests/integration/tests/custom-projects/ant-dynamic-junit/src/ant/HelloWorld.java deleted file mode 100644 index 6c9c7a9be3a..00000000000 --- a/tests/integration/tests/custom-projects/ant-dynamic-junit/src/ant/HelloWorld.java +++ /dev/null @@ -1,28 +0,0 @@ -package ant; - -import org.apache.log4j.Logger; -import org.apache.log4j.BasicConfigurator; -import java.util.Vector; - -public class HelloWorld { - static Logger logger = Logger.getLogger(HelloWorld.class); - - public static void main(String[] args) { - BasicConfigurator.configure(); - logger.info("Hello World"); // the old SysO-statement - - String temp = new String(); - Vector v = new Vector(); - } - - public Object clone() { - return new HelloWorld(); - } - public boolean equals(Object o) { - return true; - } - - public boolean Equals(Object o) { - return true; - } -} \ No newline at end of file diff --git a/tests/integration/tests/custom-projects/ant-dynamic-junit/test/FailTest.java b/tests/integration/tests/custom-projects/ant-dynamic-junit/test/FailTest.java deleted file mode 100644 index 7cdd82548ee..00000000000 --- a/tests/integration/tests/custom-projects/ant-dynamic-junit/test/FailTest.java +++ /dev/null @@ -1,10 +0,0 @@ -public class FailTest extends junit.framework.TestCase { - - public void testNothing() { - } - - public void testWillAlwaysFail() { - fail("An error message"); - } - -} \ No newline at end of file diff --git a/tests/integration/tests/custom-projects/ant-dynamic-junit/test/ant/HelloWorldTest.java b/tests/integration/tests/custom-projects/ant-dynamic-junit/test/ant/HelloWorldTest.java deleted file mode 100644 index 47ae3adeb1d..00000000000 --- a/tests/integration/tests/custom-projects/ant-dynamic-junit/test/ant/HelloWorldTest.java +++ /dev/null @@ -1,14 +0,0 @@ -package ant; - -public class HelloWorldTest extends junit.framework.TestCase { - - public void testClone() { - HelloWorld hello = new HelloWorld(); - assertEquals(hello, hello.clone()); - } - - public void testWillAlwaysFail() { - fail("An error message"); - } - -} \ No newline at end of file diff --git a/tests/integration/tests/custom-projects/ant-static/build.xml b/tests/integration/tests/custom-projects/ant-static/build.xml deleted file mode 100644 index c49b8a9ca8a..00000000000 --- a/tests/integration/tests/custom-projects/ant-static/build.xml +++ /dev/null @@ -1,45 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/tests/integration/tests/custom-projects/ant-static/lib/log4j-1.2.13.jar b/tests/integration/tests/custom-projects/ant-static/lib/log4j-1.2.13.jar deleted file mode 100644 index dde9972109d..00000000000 Binary files a/tests/integration/tests/custom-projects/ant-static/lib/log4j-1.2.13.jar and /dev/null differ diff --git a/tests/integration/tests/custom-projects/ant-static/pom.xml b/tests/integration/tests/custom-projects/ant-static/pom.xml deleted file mode 100644 index f4f4375e0a7..00000000000 --- a/tests/integration/tests/custom-projects/ant-static/pom.xml +++ /dev/null @@ -1,51 +0,0 @@ - - - - 4.0.0 - org.sonar.tests - ant-static - ant-static - 1.0 - Static analysis of Ant project - - - src - - - build/classes - - - - org.apache.maven.plugins - maven-compiler-plugin - - 1.5 - 1.5 - false - **/* - - - - - - - - - - deps - dep1 - 0.1 - system - ${basedir}/lib/log4j-1.2.13.jar - - - - - false - - \ No newline at end of file diff --git a/tests/integration/tests/custom-projects/ant-static/src/ant/HelloWorld.java b/tests/integration/tests/custom-projects/ant-static/src/ant/HelloWorld.java deleted file mode 100644 index 6c9c7a9be3a..00000000000 --- a/tests/integration/tests/custom-projects/ant-static/src/ant/HelloWorld.java +++ /dev/null @@ -1,28 +0,0 @@ -package ant; - -import org.apache.log4j.Logger; -import org.apache.log4j.BasicConfigurator; -import java.util.Vector; - -public class HelloWorld { - static Logger logger = Logger.getLogger(HelloWorld.class); - - public static void main(String[] args) { - BasicConfigurator.configure(); - logger.info("Hello World"); // the old SysO-statement - - String temp = new String(); - Vector v = new Vector(); - } - - public Object clone() { - return new HelloWorld(); - } - public boolean equals(Object o) { - return true; - } - - public boolean Equals(Object o) { - return true; - } -} \ No newline at end of file diff --git a/tests/integration/tests/custom-projects/big-project/generate-sources.rb b/tests/integration/tests/custom-projects/big-project/generate-sources.rb deleted file mode 100644 index 719b8b1387f..00000000000 --- a/tests/integration/tests/custom-projects/big-project/generate-sources.rb +++ /dev/null @@ -1,49 +0,0 @@ -require 'fileutils.rb' - -class GenerateSources - - def initialize - FileUtils.remove_dir "src/main/java", true - end - - def template - if @template.nil? - @template = '' - f = File.open("template.java", "r") - f.each_line do |line| - @template += line - end - end - @template - end - - def sources(package_name, class_name) - template.gsub(/#PACKAGE/,package_name).gsub(/#CLASS/, class_name) - end - - def generate(package_name, class_name) - content=sources(package_name, class_name) - dir="src/main/java/" + package_name.gsub(/\./, '/') - save(dir, "#{class_name}.java", content) - end - - private - def save(dir, filename,content) - FileUtils::mkdir_p dir - my_file = File.new("#{dir}/#{filename}", 'w') - my_file<0 ? ARGV[0].to_i : 10) -classes_count=(ARGV.size>1 ? ARGV[1].to_i : 500) -generator=GenerateSources.new - -for index_package in (1..packages_count) - for index_class in (1..classes_count) - generator.generate("org.sonar.tests.bigproject#{index_package}", "Class#{index_class}") - end -end - -puts "#{classes_count * packages_count} classes saved in #{packages_count} packages." \ No newline at end of file diff --git a/tests/integration/tests/custom-projects/big-project/pom.xml b/tests/integration/tests/custom-projects/big-project/pom.xml deleted file mode 100644 index 9637d505755..00000000000 --- a/tests/integration/tests/custom-projects/big-project/pom.xml +++ /dev/null @@ -1,8 +0,0 @@ - - 4.0.0 - org.sonar.tests - big-project - 1.0-SNAPSHOT - jar - Sonar tests - big project - \ No newline at end of file diff --git a/tests/integration/tests/custom-projects/big-project/template.java b/tests/integration/tests/custom-projects/big-project/template.java deleted file mode 100644 index 94e7e574b55..00000000000 --- a/tests/integration/tests/custom-projects/big-project/template.java +++ /dev/null @@ -1,38 +0,0 @@ -package #PACKAGE; - -import java.util.*; - -public class #CLASS { - public void hello( ) { - System.out.println("hello");; - int index=333; - } - - public void Hello( ) { - for (int i=0 ; i<1000 ; i++) { - int j=i*2; - } - } - - public static final int FOO() { - int j=111; - j++; - Vector v = new Vector(); - Vector v2 = new Vector(); - String s=null; - System.out.println(s); - return 222; - } - - public Object clone() { - return new Object(); - } - - public String toString() { - return "xxxxxxxxxxxxxxxx"; - } - - public String toString(String s) { - return s; - } -} \ No newline at end of file diff --git a/tests/integration/tests/custom-projects/deprecated-sonar-light/build.xml b/tests/integration/tests/custom-projects/deprecated-sonar-light/build.xml deleted file mode 100644 index 6e9b394b8a6..00000000000 --- a/tests/integration/tests/custom-projects/deprecated-sonar-light/build.xml +++ /dev/null @@ -1,45 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/tests/integration/tests/custom-projects/deprecated-sonar-light/lib/log4j-1.2.13.jar b/tests/integration/tests/custom-projects/deprecated-sonar-light/lib/log4j-1.2.13.jar deleted file mode 100644 index dde9972109d..00000000000 Binary files a/tests/integration/tests/custom-projects/deprecated-sonar-light/lib/log4j-1.2.13.jar and /dev/null differ diff --git a/tests/integration/tests/custom-projects/deprecated-sonar-light/pom.xml b/tests/integration/tests/custom-projects/deprecated-sonar-light/pom.xml deleted file mode 100644 index b017cdadac2..00000000000 --- a/tests/integration/tests/custom-projects/deprecated-sonar-light/pom.xml +++ /dev/null @@ -1,52 +0,0 @@ - - - - 4.0.0 - org.sonar.tests - deprecated-sonar-light - deprecated-sonar-light - 1.0 - Deprecated "light mode" - - - src - - - build/classes - - - - org.apache.maven.plugins - maven-compiler-plugin - - 1.5 - 1.5 - false - **/* - - - - - - - - - - deps - dep1 - 0.1 - system - ${basedir}/lib/log4j-1.2.13.jar - - - - - true - build/classes - - \ No newline at end of file diff --git a/tests/integration/tests/custom-projects/deprecated-sonar-light/src/hello/HelloWorld.java b/tests/integration/tests/custom-projects/deprecated-sonar-light/src/hello/HelloWorld.java deleted file mode 100644 index 1411f9f15bf..00000000000 --- a/tests/integration/tests/custom-projects/deprecated-sonar-light/src/hello/HelloWorld.java +++ /dev/null @@ -1,28 +0,0 @@ -package hello; - -import org.apache.log4j.Logger; -import org.apache.log4j.BasicConfigurator; -import java.util.Vector; - -public class HelloWorld { - static Logger logger = Logger.getLogger(HelloWorld.class); - - public static void main(String[] args) { - BasicConfigurator.configure(); - logger.info("Hello World"); // the old SysO-statement - - String temp = new String(); - Vector v = new Vector(); - } - - public Object clone() { - return new HelloWorld(); - } - public boolean equals(Object o) { - return true; - } - - public boolean Equals(Object o) { - return true; - } -} \ No newline at end of file diff --git a/tests/integration/tests/custom-projects/invalid-java-source-dir/pom.xml b/tests/integration/tests/custom-projects/invalid-java-source-dir/pom.xml deleted file mode 100644 index 814f2a8f99e..00000000000 --- a/tests/integration/tests/custom-projects/invalid-java-source-dir/pom.xml +++ /dev/null @@ -1,24 +0,0 @@ - - - - 4.0.0 - org.sonar.tests - invalid-java-source-dir - invalid-java-source-dir - 1.0-SNAPSHOT - - SONAR-791 When the source directory is not exactly the java package root, Sonar should stop the analysis. - See http://jira.codehaus.org/browse/SONAR-791 - - - - - src - - - - false - - \ No newline at end of file diff --git a/tests/integration/tests/custom-projects/invalid-java-source-dir/src/main/java/com/foo/Bar.java b/tests/integration/tests/custom-projects/invalid-java-source-dir/src/main/java/com/foo/Bar.java deleted file mode 100644 index 94482bf6d3b..00000000000 --- a/tests/integration/tests/custom-projects/invalid-java-source-dir/src/main/java/com/foo/Bar.java +++ /dev/null @@ -1,8 +0,0 @@ -package com.foo; - -public class Bar { - public void hello(String param) { - String s="hello"; - int i=3000; - } -} \ No newline at end of file diff --git a/tests/integration/tests/custom-projects/reuse-coverage-reports/pom.xml b/tests/integration/tests/custom-projects/reuse-coverage-reports/pom.xml deleted file mode 100644 index 0a9d066882b..00000000000 --- a/tests/integration/tests/custom-projects/reuse-coverage-reports/pom.xml +++ /dev/null @@ -1,55 +0,0 @@ - - 4.0.0 - org.sonar.tests - reuse-coverage-reports - 1.0-SNAPSHOT - jar - [SONAR-415] reuse-coverage-reports - see http://jira.codehaus.org/browse/SONAR-415 - - - - org.apache.maven.plugins - maven-compiler-plugin - - 1.5 - 1.5 - - - - - org.codehaus.mojo - cobertura-maven-plugin - 2.3 - - - xml - - - - - - cobertura - - package - - - - - - - - reuseReports - - - - - - junit - junit - 4.4 - test - - - \ No newline at end of file diff --git a/tests/integration/tests/custom-projects/reuse-coverage-reports/src/main/java/org/sonar/tests/Hello.java b/tests/integration/tests/custom-projects/reuse-coverage-reports/src/main/java/org/sonar/tests/Hello.java deleted file mode 100644 index 33ad2d055a2..00000000000 --- a/tests/integration/tests/custom-projects/reuse-coverage-reports/src/main/java/org/sonar/tests/Hello.java +++ /dev/null @@ -1,19 +0,0 @@ -package org.sonar.tests; - -public class Hello { - private String hello; - - public Hello(String s){ - this.hello = s; - } - - public String say() { - return hello; - } - - protected int notCalled() { - int i=0; - i++; - return i+3; - } -} diff --git a/tests/integration/tests/custom-projects/reuse-coverage-reports/src/test/java/org/sonar/tests/HelloTest.java b/tests/integration/tests/custom-projects/reuse-coverage-reports/src/test/java/org/sonar/tests/HelloTest.java deleted file mode 100644 index f268c714b46..00000000000 --- a/tests/integration/tests/custom-projects/reuse-coverage-reports/src/test/java/org/sonar/tests/HelloTest.java +++ /dev/null @@ -1,19 +0,0 @@ -package org.sonar.tests; - -import static org.junit.Assert.assertEquals; -import static org.junit.Assert.fail; -import org.junit.Test; - - -public class HelloTest { - - @Test - public void shouldSayHello() { - assertEquals("hi", new Hello("hi").say()); - } - - @Test - public void shouldNotFail() { - assertEquals(true, true); - } -} diff --git a/tests/integration/tests/custom-projects/timemachine/pom.xml b/tests/integration/tests/custom-projects/timemachine/pom.xml deleted file mode 100644 index fe723981f18..00000000000 --- a/tests/integration/tests/custom-projects/timemachine/pom.xml +++ /dev/null @@ -1,9 +0,0 @@ - - 4.0.0 - org.sonar.tests - timemachine - 1.0-SNAPSHOT - jar - Sonar tests - time machine - Sonar integration tests - time machine - \ No newline at end of file diff --git a/tests/integration/tests/custom-projects/timemachine/src/main/java/org/sonar/tests/timemachine/Hello.java b/tests/integration/tests/custom-projects/timemachine/src/main/java/org/sonar/tests/timemachine/Hello.java deleted file mode 100644 index f28489baaa3..00000000000 --- a/tests/integration/tests/custom-projects/timemachine/src/main/java/org/sonar/tests/timemachine/Hello.java +++ /dev/null @@ -1,19 +0,0 @@ - -package org.sonar.tests.timemachine; - -public class Hello { - - protected void methodOne() { - int i = 0; - i++; - } - - protected void methodTwo() { - int i = 0; - i++; - } - - protected int methodReturnThree() { - return 3; - } -} \ No newline at end of file diff --git a/tests/integration/tests/custom-projects/violations-timemachine/README.txt b/tests/integration/tests/custom-projects/violations-timemachine/README.txt deleted file mode 100644 index 23df016b9db..00000000000 --- a/tests/integration/tests/custom-projects/violations-timemachine/README.txt +++ /dev/null @@ -1,4 +0,0 @@ -Use-cases to check: -* File added -* File removed -* File with new/fixed violations diff --git a/tests/integration/tests/custom-projects/violations-timemachine/v1/pom.xml b/tests/integration/tests/custom-projects/violations-timemachine/v1/pom.xml deleted file mode 100644 index 3d8995b11f3..00000000000 --- a/tests/integration/tests/custom-projects/violations-timemachine/v1/pom.xml +++ /dev/null @@ -1,26 +0,0 @@ - - 4.0.0 - org.sonar.tests - violations-timemachine - 1.0-SNAPSHOT - jar - Violations timemachine - - - - org.apache.maven.plugins - maven-compiler-plugin - - 1.5 - 1.5 - - - - - - - violations-timemachine - 2010-10-19 - - diff --git a/tests/integration/tests/custom-projects/violations-timemachine/v1/src/main/java/org/sonar/tests/violationstimemachine/FileRemovedInV2.java b/tests/integration/tests/custom-projects/violations-timemachine/v1/src/main/java/org/sonar/tests/violationstimemachine/FileRemovedInV2.java deleted file mode 100644 index 6666868b5c8..00000000000 --- a/tests/integration/tests/custom-projects/violations-timemachine/v1/src/main/java/org/sonar/tests/violationstimemachine/FileRemovedInV2.java +++ /dev/null @@ -1,10 +0,0 @@ -package org.sonar.tests.violationstimemachine; - -public class FileRemovedInV2 { - - protected void methodOne() { - int i = 0; // unused local variable - i++; - } - -} diff --git a/tests/integration/tests/custom-projects/violations-timemachine/v1/src/main/java/org/sonar/tests/violationstimemachine/Hello.java b/tests/integration/tests/custom-projects/violations-timemachine/v1/src/main/java/org/sonar/tests/violationstimemachine/Hello.java deleted file mode 100644 index 4bbc1fc2ec1..00000000000 --- a/tests/integration/tests/custom-projects/violations-timemachine/v1/src/main/java/org/sonar/tests/violationstimemachine/Hello.java +++ /dev/null @@ -1,20 +0,0 @@ -package org.sonar.tests.violationstimemachine; - -public class Hello { - - // We need two similar violations here to check that they would be associated correctly - - protected void methodOne() { // design for extension - int i = 0; // unused local variable - i++; - } - - protected void methodTwo() { // design for extension - int i = 0; // unused local variable - i++; - } - - public int methodReturnThree() { // design for extension - return 3; - } -} diff --git a/tests/integration/tests/custom-projects/violations-timemachine/v2/pom.xml b/tests/integration/tests/custom-projects/violations-timemachine/v2/pom.xml deleted file mode 100644 index d61f9471aae..00000000000 --- a/tests/integration/tests/custom-projects/violations-timemachine/v2/pom.xml +++ /dev/null @@ -1,26 +0,0 @@ - - 4.0.0 - org.sonar.tests - violations-timemachine - 1.0-SNAPSHOT - jar - Violations timemachine - - - - org.apache.maven.plugins - maven-compiler-plugin - - 1.5 - 1.5 - - - - - - - violations-timemachine - 2010-11-13 - - diff --git a/tests/integration/tests/custom-projects/violations-timemachine/v2/src/main/java/org/sonar/tests/violationstimemachine/FileAddedInV2.java b/tests/integration/tests/custom-projects/violations-timemachine/v2/src/main/java/org/sonar/tests/violationstimemachine/FileAddedInV2.java deleted file mode 100644 index 0d6026331ab..00000000000 --- a/tests/integration/tests/custom-projects/violations-timemachine/v2/src/main/java/org/sonar/tests/violationstimemachine/FileAddedInV2.java +++ /dev/null @@ -1,10 +0,0 @@ -package org.sonar.tests.violationstimemachine; - -public class FileAddedInV2 { - - protected void methodOne() { // design for extension - int i = 0; // unused local variable - i++; - } - -} diff --git a/tests/integration/tests/custom-projects/violations-timemachine/v2/src/main/java/org/sonar/tests/violationstimemachine/Hello.java b/tests/integration/tests/custom-projects/violations-timemachine/v2/src/main/java/org/sonar/tests/violationstimemachine/Hello.java deleted file mode 100644 index c3c8e1c8bcb..00000000000 --- a/tests/integration/tests/custom-projects/violations-timemachine/v2/src/main/java/org/sonar/tests/violationstimemachine/Hello.java +++ /dev/null @@ -1,21 +0,0 @@ -package org.sonar.tests.violationstimemachine; - -public class Hello { - - // We need two similar violations here to check that they would be associated correctly - - protected void methodOne() { // design for extension - int i = 0; // unused local variable - i++; - } - - protected void methodTwo() { // design for extension - int i = 0; // unused local variable - i++; - } - - public final int methodReturnThree() { // fixed - design for extension - int j = 0; // new - unused local variable - return 3; - } -} diff --git a/tests/integration/tests/custom-projects/violations-timemachine/v2/src/main/java/org/sonar/tests/violationstimemachine/SecondFileAddedInV2.java b/tests/integration/tests/custom-projects/violations-timemachine/v2/src/main/java/org/sonar/tests/violationstimemachine/SecondFileAddedInV2.java deleted file mode 100644 index bddd7f0c346..00000000000 --- a/tests/integration/tests/custom-projects/violations-timemachine/v2/src/main/java/org/sonar/tests/violationstimemachine/SecondFileAddedInV2.java +++ /dev/null @@ -1,10 +0,0 @@ -package org.sonar.tests.violationstimemachine; - -public class SecondFileAddedInV2 { - - public void hasOneViolation() { - int i = 0; // unused local variable - i++; - } - -} diff --git a/tests/integration/tests/integration-tests-backup.xml b/tests/integration/tests/integration-tests-backup.xml deleted file mode 100644 index 820563ab954..00000000000 --- a/tests/integration/tests/integration-tests-backup.xml +++ /dev/null @@ -1,2025 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - turbo - false - true - java - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ]]> - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/tests/integration/tests/maven-projects/SONAR-1074-commented-code/pom.xml b/tests/integration/tests/maven-projects/SONAR-1074-commented-code/pom.xml deleted file mode 100644 index 689a7a13e80..00000000000 --- a/tests/integration/tests/maven-projects/SONAR-1074-commented-code/pom.xml +++ /dev/null @@ -1,22 +0,0 @@ - - 4.0.0 - org.sonar.tests - commented-code - jar - 1.0-SNAPSHOT - commented-code - Commented code - - - - org.apache.maven.plugins - maven-compiler-plugin - - 1.5 - 1.5 - - - - - \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/SONAR-1074-commented-code/src/main/java/com/test/CommentedCode.java b/tests/integration/tests/maven-projects/SONAR-1074-commented-code/src/main/java/com/test/CommentedCode.java deleted file mode 100644 index cb543d85ed1..00000000000 --- a/tests/integration/tests/maven-projects/SONAR-1074-commented-code/src/main/java/com/test/CommentedCode.java +++ /dev/null @@ -1,28 +0,0 @@ -package com.test; - -import java.io.PrintWriter; - -/** - * Commented Code - */ -public class CommentedCode { - - public void test(PrintWriter pw) { - System.out.println("this code is not commented"); - } - - //public void test1(PrintWriter pw) { - // System.out.println("this code seems to be commented"); - //} - - /*public void test1(PrintWriter pw) { - System.out.println("this code seems also to be commented"); - }*/ - - /** - * public boolean test2(PrintWriter pw) { - * System.out.println("this code is not considered as commented"); - * return true; - * } - */ -} \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/SONAR-1772/pom.xml b/tests/integration/tests/maven-projects/SONAR-1772/pom.xml deleted file mode 100644 index 40993ba0d57..00000000000 --- a/tests/integration/tests/maven-projects/SONAR-1772/pom.xml +++ /dev/null @@ -1,26 +0,0 @@ - - 4.0.0 - org.sonar.tests - findbugs - 1.0-SNAPSHOT - jar - [SONAR-1772] - see http://jira.codehaus.org/browse/SONAR-1772 - - - - - org.apache.maven.plugins - maven-compiler-plugin - - 1.5 - 1.5 - - - - - - - SONAR-1772 - - diff --git a/tests/integration/tests/maven-projects/SONAR-1772/src/main/java/org/sonar/tests/Hello.java b/tests/integration/tests/maven-projects/SONAR-1772/src/main/java/org/sonar/tests/Hello.java deleted file mode 100644 index 4591cf3649a..00000000000 --- a/tests/integration/tests/maven-projects/SONAR-1772/src/main/java/org/sonar/tests/Hello.java +++ /dev/null @@ -1,17 +0,0 @@ -package org.sonar.tests; - -import java.io.IOException; -import java.io.LineNumberReader; -import java.io.Reader; - -public final class Hello { - private final LineNumberReader reader; - - public Hello(Reader r) { - this.reader = new LineNumberReader(r); - } - - public String[] readTokens() throws IOException { - return reader.readLine().split("\\|"); // Dodgy - Dereference of the result of readLine() without nullcheck - } -} diff --git a/tests/integration/tests/maven-projects/SONAR-594-no-violations/pom.xml b/tests/integration/tests/maven-projects/SONAR-594-no-violations/pom.xml deleted file mode 100644 index f2797264d32..00000000000 --- a/tests/integration/tests/maven-projects/SONAR-594-no-violations/pom.xml +++ /dev/null @@ -1,13 +0,0 @@ - - 4.0.0 - org.sonar.tests - SONAR-594-no-violations - 1.0-SNAPSHOT - jar - SONAR-594 no violations - - - SONAR-594-no-violations - - - \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/SONAR-594-no-violations/src/main/java/org/sonar/tests/Hello.java b/tests/integration/tests/maven-projects/SONAR-594-no-violations/src/main/java/org/sonar/tests/Hello.java deleted file mode 100644 index e762b8f3654..00000000000 --- a/tests/integration/tests/maven-projects/SONAR-594-no-violations/src/main/java/org/sonar/tests/Hello.java +++ /dev/null @@ -1,13 +0,0 @@ -package org.sonar.tests; - -public class Hello { - private String hello; - - public Hello(String s){ - this.hello = s; - } - - public String say() { - return hello; - } -} diff --git a/tests/integration/tests/maven-projects/SONAR-767-pmd-close-resource-rule/pom.xml b/tests/integration/tests/maven-projects/SONAR-767-pmd-close-resource-rule/pom.xml deleted file mode 100644 index 0e439f28d1d..00000000000 --- a/tests/integration/tests/maven-projects/SONAR-767-pmd-close-resource-rule/pom.xml +++ /dev/null @@ -1,13 +0,0 @@ - - 4.0.0 - org.sonar.tests - SONAR-767-pmd-close-resource-rule - 1.0-SNAPSHOT - jar - SONAR-767-pmd-close-resource-rule - - - SONAR-767-pmd-close-resource-rule - - - \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/SONAR-767-pmd-close-resource-rule/src/main/java/org/sonar/tests/CloseableResource.java b/tests/integration/tests/maven-projects/SONAR-767-pmd-close-resource-rule/src/main/java/org/sonar/tests/CloseableResource.java deleted file mode 100644 index 61455ae5cfe..00000000000 --- a/tests/integration/tests/maven-projects/SONAR-767-pmd-close-resource-rule/src/main/java/org/sonar/tests/CloseableResource.java +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Sonar, open source software quality management tool. - * Copyright (C) 2008-2011 SonarSource - * mailto:contact AT sonarsource DOT com - * - * Sonar is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 3 of the License, or (at your option) any later version. - * - * Sonar is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with Sonar; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02 - */ -package org.sonar.tests; - -public class CloseableResource { - public void init() { - - } - - public void close() { - - } -} diff --git a/tests/integration/tests/maven-projects/SONAR-767-pmd-close-resource-rule/src/main/java/org/sonar/tests/ConnectionIsClosed.java b/tests/integration/tests/maven-projects/SONAR-767-pmd-close-resource-rule/src/main/java/org/sonar/tests/ConnectionIsClosed.java deleted file mode 100644 index 7a2af0171f8..00000000000 --- a/tests/integration/tests/maven-projects/SONAR-767-pmd-close-resource-rule/src/main/java/org/sonar/tests/ConnectionIsClosed.java +++ /dev/null @@ -1,21 +0,0 @@ -package org.sonar.tests; - -import java.sql.Connection; - -public class ConnectionIsClosed { - - public void connectionIsClosed() throws Exception { - Connection c = getConnection(); - try { - // do stuff - c.commit(); - - } finally { - c.close(); - } - } - - protected Connection getConnection() { - return null; - } -} diff --git a/tests/integration/tests/maven-projects/SONAR-767-pmd-close-resource-rule/src/main/java/org/sonar/tests/ConnectionIsClosedInOtherMethod.java b/tests/integration/tests/maven-projects/SONAR-767-pmd-close-resource-rule/src/main/java/org/sonar/tests/ConnectionIsClosedInOtherMethod.java deleted file mode 100644 index 62e663da06f..00000000000 --- a/tests/integration/tests/maven-projects/SONAR-767-pmd-close-resource-rule/src/main/java/org/sonar/tests/ConnectionIsClosedInOtherMethod.java +++ /dev/null @@ -1,50 +0,0 @@ -/* - * Sonar, open source software quality management tool. - * Copyright (C) 2008-2011 SonarSource - * mailto:contact AT sonarsource DOT com - * - * Sonar is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 3 of the License, or (at your option) any later version. - * - * Sonar is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with Sonar; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02 - */ -package org.sonar.tests; - -import java.sql.Connection; -import java.sql.SQLException; - -public class ConnectionIsClosedInOtherMethod { - - public void connectionIsClosedInOtherMethod() throws Exception { - Connection c = getConnection(); - try { - // do stuff - c.commit(); - - } finally { - closeSilently(c); - } - } - - protected Connection getConnection() { - return null; - } - - protected void closeSilently(Connection c) { - try { - c.close(); - } catch (SQLException e) { - // nothing to do - } - } - -} diff --git a/tests/integration/tests/maven-projects/SONAR-767-pmd-close-resource-rule/src/main/java/org/sonar/tests/ConnectionIsNotClosed.java b/tests/integration/tests/maven-projects/SONAR-767-pmd-close-resource-rule/src/main/java/org/sonar/tests/ConnectionIsNotClosed.java deleted file mode 100644 index 39d1d64e560..00000000000 --- a/tests/integration/tests/maven-projects/SONAR-767-pmd-close-resource-rule/src/main/java/org/sonar/tests/ConnectionIsNotClosed.java +++ /dev/null @@ -1,20 +0,0 @@ -package org.sonar.tests; - -import java.sql.Connection; - -public class ConnectionIsNotClosed { - public void connectionIsNotClosed() throws Exception { - Connection c = getConnection(); - try { - // do stuff - c.commit(); - - } finally { - // c.close(); - } - } - - protected Connection getConnection() { - return null; - } -} diff --git a/tests/integration/tests/maven-projects/SONAR-767-pmd-close-resource-rule/src/main/java/org/sonar/tests/ResourceIsClosed.java b/tests/integration/tests/maven-projects/SONAR-767-pmd-close-resource-rule/src/main/java/org/sonar/tests/ResourceIsClosed.java deleted file mode 100644 index f07140c96b5..00000000000 --- a/tests/integration/tests/maven-projects/SONAR-767-pmd-close-resource-rule/src/main/java/org/sonar/tests/ResourceIsClosed.java +++ /dev/null @@ -1,14 +0,0 @@ -package org.sonar.tests; - -public class ResourceIsClosed { - - public void resourceIsStopped() throws Exception { - CloseableResource resource = new CloseableResource(); - try { - resource.init(); - - } finally { - resource.close(); - } - } -} diff --git a/tests/integration/tests/maven-projects/SONAR-767-pmd-close-resource-rule/src/main/java/org/sonar/tests/ResourceIsClosedInOtherMethod.java b/tests/integration/tests/maven-projects/SONAR-767-pmd-close-resource-rule/src/main/java/org/sonar/tests/ResourceIsClosedInOtherMethod.java deleted file mode 100644 index a0736b2c8d0..00000000000 --- a/tests/integration/tests/maven-projects/SONAR-767-pmd-close-resource-rule/src/main/java/org/sonar/tests/ResourceIsClosedInOtherMethod.java +++ /dev/null @@ -1,45 +0,0 @@ -/* - * Sonar, open source software quality management tool. - * Copyright (C) 2008-2011 SonarSource - * mailto:contact AT sonarsource DOT com - * - * Sonar is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 3 of the License, or (at your option) any later version. - * - * Sonar is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with Sonar; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02 - */ -package org.sonar.tests; - - -public class ResourceIsClosedInOtherMethod { - - public void resourceIsClosedInOtherMethod() { - CloseableResource resource = new CloseableResource(); - try { - // do stuff - resource.init(); - - } finally { - closeSilently(resource); - } - } - - - protected void closeSilently(CloseableResource resource) { - try { - resource.close(); - } catch (Exception e) { - // nothing to do - } - } - -} diff --git a/tests/integration/tests/maven-projects/SONAR-767-pmd-close-resource-rule/src/main/java/org/sonar/tests/ResourceIsNotClosed.java b/tests/integration/tests/maven-projects/SONAR-767-pmd-close-resource-rule/src/main/java/org/sonar/tests/ResourceIsNotClosed.java deleted file mode 100644 index 46438061712..00000000000 --- a/tests/integration/tests/maven-projects/SONAR-767-pmd-close-resource-rule/src/main/java/org/sonar/tests/ResourceIsNotClosed.java +++ /dev/null @@ -1,14 +0,0 @@ -package org.sonar.tests; - -public class ResourceIsNotClosed { - - public void resourceIsNotStopped() throws Exception { - CloseableResource resource = new CloseableResource(); - try { - resource.init(); - - } finally { - //resource.stop(); - } - } -} diff --git a/tests/integration/tests/maven-projects/SONAR-787-checkstyle-SuppressionCommentFilter/pom.xml b/tests/integration/tests/maven-projects/SONAR-787-checkstyle-SuppressionCommentFilter/pom.xml deleted file mode 100644 index 2848c47ba38..00000000000 --- a/tests/integration/tests/maven-projects/SONAR-787-checkstyle-SuppressionCommentFilter/pom.xml +++ /dev/null @@ -1,13 +0,0 @@ - - 4.0.0 - org.sonar.tests - SONAR-787-checkstyle-SuppressionCommentFilter - 1.0-SNAPSHOT - jar - SONAR-787-checkstyle-SuppressionCommentFilter - - - SONAR-787-checkstyle-SuppressionCommentFilter - - \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/SONAR-787-checkstyle-SuppressionCommentFilter/src/main/java/org/sonar/itests/IgnoreCheckstyleFalsePositives.java b/tests/integration/tests/maven-projects/SONAR-787-checkstyle-SuppressionCommentFilter/src/main/java/org/sonar/itests/IgnoreCheckstyleFalsePositives.java deleted file mode 100644 index 5a4e64988b8..00000000000 --- a/tests/integration/tests/maven-projects/SONAR-787-checkstyle-SuppressionCommentFilter/src/main/java/org/sonar/itests/IgnoreCheckstyleFalsePositives.java +++ /dev/null @@ -1,20 +0,0 @@ -package org.sonar.tests; - -public class IgnoreCheckstyleFalsePositives { - - public void ignoreFalsePositive(){ - //CHECKSTYLE:OFF - try { - int i=2; - } catch (Exception e) { - } - //CHECKSTYLE:ON - } - - public void ruleIsViolated(){ - try { - int i=2; - } catch (Exception e) { - } - } -} diff --git a/tests/integration/tests/maven-projects/branch/pom.xml b/tests/integration/tests/maven-projects/branch/pom.xml deleted file mode 100644 index 89638e1e831..00000000000 --- a/tests/integration/tests/maven-projects/branch/pom.xml +++ /dev/null @@ -1,13 +0,0 @@ - - 4.0.0 - org.sonar.tests - reference - 0.9-SNAPSHOT - jar - Sonar tests - reference - - - BRANCH-0.9 - - \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/branch/src/main/java/org/sonar/tests/reference/HelloSwiss.java b/tests/integration/tests/maven-projects/branch/src/main/java/org/sonar/tests/reference/HelloSwiss.java deleted file mode 100644 index 2ac386ea5eb..00000000000 --- a/tests/integration/tests/maven-projects/branch/src/main/java/org/sonar/tests/reference/HelloSwiss.java +++ /dev/null @@ -1,9 +0,0 @@ -package org.sonar.tests.reference; - -public interface HelloSwiss { - - void doSomething(); - - void doSomethingElse(); - -} diff --git a/tests/integration/tests/maven-projects/branch/src/main/java/org/sonar/tests/reference/HelloWorld.java b/tests/integration/tests/maven-projects/branch/src/main/java/org/sonar/tests/reference/HelloWorld.java deleted file mode 100644 index a079f69234c..00000000000 --- a/tests/integration/tests/maven-projects/branch/src/main/java/org/sonar/tests/reference/HelloWorld.java +++ /dev/null @@ -1,12 +0,0 @@ -package org.sonar.tests.reference; - -public class HelloWorld { - - public void hello() { - - } - - public Object clone() { - return null; - } -} diff --git a/tests/integration/tests/maven-projects/clover2-skip/module1/pom.xml b/tests/integration/tests/maven-projects/clover2-skip/module1/pom.xml deleted file mode 100644 index 937e8263823..00000000000 --- a/tests/integration/tests/maven-projects/clover2-skip/module1/pom.xml +++ /dev/null @@ -1,23 +0,0 @@ - - 4.0.0 - - org.sonar.tests.clover2skip - parent - 1.0-SNAPSHOT - - module1-skip - module1-skip - - - - com.atlassian.maven.plugins - maven-clover2-plugin - - ${basedir}/src/test/clover/clover2.license - true - - - - - \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/clover2-skip/module1/src/main/java/org/sonar/tests/clover2/module1/Hello.java b/tests/integration/tests/maven-projects/clover2-skip/module1/src/main/java/org/sonar/tests/clover2/module1/Hello.java deleted file mode 100644 index 845746edfb1..00000000000 --- a/tests/integration/tests/maven-projects/clover2-skip/module1/src/main/java/org/sonar/tests/clover2/module1/Hello.java +++ /dev/null @@ -1,13 +0,0 @@ -package org.sonar.tests.clover2.module1; - -public class Hello { - private String hello; - - public Hello(String s){ - this.hello = s; - } - - public String say() { - return hello; - } -} diff --git a/tests/integration/tests/maven-projects/clover2-skip/module1/src/main/java/org/sonar/tests/clover2/module1/MyInterface.java b/tests/integration/tests/maven-projects/clover2-skip/module1/src/main/java/org/sonar/tests/clover2/module1/MyInterface.java deleted file mode 100644 index 431a32034ec..00000000000 --- a/tests/integration/tests/maven-projects/clover2-skip/module1/src/main/java/org/sonar/tests/clover2/module1/MyInterface.java +++ /dev/null @@ -1,5 +0,0 @@ -package org.sonar.tests.clover2.module1; - -public interface MyInterface { - void myMethod(); -} diff --git a/tests/integration/tests/maven-projects/clover2-skip/module1/src/main/java/org/sonar/tests/clover2/module1/NotTestedClass.java b/tests/integration/tests/maven-projects/clover2-skip/module1/src/main/java/org/sonar/tests/clover2/module1/NotTestedClass.java deleted file mode 100644 index c12c6f6ff34..00000000000 --- a/tests/integration/tests/maven-projects/clover2-skip/module1/src/main/java/org/sonar/tests/clover2/module1/NotTestedClass.java +++ /dev/null @@ -1,17 +0,0 @@ -package org.sonar.tests.clover2.module1; - -public class NotTestedClass { - private String hello; - - public NotTestedClass(String s){ - this.hello = s; - } - - public String say() { - return hello; - } - - public String hello() { - return hello; - } -} diff --git a/tests/integration/tests/maven-projects/clover2-skip/module1/src/test/java/org/sonar/tests/clover2/module1/HelloTest.java b/tests/integration/tests/maven-projects/clover2-skip/module1/src/test/java/org/sonar/tests/clover2/module1/HelloTest.java deleted file mode 100644 index fe422a3b08d..00000000000 --- a/tests/integration/tests/maven-projects/clover2-skip/module1/src/test/java/org/sonar/tests/clover2/module1/HelloTest.java +++ /dev/null @@ -1,39 +0,0 @@ -package org.sonar.tests.clover2.module1; - -import static org.junit.Assert.assertEquals; -import static org.junit.Assert.fail; -import org.junit.Test; - - -public class HelloTest { - - @Test - public void shouldSayHello() { - assertEquals("hi", new Hello("hi").say()); - } - - @Test - public void thisIsError() { - assertEquals("foo", "bar"); - } - - @Test - public void thisIsFailure() { - throw new RuntimeException(); - } - - @Test - public void anotherTest() { - assertEquals("hi", new Hello("hi").say()); - } - - @Test - public void again() { - assertEquals("hi", new Hello("hi").say()); - } - - @Test - public void thelast() { - assertEquals("hi", new Hello("hi").say()); - } -} diff --git a/tests/integration/tests/maven-projects/clover2-skip/module2/pom.xml b/tests/integration/tests/maven-projects/clover2-skip/module2/pom.xml deleted file mode 100644 index a6fdd1f5356..00000000000 --- a/tests/integration/tests/maven-projects/clover2-skip/module2/pom.xml +++ /dev/null @@ -1,14 +0,0 @@ - - 4.0.0 - - org.sonar.tests.clover2skip - parent - 1.0-SNAPSHOT - - module2-skip - module2-skip - - true - - \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/clover2-skip/module2/src/main/java/org/sonar/tests/clover2/module2/Hello.java b/tests/integration/tests/maven-projects/clover2-skip/module2/src/main/java/org/sonar/tests/clover2/module2/Hello.java deleted file mode 100644 index f7a21d1559a..00000000000 --- a/tests/integration/tests/maven-projects/clover2-skip/module2/src/main/java/org/sonar/tests/clover2/module2/Hello.java +++ /dev/null @@ -1,13 +0,0 @@ -package org.sonar.tests.clover2.module2; - -public class Hello { - private String hello; - - public Hello(String s){ - this.hello = s; - } - - public String say() { - return hello; - } -} diff --git a/tests/integration/tests/maven-projects/clover2-skip/module2/src/main/java/org/sonar/tests/clover2/module2/NotTestedClass.java b/tests/integration/tests/maven-projects/clover2-skip/module2/src/main/java/org/sonar/tests/clover2/module2/NotTestedClass.java deleted file mode 100644 index 96c63955851..00000000000 --- a/tests/integration/tests/maven-projects/clover2-skip/module2/src/main/java/org/sonar/tests/clover2/module2/NotTestedClass.java +++ /dev/null @@ -1,17 +0,0 @@ -package org.sonar.tests.clover2.module2; - -public class NotTestedClass { - private String hello; - - public NotTestedClass(String s){ - this.hello = s; - } - - public String say() { - return hello; - } - - public String hello() { - return hello; - } -} diff --git a/tests/integration/tests/maven-projects/clover2-skip/module2/src/test/java/org/sonar/tests/clover2/module2/HelloTest.java b/tests/integration/tests/maven-projects/clover2-skip/module2/src/test/java/org/sonar/tests/clover2/module2/HelloTest.java deleted file mode 100644 index 5872fbb93d7..00000000000 --- a/tests/integration/tests/maven-projects/clover2-skip/module2/src/test/java/org/sonar/tests/clover2/module2/HelloTest.java +++ /dev/null @@ -1,39 +0,0 @@ -package org.sonar.tests.clover2.module2; - -import static org.junit.Assert.assertEquals; -import static org.junit.Assert.fail; -import org.junit.Test; - - -public class HelloTest { - - @Test - public void shouldSayHello() { - assertEquals("hi", new Hello("hi").say()); - } - - @Test - public void thisIsError() { - assertEquals("foo", "bar"); - } - - @Test - public void thisIsFailure() { - throw new RuntimeException(); - } - - @Test - public void anotherTest() { - assertEquals("hi", new Hello("hi").say()); - } - - @Test - public void again() { - assertEquals("hi", new Hello("hi").say()); - } - - @Test - public void thelast() { - assertEquals("hi", new Hello("hi").say()); - } -} diff --git a/tests/integration/tests/maven-projects/clover2-skip/pom.xml b/tests/integration/tests/maven-projects/clover2-skip/pom.xml deleted file mode 100644 index 8cab2c587bf..00000000000 --- a/tests/integration/tests/maven-projects/clover2-skip/pom.xml +++ /dev/null @@ -1,54 +0,0 @@ - - 4.0.0 - org.sonar.tests.clover2skip - parent - 1.0-SNAPSHOT - pom - Sonar tests - clover2 skip - foo - - module1 - module2 - - - - - - org.apache.maven.plugins - maven-compiler-plugin - - 1.5 - 1.5 - - - - com.atlassian.maven.plugins - maven-clover2-plugin - 2.6.3 - - JBJk2Ke7ZrTZvmO00u366sv9IY - rqqMuWRPpRNNRompPqrtwqnoPpMoqqprMrVVvVXXVtVppQ - RrnmqmUUnorrvrtommmmmUUnorrvrtommmmmUUJlkXoUUn - mmmm]]> - - - - - - - - - junit - junit - 4.4 - test - - - - - turbo - clover - - \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/clover2/module1/pom.xml b/tests/integration/tests/maven-projects/clover2/module1/pom.xml deleted file mode 100644 index 3a078a899a5..00000000000 --- a/tests/integration/tests/maven-projects/clover2/module1/pom.xml +++ /dev/null @@ -1,11 +0,0 @@ - - 4.0.0 - - org.sonar.tests.clover2 - parent - 1.0-SNAPSHOT - - module1 - module1 - \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/clover2/module1/src/main/java/org/sonar/tests/clover2/module1/Hello.java b/tests/integration/tests/maven-projects/clover2/module1/src/main/java/org/sonar/tests/clover2/module1/Hello.java deleted file mode 100644 index 845746edfb1..00000000000 --- a/tests/integration/tests/maven-projects/clover2/module1/src/main/java/org/sonar/tests/clover2/module1/Hello.java +++ /dev/null @@ -1,13 +0,0 @@ -package org.sonar.tests.clover2.module1; - -public class Hello { - private String hello; - - public Hello(String s){ - this.hello = s; - } - - public String say() { - return hello; - } -} diff --git a/tests/integration/tests/maven-projects/clover2/module1/src/main/java/org/sonar/tests/clover2/module1/MyInterface.java b/tests/integration/tests/maven-projects/clover2/module1/src/main/java/org/sonar/tests/clover2/module1/MyInterface.java deleted file mode 100644 index 431a32034ec..00000000000 --- a/tests/integration/tests/maven-projects/clover2/module1/src/main/java/org/sonar/tests/clover2/module1/MyInterface.java +++ /dev/null @@ -1,5 +0,0 @@ -package org.sonar.tests.clover2.module1; - -public interface MyInterface { - void myMethod(); -} diff --git a/tests/integration/tests/maven-projects/clover2/module1/src/main/java/org/sonar/tests/clover2/module1/NotTestedClass.java b/tests/integration/tests/maven-projects/clover2/module1/src/main/java/org/sonar/tests/clover2/module1/NotTestedClass.java deleted file mode 100644 index c12c6f6ff34..00000000000 --- a/tests/integration/tests/maven-projects/clover2/module1/src/main/java/org/sonar/tests/clover2/module1/NotTestedClass.java +++ /dev/null @@ -1,17 +0,0 @@ -package org.sonar.tests.clover2.module1; - -public class NotTestedClass { - private String hello; - - public NotTestedClass(String s){ - this.hello = s; - } - - public String say() { - return hello; - } - - public String hello() { - return hello; - } -} diff --git a/tests/integration/tests/maven-projects/clover2/module1/src/test/java/org/sonar/tests/clover2/module1/HelloTest.java b/tests/integration/tests/maven-projects/clover2/module1/src/test/java/org/sonar/tests/clover2/module1/HelloTest.java deleted file mode 100644 index fe422a3b08d..00000000000 --- a/tests/integration/tests/maven-projects/clover2/module1/src/test/java/org/sonar/tests/clover2/module1/HelloTest.java +++ /dev/null @@ -1,39 +0,0 @@ -package org.sonar.tests.clover2.module1; - -import static org.junit.Assert.assertEquals; -import static org.junit.Assert.fail; -import org.junit.Test; - - -public class HelloTest { - - @Test - public void shouldSayHello() { - assertEquals("hi", new Hello("hi").say()); - } - - @Test - public void thisIsError() { - assertEquals("foo", "bar"); - } - - @Test - public void thisIsFailure() { - throw new RuntimeException(); - } - - @Test - public void anotherTest() { - assertEquals("hi", new Hello("hi").say()); - } - - @Test - public void again() { - assertEquals("hi", new Hello("hi").say()); - } - - @Test - public void thelast() { - assertEquals("hi", new Hello("hi").say()); - } -} diff --git a/tests/integration/tests/maven-projects/clover2/module2/pom.xml b/tests/integration/tests/maven-projects/clover2/module2/pom.xml deleted file mode 100644 index 20c7e16c0ce..00000000000 --- a/tests/integration/tests/maven-projects/clover2/module2/pom.xml +++ /dev/null @@ -1,11 +0,0 @@ - - 4.0.0 - - org.sonar.tests.clover2 - parent - 1.0-SNAPSHOT - - module2 - module2 - \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/clover2/module2/src/main/java/org/sonar/tests/clover2/module2/Hello.java b/tests/integration/tests/maven-projects/clover2/module2/src/main/java/org/sonar/tests/clover2/module2/Hello.java deleted file mode 100644 index f7a21d1559a..00000000000 --- a/tests/integration/tests/maven-projects/clover2/module2/src/main/java/org/sonar/tests/clover2/module2/Hello.java +++ /dev/null @@ -1,13 +0,0 @@ -package org.sonar.tests.clover2.module2; - -public class Hello { - private String hello; - - public Hello(String s){ - this.hello = s; - } - - public String say() { - return hello; - } -} diff --git a/tests/integration/tests/maven-projects/clover2/module2/src/main/java/org/sonar/tests/clover2/module2/NotTestedClass.java b/tests/integration/tests/maven-projects/clover2/module2/src/main/java/org/sonar/tests/clover2/module2/NotTestedClass.java deleted file mode 100644 index 96c63955851..00000000000 --- a/tests/integration/tests/maven-projects/clover2/module2/src/main/java/org/sonar/tests/clover2/module2/NotTestedClass.java +++ /dev/null @@ -1,17 +0,0 @@ -package org.sonar.tests.clover2.module2; - -public class NotTestedClass { - private String hello; - - public NotTestedClass(String s){ - this.hello = s; - } - - public String say() { - return hello; - } - - public String hello() { - return hello; - } -} diff --git a/tests/integration/tests/maven-projects/clover2/module2/src/test/java/org/sonar/tests/clover2/module2/HelloTest.java b/tests/integration/tests/maven-projects/clover2/module2/src/test/java/org/sonar/tests/clover2/module2/HelloTest.java deleted file mode 100644 index 5872fbb93d7..00000000000 --- a/tests/integration/tests/maven-projects/clover2/module2/src/test/java/org/sonar/tests/clover2/module2/HelloTest.java +++ /dev/null @@ -1,39 +0,0 @@ -package org.sonar.tests.clover2.module2; - -import static org.junit.Assert.assertEquals; -import static org.junit.Assert.fail; -import org.junit.Test; - - -public class HelloTest { - - @Test - public void shouldSayHello() { - assertEquals("hi", new Hello("hi").say()); - } - - @Test - public void thisIsError() { - assertEquals("foo", "bar"); - } - - @Test - public void thisIsFailure() { - throw new RuntimeException(); - } - - @Test - public void anotherTest() { - assertEquals("hi", new Hello("hi").say()); - } - - @Test - public void again() { - assertEquals("hi", new Hello("hi").say()); - } - - @Test - public void thelast() { - assertEquals("hi", new Hello("hi").say()); - } -} diff --git a/tests/integration/tests/maven-projects/clover2/pom.xml b/tests/integration/tests/maven-projects/clover2/pom.xml deleted file mode 100644 index a6e37723216..00000000000 --- a/tests/integration/tests/maven-projects/clover2/pom.xml +++ /dev/null @@ -1,55 +0,0 @@ - - 4.0.0 - org.sonar.tests.clover2 - parent - 1.0-SNAPSHOT - pom - Sonar tests - clover2 - foo - - module1 - module2 - - - - - - org.apache.maven.plugins - maven-compiler-plugin - - 1.5 - 1.5 - - - - - com.atlassian.maven.plugins - maven-clover2-plugin - 2.6.3 - - JBJk2Ke7ZrTZvmO00u366sv9IY - rqqMuWRPpRNNRompPqrtwqnoPpMoqqprMrVVvVXXVtVppQ - RrnmqmUUnorrvrtommmmmUUnorrvrtommmmmUUJlkXoUUn - mmmm]]> - - - - - - - - - junit - junit - 4.7 - test - - - - - turbo - clover - - \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/clover3/module1/pom.xml b/tests/integration/tests/maven-projects/clover3/module1/pom.xml deleted file mode 100644 index 364c03faebf..00000000000 --- a/tests/integration/tests/maven-projects/clover3/module1/pom.xml +++ /dev/null @@ -1,11 +0,0 @@ - - 4.0.0 - - org.sonar.tests.clover3 - parent - 1.0-SNAPSHOT - - module1 - module1 - \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/clover3/module1/src/main/java/org/sonar/tests/clover3/module1/Hello.java b/tests/integration/tests/maven-projects/clover3/module1/src/main/java/org/sonar/tests/clover3/module1/Hello.java deleted file mode 100644 index 6f43534df7e..00000000000 --- a/tests/integration/tests/maven-projects/clover3/module1/src/main/java/org/sonar/tests/clover3/module1/Hello.java +++ /dev/null @@ -1,13 +0,0 @@ -package org.sonar.tests.clover3.module1; - -public class Hello { - private String hello; - - public Hello(String s){ - this.hello = s; - } - - public String say() { - return hello; - } -} diff --git a/tests/integration/tests/maven-projects/clover3/module1/src/main/java/org/sonar/tests/clover3/module1/MyInterface.java b/tests/integration/tests/maven-projects/clover3/module1/src/main/java/org/sonar/tests/clover3/module1/MyInterface.java deleted file mode 100644 index e48174fd88c..00000000000 --- a/tests/integration/tests/maven-projects/clover3/module1/src/main/java/org/sonar/tests/clover3/module1/MyInterface.java +++ /dev/null @@ -1,5 +0,0 @@ -package org.sonar.tests.clover3.module1; - -public interface MyInterface { - void myMethod(); -} diff --git a/tests/integration/tests/maven-projects/clover3/module1/src/main/java/org/sonar/tests/clover3/module1/NotTestedClass.java b/tests/integration/tests/maven-projects/clover3/module1/src/main/java/org/sonar/tests/clover3/module1/NotTestedClass.java deleted file mode 100644 index 4d022b99d8c..00000000000 --- a/tests/integration/tests/maven-projects/clover3/module1/src/main/java/org/sonar/tests/clover3/module1/NotTestedClass.java +++ /dev/null @@ -1,17 +0,0 @@ -package org.sonar.tests.clover3.module1; - -public class NotTestedClass { - private String hello; - - public NotTestedClass(String s){ - this.hello = s; - } - - public String say() { - return hello; - } - - public String hello() { - return hello; - } -} diff --git a/tests/integration/tests/maven-projects/clover3/module1/src/test/java/org/sonar/tests/clover3/module1/HelloTest.java b/tests/integration/tests/maven-projects/clover3/module1/src/test/java/org/sonar/tests/clover3/module1/HelloTest.java deleted file mode 100644 index 7ba00f712d2..00000000000 --- a/tests/integration/tests/maven-projects/clover3/module1/src/test/java/org/sonar/tests/clover3/module1/HelloTest.java +++ /dev/null @@ -1,39 +0,0 @@ -package org.sonar.tests.clover3.module1; - -import static org.junit.Assert.assertEquals; -import static org.junit.Assert.fail; -import org.junit.Test; - - -public class HelloTest { - - @Test - public void shouldSayHello() { - assertEquals("hi", new Hello("hi").say()); - } - - @Test - public void thisIsError() { - assertEquals("foo", "bar"); - } - - @Test - public void thisIsFailure() { - throw new RuntimeException(); - } - - @Test - public void anotherTest() { - assertEquals("hi", new Hello("hi").say()); - } - - @Test - public void again() { - assertEquals("hi", new Hello("hi").say()); - } - - @Test - public void thelast() { - assertEquals("hi", new Hello("hi").say()); - } -} diff --git a/tests/integration/tests/maven-projects/clover3/module2/pom.xml b/tests/integration/tests/maven-projects/clover3/module2/pom.xml deleted file mode 100644 index 5f6cc8877e7..00000000000 --- a/tests/integration/tests/maven-projects/clover3/module2/pom.xml +++ /dev/null @@ -1,11 +0,0 @@ - - 4.0.0 - - org.sonar.tests.clover3 - parent - 1.0-SNAPSHOT - - module2 - module2 - \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/clover3/module2/src/main/java/org/sonar/tests/clover3/module2/Hello.java b/tests/integration/tests/maven-projects/clover3/module2/src/main/java/org/sonar/tests/clover3/module2/Hello.java deleted file mode 100644 index 697a5108d41..00000000000 --- a/tests/integration/tests/maven-projects/clover3/module2/src/main/java/org/sonar/tests/clover3/module2/Hello.java +++ /dev/null @@ -1,13 +0,0 @@ -package org.sonar.tests.clover3.module2; - -public class Hello { - private String hello; - - public Hello(String s){ - this.hello = s; - } - - public String say() { - return hello; - } -} diff --git a/tests/integration/tests/maven-projects/clover3/module2/src/main/java/org/sonar/tests/clover3/module2/NotTestedClass.java b/tests/integration/tests/maven-projects/clover3/module2/src/main/java/org/sonar/tests/clover3/module2/NotTestedClass.java deleted file mode 100644 index a6b4f96cf33..00000000000 --- a/tests/integration/tests/maven-projects/clover3/module2/src/main/java/org/sonar/tests/clover3/module2/NotTestedClass.java +++ /dev/null @@ -1,17 +0,0 @@ -package org.sonar.tests.clover3.module2; - -public class NotTestedClass { - private String hello; - - public NotTestedClass(String s){ - this.hello = s; - } - - public String say() { - return hello; - } - - public String hello() { - return hello; - } -} diff --git a/tests/integration/tests/maven-projects/clover3/module2/src/test/java/org/sonar/tests/clover3/module2/HelloTest.java b/tests/integration/tests/maven-projects/clover3/module2/src/test/java/org/sonar/tests/clover3/module2/HelloTest.java deleted file mode 100644 index bff1f32e4cc..00000000000 --- a/tests/integration/tests/maven-projects/clover3/module2/src/test/java/org/sonar/tests/clover3/module2/HelloTest.java +++ /dev/null @@ -1,39 +0,0 @@ -package org.sonar.tests.clover3.module2; - -import static org.junit.Assert.assertEquals; -import static org.junit.Assert.fail; -import org.junit.Test; - - -public class HelloTest { - - @Test - public void shouldSayHello() { - assertEquals("hi", new Hello("hi").say()); - } - - @Test - public void thisIsError() { - assertEquals("foo", "bar"); - } - - @Test - public void thisIsFailure() { - throw new RuntimeException(); - } - - @Test - public void anotherTest() { - assertEquals("hi", new Hello("hi").say()); - } - - @Test - public void again() { - assertEquals("hi", new Hello("hi").say()); - } - - @Test - public void thelast() { - assertEquals("hi", new Hello("hi").say()); - } -} diff --git a/tests/integration/tests/maven-projects/clover3/pom.xml b/tests/integration/tests/maven-projects/clover3/pom.xml deleted file mode 100644 index 613459fa750..00000000000 --- a/tests/integration/tests/maven-projects/clover3/pom.xml +++ /dev/null @@ -1,55 +0,0 @@ - - 4.0.0 - org.sonar.tests.clover3 - parent - 1.0-SNAPSHOT - pom - Sonar tests - clover3 - foo - - module1 - module2 - - - - - - org.apache.maven.plugins - maven-compiler-plugin - - 1.5 - 1.5 - - - - - com.atlassian.maven.plugins - maven-clover2-plugin - 3.0.1 - - JBJk2Ke7ZrTZvmO00u366sv9IY - rqqMuWRPpRNNRompPqrtwqnoPpMoqqprMrVVvVXXVtVppQ - RrnmqmUUnorrvrtommmmmUUnorrvrtommmmmUUJlkXoUUn - mmmm]]> - - - - - - - - - junit - junit - 4.7 - test - - - - - turbo - clover - - \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/do-not-import-sources/pom.xml b/tests/integration/tests/maven-projects/do-not-import-sources/pom.xml deleted file mode 100644 index 4cf8f137fcd..00000000000 --- a/tests/integration/tests/maven-projects/do-not-import-sources/pom.xml +++ /dev/null @@ -1,11 +0,0 @@ - - 4.0.0 - org.sonar.tests - do-not-import-sources - 1.0-SNAPSHOT - jar - Sonar tests - do not import sources - - false - - \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/do-not-import-sources/src/main/java/org/sonar/tests/doNotImportSources/Hello.java b/tests/integration/tests/maven-projects/do-not-import-sources/src/main/java/org/sonar/tests/doNotImportSources/Hello.java deleted file mode 100644 index fcb329f873d..00000000000 --- a/tests/integration/tests/maven-projects/do-not-import-sources/src/main/java/org/sonar/tests/doNotImportSources/Hello.java +++ /dev/null @@ -1,9 +0,0 @@ -package org.sonar.tests.doNotImportSources; - -public interface Hello { - - void doSomething(); - - void doSomethingElse(); - -} diff --git a/tests/integration/tests/maven-projects/do-not-import-sources/src/main/java/org/sonar/tests/doNotImportSources/Swiss.java b/tests/integration/tests/maven-projects/do-not-import-sources/src/main/java/org/sonar/tests/doNotImportSources/Swiss.java deleted file mode 100644 index 30e5f424117..00000000000 --- a/tests/integration/tests/maven-projects/do-not-import-sources/src/main/java/org/sonar/tests/doNotImportSources/Swiss.java +++ /dev/null @@ -1,15 +0,0 @@ -package org.sonar.tests.doNotImportSources; - -public class Swiss { - String test = "foo"; - - public Swiss(){ - String t; - if (true) - t = "bar"; - } - - public boolean equals(Object o) { - return false; - } -} diff --git a/tests/integration/tests/maven-projects/duplications/pom.xml b/tests/integration/tests/maven-projects/duplications/pom.xml deleted file mode 100644 index f54fa5b51db..00000000000 --- a/tests/integration/tests/maven-projects/duplications/pom.xml +++ /dev/null @@ -1,74 +0,0 @@ - - 4.0.0 - org.sonar.tests - duplications - 1.0-SNAPSHOT - jar - Sonar tests - duplications - Sonar integration tests - duplications project - http://foo/bar - - - turbo - - - - - geronimo-spec - geronimo-spec-jta - 1.0-M1 - - - org.hibernate - hibernate - 3.2.6.ga - - - - javax.transaction - jta - - - - commons-logging - commons-logging - - - - - org.hibernate - hibernate-annotations - 3.3.0.ga - - - org.hibernate - hibernate-commons-annotations - 3.3.0.ga - - - org.hibernate - hibernate-entitymanager - 3.3.1.ga - - - junit - junit - 4.4 - test - - - - - - - org.apache.maven.plugins - maven-compiler-plugin - - 1.5 - 1.5 - - - - - \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/duplications/src/main/java/org/sonar/samples/duplicated_lines_with_other_package1/DuplicatedLinesWithOtherPackage.java b/tests/integration/tests/maven-projects/duplications/src/main/java/org/sonar/samples/duplicated_lines_with_other_package1/DuplicatedLinesWithOtherPackage.java deleted file mode 100644 index 73efdd038bc..00000000000 --- a/tests/integration/tests/maven-projects/duplications/src/main/java/org/sonar/samples/duplicated_lines_with_other_package1/DuplicatedLinesWithOtherPackage.java +++ /dev/null @@ -1,60 +0,0 @@ -/* - * Sonar, entreprise quality control tool. - * Copyright (C) 2007-2008 Hortis-GRC SA - * mailto:be_agile HAT hortis DOT ch - * - * Sonar is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 3 of the License, or (at your option) any later version. - * - * Sonar is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with Sonar; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02 - */ -package org.sonar.samples.duplicated_lines_with_other_package1; - -public class DuplicatedLinesWithOtherPackage { - - public DuplicatedLinesWithOtherPackage() { - } - - public void duplicatedMethodWithOtherPackage() { - char[] charList = new char[30]; - charList[0] = 'a'; - charList[1] = 'b'; - charList[2] = 'c'; - charList[3] = 'd'; - charList[4] = 'e'; - charList[5] = 'f'; - charList[6] = 'g'; - charList[7] = 'g'; - charList[8] = 'g'; - charList[9] = 'g'; - charList[10] = 'g'; - charList[11] = 'g'; - charList[12] = 'g'; - charList[13] = 'g'; - charList[14] = 'g'; - charList[15] = 'g'; - charList[16] = 'g'; - charList[17] = 'g'; - charList[18] = 'g'; - charList[19] = 'g'; - charList[20] = 'g'; - charList[21] = 'g'; - charList[22] = 'g'; - charList[23] = 'g'; - charList[24] = 'g'; - charList[27] = 'g'; - charList[28] = 'g'; - charList[29] = 'g'; - charList[30] = 'g'; - } - -} \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/duplications/src/main/java/org/sonar/samples/duplicated_lines_with_other_package2/DuplicatedLinesWithOtherPackage.java b/tests/integration/tests/maven-projects/duplications/src/main/java/org/sonar/samples/duplicated_lines_with_other_package2/DuplicatedLinesWithOtherPackage.java deleted file mode 100644 index dd5f6108917..00000000000 --- a/tests/integration/tests/maven-projects/duplications/src/main/java/org/sonar/samples/duplicated_lines_with_other_package2/DuplicatedLinesWithOtherPackage.java +++ /dev/null @@ -1,60 +0,0 @@ -/* - * Sonar, entreprise quality control tool. - * Copyright (C) 2007-2008 Hortis-GRC SA - * mailto:be_agile HAT hortis DOT ch - * - * Sonar is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 3 of the License, or (at your option) any later version. - * - * Sonar is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with Sonar; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02 - */ -package org.sonar.samples.duplicated_lines_with_other_package2; - -public class DuplicatedLinesWithOtherPackage { - - public DuplicatedLinesWithOtherPackage() { - } - - public void duplicatedMethodWithOtherPackage() { - char[] charList = new char[30]; - charList[0] = 'a'; - charList[1] = 'b'; - charList[2] = 'c'; - charList[3] = 'd'; - charList[4] = 'e'; - charList[5] = 'f'; - charList[6] = 'g'; - charList[7] = 'g'; - charList[8] = 'g'; - charList[9] = 'g'; - charList[10] = 'g'; - charList[11] = 'g'; - charList[12] = 'g'; - charList[13] = 'g'; - charList[14] = 'g'; - charList[15] = 'g'; - charList[16] = 'g'; - charList[17] = 'g'; - charList[18] = 'g'; - charList[19] = 'g'; - charList[20] = 'g'; - charList[21] = 'g'; - charList[22] = 'g'; - charList[23] = 'g'; - charList[24] = 'g'; - charList[27] = 'g'; - charList[28] = 'g'; - charList[29] = 'g'; - charList[30] = 'g'; - } - -} \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/duplications/src/main/java/org/sonar/samples/duplicated_lines_within_package/DuplicatedLinesInSamePackage1.java b/tests/integration/tests/maven-projects/duplications/src/main/java/org/sonar/samples/duplicated_lines_within_package/DuplicatedLinesInSamePackage1.java deleted file mode 100644 index 77cb339ec5b..00000000000 --- a/tests/integration/tests/maven-projects/duplications/src/main/java/org/sonar/samples/duplicated_lines_within_package/DuplicatedLinesInSamePackage1.java +++ /dev/null @@ -1,124 +0,0 @@ -/* - * Sonar, entreprise quality control tool. - * Copyright (C) 2007-2008 Hortis-GRC SA - * mailto:be_agile HAT hortis DOT ch - * - * Sonar is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 3 of the License, or (at your option) any later version. - * - * Sonar is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with Sonar; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02 - */ -package org.sonar.samples.duplicated_lines_within_package; - -public class DuplicatedLinesInSamePackage1 { - - public DuplicatedLinesInSamePackage1() { - } - - /* - * sddfgdfgfg - */ - public void duplicatedMethodInSameClass1() { - int intergerToBeIncremented = 0; - while (intergerToBeIncremented < 100) { - intergerToBeIncremented++; - } - int intergerToBeIncremented2 = 0; - while (intergerToBeIncremented2 < 100) { - intergerToBeIncremented2++; - } - // first - int intergerToBeIncremented3 = 0; - while (intergerToBeIncremented3 < 100) { - intergerToBeIncremented3++; - } - int intergerToBeIncremented4 = 0; - while (intergerToBeIncremented4 < 100) { - intergerToBeIncremented4++; - } - int intergerToBeIncremented5 = 0; - while (intergerToBeIncremented5 < 100) { - intergerToBeIncremented5++; - } - int intergerToBeIncremented6 = 0; - while (intergerToBeIncremented6 < 100) { - intergerToBeIncremented6++; - } - int intergerToBeIncremented7 = 0; - while (intergerToBeIncremented7 < 100) { - intergerToBeIncremented7++; - } - } - - - public void duplicatedMethodInSameClass3() { - int intergerToBeIncremented = 0; - while (intergerToBeIncremented < 100) { - intergerToBeIncremented++; - } - // test2 - int intergerToBeIncremented2 = 0; - while (intergerToBeIncremented2 < 100) { - intergerToBeIncremented2++; - } - int intergerToBeIncremented8 = 0; - while (intergerToBeIncremented8 < 100) { - intergerToBeIncremented8++; - } - int intergerToBeIncremented9 = 0; - while (intergerToBeIncremented9 < 100) { - intergerToBeIncremented9++; - } - // test 1 - int intergerToBeIncremented10 = 0; - while (intergerToBeIncremented10 < 100) { - intergerToBeIncremented10++; - } - int intergerToBeIncremented60 = 0; - while (intergerToBeIncremented60 < 100) { - intergerToBeIncremented60++; - } - int intergerToBeIncremented70 = 0; - while (intergerToBeIncremented70 < 100) { - intergerToBeIncremented70++; - } - } - - public void duplicated2MethodInSameClass3() { - System.out.print("copy test start"); - int intergerToBeIncremented1 = 0; - while (intergerToBeIncremented1 < 100) { - intergerToBeIncremented1++; - } - int intergerToBeIncremented20 = 0; - while (intergerToBeIncremented20 < 100) { - intergerToBeIncremented20++; - } - int intergerToBeIncremented8 = 0; - while (intergerToBeIncremented8 < 100) { - intergerToBeIncremented8++; - } - int intergerToBeIncremented9 = 0; - while (intergerToBeIncremented9 < 100) { - intergerToBeIncremented9++; - } - int intergerToBeIncremented10 = 0; - while (intergerToBeIncremented10 < 100) { - intergerToBeIncremented10++; - } - int intergerToBeIncremented60 = 0; - while (intergerToBeIncremented60 < 100) { - intergerToBeIncremented60++; - } - System.out.print("copy test end"); - } -} \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/duplications/src/main/java/org/sonar/samples/duplicated_lines_within_package/DuplicatedLinesInSamePackage2.java b/tests/integration/tests/maven-projects/duplications/src/main/java/org/sonar/samples/duplicated_lines_within_package/DuplicatedLinesInSamePackage2.java deleted file mode 100644 index 30b8db6f4db..00000000000 --- a/tests/integration/tests/maven-projects/duplications/src/main/java/org/sonar/samples/duplicated_lines_within_package/DuplicatedLinesInSamePackage2.java +++ /dev/null @@ -1,90 +0,0 @@ -/* - * Sonar, entreprise quality control tool. - * Copyright (C) 2007-2008 Hortis-GRC SA - * mailto:be_agile HAT hortis DOT ch - * - * Sonar is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 3 of the License, or (at your option) any later version. - * - * Sonar is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with Sonar; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02 - */ -package org.sonar.samples.duplicated_lines_within_package; - -public class DuplicatedLinesInSamePackage2 { - - public DuplicatedLinesInSamePackage2() { - } - - public void duplicated2MethodInSameClass3() { - System.out.print("copy test start"); - int intergerToBeIncremented1 = 0; - while (intergerToBeIncremented1 < 100) { - intergerToBeIncremented1++; - } - int intergerToBeIncremented20 = 0; - while (intergerToBeIncremented20 < 100) { - intergerToBeIncremented20++; - } - int intergerToBeIncremented8 = 0; - while (intergerToBeIncremented8 < 100) { - intergerToBeIncremented8++; - } - int intergerToBeIncremented9 = 0; - while (intergerToBeIncremented9 < 100) { - intergerToBeIncremented9++; - } - int intergerToBeIncremented10 = 0; - while (intergerToBeIncremented10 < 100) { - intergerToBeIncremented10++; - } - int intergerToBeIncremented60 = 0; - while (intergerToBeIncremented60 < 100) { - intergerToBeIncremented60++; - } - System.out.print("copy test end"); - } - - public void duplicatedMethodInSameClass1() { - int intergerToBeIncremented = 0; - while (intergerToBeIncremented < 100) { - intergerToBeIncremented++; - } - int intergerToBeIncremented2 = 0; - while (intergerToBeIncremented2 < 100) { - intergerToBeIncremented2++; - } - // second - int intergerToBeIncremented3 = 0; - while (intergerToBeIncremented3 < 100) { - intergerToBeIncremented3++; - } - int intergerToBeIncremented4 = 0; - while (intergerToBeIncremented4 < 100) { - intergerToBeIncremented4++; - } - int intergerToBeIncremented5 = 0; - while (intergerToBeIncremented5 < 100) { - intergerToBeIncremented5++; - } - // vghgvhz - // bhjjh - int intergerToBeIncremented6 = 0; - while (intergerToBeIncremented6 < 100) { - intergerToBeIncremented6++; - } - int intergerToBeIncremented7 = 0; - while (intergerToBeIncremented7 < 100) { - intergerToBeIncremented7++; - } - } - -} \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/duplications/src/main/java/org/sonar/samples/duplicated_lines_within_same_class/DuplicatedLinesInSameClass.java b/tests/integration/tests/maven-projects/duplications/src/main/java/org/sonar/samples/duplicated_lines_within_same_class/DuplicatedLinesInSameClass.java deleted file mode 100644 index 3f57c58a130..00000000000 --- a/tests/integration/tests/maven-projects/duplications/src/main/java/org/sonar/samples/duplicated_lines_within_same_class/DuplicatedLinesInSameClass.java +++ /dev/null @@ -1,89 +0,0 @@ -/* - * Sonar, entreprise quality control tool. - * Copyright (C) 2007-2008 Hortis-GRC SA - * mailto:be_agile HAT hortis DOT ch - * - * Sonar is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 3 of the License, or (at your option) any later version. - * - * Sonar is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with Sonar; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02 - */ -package org.sonar.samples.duplicated_lines_within_same_class; - -public class DuplicatedLinesInSameClass { - - public DuplicatedLinesInSameClass() { - } - - public void duplicatedMethodInSameClass1() { - String temp = ""; - for (int i=0; i<10; i++){ - temp += "say something"+i; - } - for (int i=0; i<20; i++){ - temp += "say nothing"+i; - } - for (int i=0; i<30; i++){ - temp += "always say nothing"+i; - } - for (int i=0; i<40; i++){ - temp += "really nothing to say "+i; - } - for (int i=0; i<50; i++){ - temp += "really really nothing to say "+i; - } - for (int i=0; i<60; i++){ - temp += ".. "+i; - } - for (int i=0; i<70; i++){ - temp += "you say something? "+i; - } - for (int i=0; i<80; i++){ - temp += "ah no..."+i; - } - for (int i=0; i<90; i++){ - temp += "bye"+i; - } - } - - public void duplicatedMethodInSameClass2() { - String temp = ""; - for (int i=0; i<10; i++){ - temp += "say something"+i; - } - for (int i=0; i<20; i++){ - temp += "say nothing"+i; - } - for (int i=0; i<30; i++){ - temp += "always say nothing"+i; - } - for (int i=0; i<40; i++){ - temp += "really nothing to say "+i; - } - for (int i=0; i<50; i++){ - temp += "really really nothing to say "+i; - } - for (int i=0; i<60; i++){ - temp += ".. "+i; - } - for (int i=0; i<70; i++){ - temp += "you say something? "+i; - } - for (int i=0; i<80; i++){ - temp += "ah no..."+i; - } - for (int i=0; i<90; i++){ - temp += "bye"+i; - } - } - -} diff --git a/tests/integration/tests/maven-projects/duplications/src/main/java/org/sonar/samples/duplicated_same_lines_within_3_classes/Class1.java b/tests/integration/tests/maven-projects/duplications/src/main/java/org/sonar/samples/duplicated_same_lines_within_3_classes/Class1.java deleted file mode 100644 index d847f24d8e7..00000000000 --- a/tests/integration/tests/maven-projects/duplications/src/main/java/org/sonar/samples/duplicated_same_lines_within_3_classes/Class1.java +++ /dev/null @@ -1,60 +0,0 @@ -/* - * Sonar, open source software quality management tool. - * Copyright (C) 2008-2011 SonarSource - * mailto:contact AT sonarsource DOT com - * - * Sonar is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 3 of the License, or (at your option) any later version. - * - * Sonar is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with Sonar; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02 - */ -package org.sonar.samples.duplicated_same_lines_within_3_classes; - -public class Class1 { - - public void someMethod() { - System.out.println("Test"); - } - - public void duplicatedMethod() { - int intergerToBeIncremented = 0; - while (intergerToBeIncremented < 100) { - intergerToBeIncremented++; - } - System.out.println("test"); - int intergerToBeIncremented3 = 0; - while (intergerToBeIncremented3 < 100) { - intergerToBeIncremented3++; - } - System.out.println("test"); - int intergerToBeIncremented4 = 0; - while (intergerToBeIncremented4 < 100) { - intergerToBeIncremented4++; - } - System.out.println("test"); - int intergerToBeIncremented5 = 0; - while (intergerToBeIncremented5 < 100) { - intergerToBeIncremented5++; - } - System.out.println("test"); - int intergerToBeIncremented6 = 0; - while (intergerToBeIncremented6 < 100) { - intergerToBeIncremented6++; - } - System.out.println("test"); - int intergerToBeIncremented7 = 0; - while (intergerToBeIncremented7 < 100) { - intergerToBeIncremented7++; - } - } - -} diff --git a/tests/integration/tests/maven-projects/duplications/src/main/java/org/sonar/samples/duplicated_same_lines_within_3_classes/Class2.java b/tests/integration/tests/maven-projects/duplications/src/main/java/org/sonar/samples/duplicated_same_lines_within_3_classes/Class2.java deleted file mode 100644 index 28ae766f163..00000000000 --- a/tests/integration/tests/maven-projects/duplications/src/main/java/org/sonar/samples/duplicated_same_lines_within_3_classes/Class2.java +++ /dev/null @@ -1,59 +0,0 @@ -/* - * Sonar, open source software quality management tool. - * Copyright (C) 2008-2011 SonarSource - * mailto:contact AT sonarsource DOT com - * - * Sonar is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 3 of the License, or (at your option) any later version. - * - * Sonar is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with Sonar; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02 - */ -package org.sonar.samples.duplicated_same_lines_within_3_classes; - -public class Class2 { - - public void duplicatedMethod() { - int intergerToBeIncremented = 0; - while (intergerToBeIncremented < 100) { - intergerToBeIncremented++; - } - System.out.println("test"); - int intergerToBeIncremented3 = 0; - while (intergerToBeIncremented3 < 100) { - intergerToBeIncremented3++; - } - System.out.println("test"); - int intergerToBeIncremented4 = 0; - while (intergerToBeIncremented4 < 100) { - intergerToBeIncremented4++; - } - System.out.println("test"); - int intergerToBeIncremented5 = 0; - while (intergerToBeIncremented5 < 100) { - intergerToBeIncremented5++; - } - System.out.println("test"); - int intergerToBeIncremented6 = 0; - while (intergerToBeIncremented6 < 100) { - intergerToBeIncremented6++; - } - System.out.println("test"); - int intergerToBeIncremented7 = 0; - while (intergerToBeIncremented7 < 100) { - intergerToBeIncremented7++; - } - } - - public void someOtherMethod() { - System.out.println("Test2"); - } -} diff --git a/tests/integration/tests/maven-projects/duplications/src/main/java/org/sonar/samples/duplicated_same_lines_within_3_classes/Class3.java b/tests/integration/tests/maven-projects/duplications/src/main/java/org/sonar/samples/duplicated_same_lines_within_3_classes/Class3.java deleted file mode 100644 index 6cb454fdaee..00000000000 --- a/tests/integration/tests/maven-projects/duplications/src/main/java/org/sonar/samples/duplicated_same_lines_within_3_classes/Class3.java +++ /dev/null @@ -1,62 +0,0 @@ -/* - * Sonar, open source software quality management tool. - * Copyright (C) 2008-2011 SonarSource - * mailto:contact AT sonarsource DOT com - * - * Sonar is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 3 of the License, or (at your option) any later version. - * - * Sonar is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with Sonar; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02 - */ -package org.sonar.samples.duplicated_same_lines_within_3_classes; - -public class Class3 { - - private String test; - - public void duplicatedMethod() { - int intergerToBeIncremented = 0; - while (intergerToBeIncremented < 100) { - intergerToBeIncremented++; - } - System.out.println("test"); - int intergerToBeIncremented3 = 0; - while (intergerToBeIncremented3 < 100) { - intergerToBeIncremented3++; - } - System.out.println("test"); - int intergerToBeIncremented4 = 0; - while (intergerToBeIncremented4 < 100) { - intergerToBeIncremented4++; - } - System.out.println("test"); - int intergerToBeIncremented5 = 0; - while (intergerToBeIncremented5 < 100) { - intergerToBeIncremented5++; - } - System.out.println("test"); - int intergerToBeIncremented6 = 0; - while (intergerToBeIncremented6 < 100) { - intergerToBeIncremented6++; - } - System.out.println("test"); - int intergerToBeIncremented7 = 0; - while (intergerToBeIncremented7 < 100) { - intergerToBeIncremented7++; - } - } - - public String getTest() { - return test; - } - -} diff --git a/tests/integration/tests/maven-projects/exclusions/pom.xml b/tests/integration/tests/maven-projects/exclusions/pom.xml deleted file mode 100644 index 76d96dda0d6..00000000000 --- a/tests/integration/tests/maven-projects/exclusions/pom.xml +++ /dev/null @@ -1,34 +0,0 @@ - - 4.0.0 - org.sonar.tests - exclusions - 1.0-SNAPSHOT - jar - exclusions - - - - junit - junit - 4.4 - test - - - - - - - org.apache.maven.plugins - maven-compiler-plugin - - 1.5 - 1.5 - - - - - - - **/*Exclude*.java,org/sonar/tests/packageToExclude/** - - \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/exclusions/src/main/java/ClassOnDefaultPackage.java b/tests/integration/tests/maven-projects/exclusions/src/main/java/ClassOnDefaultPackage.java deleted file mode 100644 index dff4c90b9ba..00000000000 --- a/tests/integration/tests/maven-projects/exclusions/src/main/java/ClassOnDefaultPackage.java +++ /dev/null @@ -1,10 +0,0 @@ -public class ClassOnDefaultPackage { - - public ClassOnDefaultPackage(int i) { - int j = i++; - } - - private String myMethod() { - return "hello"; - } -} diff --git a/tests/integration/tests/maven-projects/exclusions/src/main/java/org/sonar/tests/ClassOne.java b/tests/integration/tests/maven-projects/exclusions/src/main/java/org/sonar/tests/ClassOne.java deleted file mode 100644 index f9de47bea90..00000000000 --- a/tests/integration/tests/maven-projects/exclusions/src/main/java/org/sonar/tests/ClassOne.java +++ /dev/null @@ -1,47 +0,0 @@ -package org.sonar.tests; - -public class ClassOne { - public void toto() throws Exception { - int i=0; - i++; - } - public String hello() { - return "hello"; - } - - protected void duplicatedMethod(int i) { - i++; - int j=10; - if (i==0) { - i=j + 10; - } - if (i==0) { - i=j + 10; - } - if (i==0) { - i=j + 10; - } - if (i==0) { - i=j + 10; - } - if (i==0) { - i=j + 10; - } - if (i==0) { - i=j + 10; - } - if (i==0) { - i=j + 10; - } - if (i==0) { - i=j + 10; - } - if (i==0) { - i=j + 10; - } - if (i==0) { - i=j + 10; - } - System.out.println("i=" + i); - } -} diff --git a/tests/integration/tests/maven-projects/exclusions/src/main/java/org/sonar/tests/ClassToExclude.java b/tests/integration/tests/maven-projects/exclusions/src/main/java/org/sonar/tests/ClassToExclude.java deleted file mode 100644 index 6e7c3f7ba16..00000000000 --- a/tests/integration/tests/maven-projects/exclusions/src/main/java/org/sonar/tests/ClassToExclude.java +++ /dev/null @@ -1,66 +0,0 @@ -package org.sonar.tests; - -/** - * JAVADOC - * ......... - */ -public class ClassToExclude { - String test = "foo"; - String test2 = "bar"; - String test3 = "toto"; - - public ClassToExclude(){ - String t; - if (true) - t = "sonar"; - } - - public static final String method1(String unused) { - if (true) { - return "foo"; - } - if (false) { - return "foooooo"; - } - String loooooooooooooooooooooooooooooooooooooooooooooongVar = "wantsViolations"; - return loooooooooooooooooooooooooooooooooooooooooooooongVar; - } - - protected void duplicatedMethod(int i) { - // commmmmmmments - // foo.............. - i++; - int j=10; - if (i==0) { - i=j + 10; - } - if (i==0) { - i=j + 10; - } - if (i==0) { - i=j + 10; - } - if (i==0) { - i=j + 10; - } - if (i==0) { - i=j + 10; - } - if (i==0) { - i=j + 10; - } - if (i==0) { - i=j + 10; - } - if (i==0) { - i=j + 10; - } - if (i==0) { - i=j + 10; - } - if (i==0) { - i=j + 10; - } - System.out.println("i=" + i); - } -} diff --git a/tests/integration/tests/maven-projects/exclusions/src/main/java/org/sonar/tests/ClassTwo.java b/tests/integration/tests/maven-projects/exclusions/src/main/java/org/sonar/tests/ClassTwo.java deleted file mode 100644 index 809858dce8a..00000000000 --- a/tests/integration/tests/maven-projects/exclusions/src/main/java/org/sonar/tests/ClassTwo.java +++ /dev/null @@ -1,26 +0,0 @@ -package org.sonar.tests; - -import java.lang.String; - -/** - * THE JAVADOC HEADER - */ -public class ClassTwo { - - public ClassTwo(int i) { - // single comment - int j = i++; - myMethod(); - } - - private String myMethod() { - /* - comment - on - many - lines - */ - int toto = 34; // comment at end of line - return "hello"; - } -} diff --git a/tests/integration/tests/maven-projects/exclusions/src/main/java/org/sonar/tests/NoSonarComment.java b/tests/integration/tests/maven-projects/exclusions/src/main/java/org/sonar/tests/NoSonarComment.java deleted file mode 100644 index 206d72ba6ac..00000000000 --- a/tests/integration/tests/maven-projects/exclusions/src/main/java/org/sonar/tests/NoSonarComment.java +++ /dev/null @@ -1,13 +0,0 @@ -package org.sonar.tests; - -import java.lang.String;//NOSONAR - -public class NoSonarComment { - - public NoSonarComment(int i) {//NOSONAR - i=3;// NOSONAR - i=4; // ERROR magic number, parameter assignment - String s="foo"; - if (s=="bar") return; // ERROR: compare Strings with equals() - } -} diff --git a/tests/integration/tests/maven-projects/exclusions/src/main/java/org/sonar/tests/packageToExclude/ClassThree.java b/tests/integration/tests/maven-projects/exclusions/src/main/java/org/sonar/tests/packageToExclude/ClassThree.java deleted file mode 100644 index eef3c947488..00000000000 --- a/tests/integration/tests/maven-projects/exclusions/src/main/java/org/sonar/tests/packageToExclude/ClassThree.java +++ /dev/null @@ -1,26 +0,0 @@ -package org.sonar.tests.packageToExclude; - -import java.lang.String; - -/** - * THE JAVADOC HEADER - */ -public class ClassThree { - - public ClassThree(int i) { - // single comment - int j = i++; - myMethod(); - } - - private String myMethod() { - /* - comment - on - many - lines - */ - int toto = 34; // comment at end of line - return "hello"; - } -} diff --git a/tests/integration/tests/maven-projects/exclusions/src/test/java/org/sonar/tests/ClassOneTest.java b/tests/integration/tests/maven-projects/exclusions/src/test/java/org/sonar/tests/ClassOneTest.java deleted file mode 100644 index 8c0967e496f..00000000000 --- a/tests/integration/tests/maven-projects/exclusions/src/test/java/org/sonar/tests/ClassOneTest.java +++ /dev/null @@ -1,11 +0,0 @@ -package org.sonar.tests; - -import org.junit.Test; - -public class ClassOneTest { - - @Test - public void nothing() { - - } -} diff --git a/tests/integration/tests/maven-projects/exclusions/src/test/java/org/sonar/tests/ClassToExcludeTest.java b/tests/integration/tests/maven-projects/exclusions/src/test/java/org/sonar/tests/ClassToExcludeTest.java deleted file mode 100644 index 712e2ec4a4a..00000000000 --- a/tests/integration/tests/maven-projects/exclusions/src/test/java/org/sonar/tests/ClassToExcludeTest.java +++ /dev/null @@ -1,19 +0,0 @@ -package org.sonar.tests; - -import org.junit.Test; -import static org.junit.Assert.fail; - -public class ClassToExcludeTest { - - @Test - public void increaseCodeCoverage() { - new ClassToExclude().duplicatedMethod(222); - } - - @Test - public void shouldFail() { - if (true) { - fail(); - } - } -} diff --git a/tests/integration/tests/maven-projects/exclusions/src/test/java/org/sonar/tests/ClassTwoTest.java b/tests/integration/tests/maven-projects/exclusions/src/test/java/org/sonar/tests/ClassTwoTest.java deleted file mode 100644 index 4f2aeba813f..00000000000 --- a/tests/integration/tests/maven-projects/exclusions/src/test/java/org/sonar/tests/ClassTwoTest.java +++ /dev/null @@ -1,12 +0,0 @@ -package org.sonar.tests; - -import org.junit.Test; - - -public class ClassTwoTest { - - @Test - public void increaseCodeCoverage() { - new ClassTwo(67); - } -} diff --git a/tests/integration/tests/maven-projects/jar-without-sources/pom.xml b/tests/integration/tests/maven-projects/jar-without-sources/pom.xml deleted file mode 100644 index 76a86915a07..00000000000 --- a/tests/integration/tests/maven-projects/jar-without-sources/pom.xml +++ /dev/null @@ -1,10 +0,0 @@ - - - 4.0.0 - org.sonar.tests - jar-without-sources - jar - 1.0-SNAPSHOT - JAR without sources - \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/java-complexity/pom.xml b/tests/integration/tests/maven-projects/java-complexity/pom.xml deleted file mode 100644 index 63afab1e8ab..00000000000 --- a/tests/integration/tests/maven-projects/java-complexity/pom.xml +++ /dev/null @@ -1,8 +0,0 @@ - - 4.0.0 - org.sonar.tests - java-complexity - 1.0-SNAPSHOT - java-complexity - \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/java-complexity/src/main/java/foo/AnonymousClass.java b/tests/integration/tests/maven-projects/java-complexity/src/main/java/foo/AnonymousClass.java deleted file mode 100644 index 61b755b16c6..00000000000 --- a/tests/integration/tests/maven-projects/java-complexity/src/main/java/foo/AnonymousClass.java +++ /dev/null @@ -1,27 +0,0 @@ -package foo; - -import java.io.Serializable; -import java.lang.Runnable; - -public class AnonymousClass { - - // method complexity: 1 or 3 ? - public void hasComplexAnonymousClass() { - Runnable runnable = new Runnable() { - - // method complexity: 2 - public void run() { - if (true) { - System.out.println("true"); - } - } - }; - } - - // method complexity: 1 - public void hasEmptyAnonymousClass() { - Serializable serializable = new Serializable() { - - }; - } -} \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/java-complexity/src/main/java/foo/ContainsInnerClasses.java b/tests/integration/tests/maven-projects/java-complexity/src/main/java/foo/ContainsInnerClasses.java deleted file mode 100644 index 900e5e5eac1..00000000000 --- a/tests/integration/tests/maven-projects/java-complexity/src/main/java/foo/ContainsInnerClasses.java +++ /dev/null @@ -1,37 +0,0 @@ -package foo; - -// class complexity: 5 -public class ContainsInnerClasses { - - // method complexity: 1 - public ContainsInnerClasses() { - - } - - // class complexity: 3 - public static class InnerClass { - private String field; - - // method complexity: 1 - public InnerClass() { - - } - - // method complexity: 2 - public InnerClass(String s) { - if (s != null) { - field = s; - } - } - } -} - -// class complexity: 1 -class PackageClass { - private String field; - - // method complexity: 1 - public PackageClass() { - - } - } diff --git a/tests/integration/tests/maven-projects/java-complexity/src/main/java/foo/ExcludedByFilter.java b/tests/integration/tests/maven-projects/java-complexity/src/main/java/foo/ExcludedByFilter.java deleted file mode 100644 index b5193444cd6..00000000000 --- a/tests/integration/tests/maven-projects/java-complexity/src/main/java/foo/ExcludedByFilter.java +++ /dev/null @@ -1,19 +0,0 @@ -package foo; - -// this class is excluded by the resource filter defined in sonar-it-reference-plugin -public class ExcludedByFilter { - - public void say() { - int i=0; - if(i>5) { - System.out.println("say something"); - } - } - - public void cry() { - int i=0; - if(i<5) { - System.out.println("cry"); - } - } -} diff --git a/tests/integration/tests/maven-projects/java-complexity/src/main/java/foo/Helloworld.java b/tests/integration/tests/maven-projects/java-complexity/src/main/java/foo/Helloworld.java deleted file mode 100644 index ded87d61848..00000000000 --- a/tests/integration/tests/maven-projects/java-complexity/src/main/java/foo/Helloworld.java +++ /dev/null @@ -1,42 +0,0 @@ -package foo; - -// class complexity: 6 -public class Helloworld { - - private String field = null; - - // this is considered as a method (bug http://jira.codehaus.org/browse/SONAR-2152) - // complexity: 2 - static { - int i = 0; - if (i > 5) { - System.out.println("hello from static block"); - } - } - - // method complexity: 1 - public Helloworld(String s) { - this.field = s; - } - - // accessor - // complexity: 0 - public String getField() { - return field; - } - - // accessor - // complexity: 0 - public void setField(String s) { - this.field = s; - } - - // method complexity: 3 - public void sayHello() { - for (int i = 0; i < 5; i++) { - if (field != null) { - System.out.println(field); - } - } - } -} diff --git a/tests/integration/tests/maven-projects/java-complexity/src/main/java/foo/ZeroComplexity.java b/tests/integration/tests/maven-projects/java-complexity/src/main/java/foo/ZeroComplexity.java deleted file mode 100644 index ee6b3eb25f8..00000000000 --- a/tests/integration/tests/maven-projects/java-complexity/src/main/java/foo/ZeroComplexity.java +++ /dev/null @@ -1,6 +0,0 @@ -package foo; - -// complexity: 0 -public class ZeroComplexity { - -} diff --git a/tests/integration/tests/maven-projects/java-inner-classes/pom.xml b/tests/integration/tests/maven-projects/java-inner-classes/pom.xml deleted file mode 100644 index d3890843ada..00000000000 --- a/tests/integration/tests/maven-projects/java-inner-classes/pom.xml +++ /dev/null @@ -1,30 +0,0 @@ - - 4.0.0 - org.sonar.tests - java-inner-classes - 1.0-SNAPSHOT - Java inner classes - - - - junit - junit - 4.6 - test - - - - - - - org.apache.maven.plugins - maven-compiler-plugin - - 1.5 - 1.5 - - - - - \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/java-inner-classes/src/main/java/WithAnonymousClass.java b/tests/integration/tests/maven-projects/java-inner-classes/src/main/java/WithAnonymousClass.java deleted file mode 100644 index d3df3bcb11c..00000000000 --- a/tests/integration/tests/maven-projects/java-inner-classes/src/main/java/WithAnonymousClass.java +++ /dev/null @@ -1,46 +0,0 @@ -/* - * Sonar, open source software quality management tool. - * Copyright (C) 2008-2011 SonarSource - * mailto:contact AT sonarsource DOT com - * - * Sonar is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 3 of the License, or (at your option) any later version. - * - * Sonar is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with Sonar; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02 - */ - -import java.util.AbstractMap; -import java.util.Set; - -/** - * See http://java.sun.com/docs/books/tutorial/java/javaOO/nested.html - */ -public class WithAnonymousClass { - - public void mainMethod1() { - AbstractMap anonymousMap = new AbstractMap() { - public Set entrySet() { - return null; - } - }; - anonymousMap.entrySet(); - anonymousMap = null; - } - - public void mainMethod2() { - int i = 9999; - i++; - i += 444; - } - - -} \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/java-inner-classes/src/main/java/WithInnerClass.java b/tests/integration/tests/maven-projects/java-inner-classes/src/main/java/WithInnerClass.java deleted file mode 100644 index d9b5ac53391..00000000000 --- a/tests/integration/tests/maven-projects/java-inner-classes/src/main/java/WithInnerClass.java +++ /dev/null @@ -1,42 +0,0 @@ -/* - * Sonar, open source software quality management tool. - * Copyright (C) 2008-2011 SonarSource - * mailto:contact AT sonarsource DOT com - * - * Sonar is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 3 of the License, or (at your option) any later version. - * - * Sonar is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with Sonar; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02 - */ - -/** - * See http://java.sun.com/docs/books/tutorial/java/javaOO/nested.html - */ -public class WithInnerClass { - - public int mainMethod1() { - int i = new InnerClass().innerMethod1(); - i += 3; - return i; - } - - /** - * A non-static nested class is named "inner class" - */ - class InnerClass { - public int innerMethod1() { - int j = 200; - j += 500; - return j; - } - } -} \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/java-inner-classes/src/main/java/WithLocalInnerClass.java b/tests/integration/tests/maven-projects/java-inner-classes/src/main/java/WithLocalInnerClass.java deleted file mode 100644 index c4898ae9752..00000000000 --- a/tests/integration/tests/maven-projects/java-inner-classes/src/main/java/WithLocalInnerClass.java +++ /dev/null @@ -1,42 +0,0 @@ -/* - * Sonar, open source software quality management tool. - * Copyright (C) 2008-2011 SonarSource - * mailto:contact AT sonarsource DOT com - * - * Sonar is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 3 of the License, or (at your option) any later version. - * - * Sonar is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with Sonar; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02 - */ - -public class WithLocalInnerClass { - - public String mainMethod1() { - class LocalInnerClass { - public String staticNestedMethod1() { - String s = "foo"; - return s; - } - } - - String foo = new LocalInnerClass().staticNestedMethod1(); - foo += "xxxxxxxx"; - return foo; - } - - public void mainMethod2() { - int i = 9999; - //do nothing - } - - -} diff --git a/tests/integration/tests/maven-projects/java-inner-classes/src/main/java/WithStaticInnerClass.java b/tests/integration/tests/maven-projects/java-inner-classes/src/main/java/WithStaticInnerClass.java deleted file mode 100644 index 232fdc4444d..00000000000 --- a/tests/integration/tests/maven-projects/java-inner-classes/src/main/java/WithStaticInnerClass.java +++ /dev/null @@ -1,49 +0,0 @@ -/* - * Sonar, open source software quality management tool. - * Copyright (C) 2008-2011 SonarSource - * mailto:contact AT sonarsource DOT com - * - * Sonar is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 3 of the License, or (at your option) any later version. - * - * Sonar is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with Sonar; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02 - */ - -/** - * See http://java.sun.com/docs/books/tutorial/java/javaOO/nested.html - */ -public class WithStaticInnerClass { - public String mainMethod1() { - String foo = new StaticNestedClass().staticNestedMethod1(); - foo += "xxxxxxxx"; - return foo; - } - - public void mainMethod2() { - int i = 9999; - //do nothing - } - - static class StaticNestedClass { - public String staticNestedMethod1() { - String s = "foo"; - return s; - } - } - - public static class PublicStaticNestedClass { - public int publicStaticNestedMethod1() { - String s = "bar"; - return 123456; - } - } -} diff --git a/tests/integration/tests/maven-projects/java-inner-classes/src/main/java/WithSubClass.java b/tests/integration/tests/maven-projects/java-inner-classes/src/main/java/WithSubClass.java deleted file mode 100644 index bd934492c31..00000000000 --- a/tests/integration/tests/maven-projects/java-inner-classes/src/main/java/WithSubClass.java +++ /dev/null @@ -1,46 +0,0 @@ -/* - * Sonar, open source software quality management tool. - * Copyright (C) 2008-2011 SonarSource - * mailto:contact AT sonarsource DOT com - * - * Sonar is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 3 of the License, or (at your option) any later version. - * - * Sonar is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with Sonar; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02 - */ - -public class WithSubClass { - public void mainMethod1() { - String foo = new SubClass1().subMethod(); - foo += "bar"; - } - - public void mainMethod2() { - int i = 9999; - //do nothing - } -} - -class SubClass1 { - public String subMethod() { - String foo = "foo"; - foo += "xxxxxxxx"; - return foo; - } -} - -class SubClass2 { - public void subMethod() { - String foo = "foo"; - foo += "xxxxxxxx"; - } -} diff --git a/tests/integration/tests/maven-projects/java-inner-classes/src/test/java/WithAnonymousClassTest.java b/tests/integration/tests/maven-projects/java-inner-classes/src/test/java/WithAnonymousClassTest.java deleted file mode 100644 index 989740136b1..00000000000 --- a/tests/integration/tests/maven-projects/java-inner-classes/src/test/java/WithAnonymousClassTest.java +++ /dev/null @@ -1,29 +0,0 @@ -/* - * Sonar, open source software quality management tool. - * Copyright (C) 2008-2011 SonarSource - * mailto:contact AT sonarsource DOT com - * - * Sonar is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 3 of the License, or (at your option) any later version. - * - * Sonar is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with Sonar; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02 - */ - -import org.junit.Test; - -public class WithAnonymousClassTest { - - @Test - public void test1() { - new WithAnonymousClass().mainMethod1(); - } -} diff --git a/tests/integration/tests/maven-projects/java-inner-classes/src/test/java/WithInnerClassTest.java b/tests/integration/tests/maven-projects/java-inner-classes/src/test/java/WithInnerClassTest.java deleted file mode 100644 index ccd43d8d9f2..00000000000 --- a/tests/integration/tests/maven-projects/java-inner-classes/src/test/java/WithInnerClassTest.java +++ /dev/null @@ -1,28 +0,0 @@ -/* - * Sonar, open source software quality management tool. - * Copyright (C) 2008-2011 SonarSource - * mailto:contact AT sonarsource DOT com - * - * Sonar is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 3 of the License, or (at your option) any later version. - * - * Sonar is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with Sonar; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02 - */ - -import org.junit.Test; - -public class WithInnerClassTest { - @Test - public void test1() { - new WithInnerClass().mainMethod1(); - } -} diff --git a/tests/integration/tests/maven-projects/java-inner-classes/src/test/java/WithLocalInnerClassTest.java b/tests/integration/tests/maven-projects/java-inner-classes/src/test/java/WithLocalInnerClassTest.java deleted file mode 100644 index c7d2397738c..00000000000 --- a/tests/integration/tests/maven-projects/java-inner-classes/src/test/java/WithLocalInnerClassTest.java +++ /dev/null @@ -1,28 +0,0 @@ -/* - * Sonar, open source software quality management tool. - * Copyright (C) 2008-2011 SonarSource - * mailto:contact AT sonarsource DOT com - * - * Sonar is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 3 of the License, or (at your option) any later version. - * - * Sonar is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with Sonar; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02 - */ - -import org.junit.Test; - -public class WithLocalInnerClassTest { - @Test - public void test1() { - new WithLocalInnerClass().mainMethod1(); - } -} diff --git a/tests/integration/tests/maven-projects/java-inner-classes/src/test/java/WithStaticInnerClassTest.java b/tests/integration/tests/maven-projects/java-inner-classes/src/test/java/WithStaticInnerClassTest.java deleted file mode 100644 index dd134de124c..00000000000 --- a/tests/integration/tests/maven-projects/java-inner-classes/src/test/java/WithStaticInnerClassTest.java +++ /dev/null @@ -1,28 +0,0 @@ -/* - * Sonar, open source software quality management tool. - * Copyright (C) 2008-2011 SonarSource - * mailto:contact AT sonarsource DOT com - * - * Sonar is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 3 of the License, or (at your option) any later version. - * - * Sonar is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with Sonar; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02 - */ - -import org.junit.Test; - -public class WithStaticInnerClassTest { - @Test - public void test1() { - new WithStaticInnerClass().mainMethod1(); - } -} diff --git a/tests/integration/tests/maven-projects/java-inner-classes/src/test/java/WithSubClassTest.java b/tests/integration/tests/maven-projects/java-inner-classes/src/test/java/WithSubClassTest.java deleted file mode 100644 index 46aa3d9194a..00000000000 --- a/tests/integration/tests/maven-projects/java-inner-classes/src/test/java/WithSubClassTest.java +++ /dev/null @@ -1,28 +0,0 @@ -/* - * Sonar, open source software quality management tool. - * Copyright (C) 2008-2011 SonarSource - * mailto:contact AT sonarsource DOT com - * - * Sonar is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 3 of the License, or (at your option) any later version. - * - * Sonar is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with Sonar; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02 - */ - -import org.junit.Test; - -public class WithSubClassTest { - @Test - public void test1() { - new WithSubClass().mainMethod1(); - } -} diff --git a/tests/integration/tests/maven-projects/java4/pom.xml b/tests/integration/tests/maven-projects/java4/pom.xml deleted file mode 100644 index 7931fb22a68..00000000000 --- a/tests/integration/tests/maven-projects/java4/pom.xml +++ /dev/null @@ -1,21 +0,0 @@ - - 4.0.0 - org.sonar.tests - java4 - 1.0-SNAPSHOT - jar - Sonar tests - java4 syntax - - - - - org.apache.maven.plugins - maven-compiler-plugin - - 1.4 - 1.4 - - - - - \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/java4/src/main/java/org/sonar/tests/java4/Java4.java b/tests/integration/tests/maven-projects/java4/src/main/java/org/sonar/tests/java4/Java4.java deleted file mode 100644 index 77ae9665c4c..00000000000 --- a/tests/integration/tests/maven-projects/java4/src/main/java/org/sonar/tests/java4/Java4.java +++ /dev/null @@ -1,9 +0,0 @@ -package org.sonar.tests.java4; - -public class Java4 { - private String enum = null; - - public Java4(String enum){ - this.enum = enum; - } -} diff --git a/tests/integration/tests/maven-projects/jee-sample/ear-module/pom.xml b/tests/integration/tests/maven-projects/jee-sample/ear-module/pom.xml deleted file mode 100644 index 0bb98d61827..00000000000 --- a/tests/integration/tests/maven-projects/jee-sample/ear-module/pom.xml +++ /dev/null @@ -1,66 +0,0 @@ - - - - parent - org.sonar.tests.jee - 1.0-SNAPSHOT - - 4.0.0 - org.sonar.tests.jee - ear-module - ear-module - ear - - - ${project.groupId} - java-module - ${project.version} - jar - - - ${project.groupId} - ejb-module - ${project.version} - ejb - - - ${project.groupId} - web-module - ${project.version} - war - - - junit - junit - 3.8.1 - test - - - - - - - org.apache.maven.plugins - maven-ear-plugin - - - - ${project.groupId} - java-module - - - ${project.groupId} - ejb-module - - - ${project.groupId} - web-module - jee-sample - - - - - - - - \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/jee-sample/ejb-module/pom.xml b/tests/integration/tests/maven-projects/jee-sample/ejb-module/pom.xml deleted file mode 100644 index 3b32e9d4cb2..00000000000 --- a/tests/integration/tests/maven-projects/jee-sample/ejb-module/pom.xml +++ /dev/null @@ -1,35 +0,0 @@ - - - - parent - org.sonar.tests.jee - 1.0-SNAPSHOT - - 4.0.0 - org.sonar.tests.jee - ejb-module - ejb-module - 1.0-SNAPSHOT - ejb - - - org.apache.geronimo.specs - geronimo-ejb_2.1_spec - 1.1 - provided - - - - ${project.groupId} - java-module - ${project.version} - runtime - - - junit - junit - 3.8.1 - test - - - \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/jee-sample/ejb-module/src/main/java/org/sonar/tests/App.java b/tests/integration/tests/maven-projects/jee-sample/ejb-module/src/main/java/org/sonar/tests/App.java deleted file mode 100644 index ddc6d08253b..00000000000 --- a/tests/integration/tests/maven-projects/jee-sample/ejb-module/src/main/java/org/sonar/tests/App.java +++ /dev/null @@ -1,13 +0,0 @@ -package org.sonar.tests; - -/** - * Hello world! - * - */ -public class App -{ - public static void main( String[] args ) - { - System.out.println( "Hello World!" ); - } -} diff --git a/tests/integration/tests/maven-projects/jee-sample/ejb-module/src/main/resources/META-INF/ejb-jar.xml b/tests/integration/tests/maven-projects/jee-sample/ejb-module/src/main/resources/META-INF/ejb-jar.xml deleted file mode 100644 index f97427d26aa..00000000000 --- a/tests/integration/tests/maven-projects/jee-sample/ejb-module/src/main/resources/META-INF/ejb-jar.xml +++ /dev/null @@ -1,13 +0,0 @@ - - - - - - - - - - - diff --git a/tests/integration/tests/maven-projects/jee-sample/ejb-module/src/test/java/org/sonar/tests/AppTest.java b/tests/integration/tests/maven-projects/jee-sample/ejb-module/src/test/java/org/sonar/tests/AppTest.java deleted file mode 100644 index ce03155a801..00000000000 --- a/tests/integration/tests/maven-projects/jee-sample/ejb-module/src/test/java/org/sonar/tests/AppTest.java +++ /dev/null @@ -1,38 +0,0 @@ -package org.sonar.tests; - -import junit.framework.Test; -import junit.framework.TestCase; -import junit.framework.TestSuite; - -/** - * Unit test for simple App. - */ -public class AppTest - extends TestCase -{ - /** - * Create the test case - * - * @param testName name of the test case - */ - public AppTest( String testName ) - { - super( testName ); - } - - /** - * @return the suite of tests being tested - */ - public static Test suite() - { - return new TestSuite( AppTest.class ); - } - - /** - * Rigourous Test :-) - */ - public void testApp() - { - assertTrue( true ); - } -} diff --git a/tests/integration/tests/maven-projects/jee-sample/java-module/pom.xml b/tests/integration/tests/maven-projects/jee-sample/java-module/pom.xml deleted file mode 100644 index ee14f3dc342..00000000000 --- a/tests/integration/tests/maven-projects/jee-sample/java-module/pom.xml +++ /dev/null @@ -1,21 +0,0 @@ - - - - parent - org.sonar.tests.jee - 1.0-SNAPSHOT - - 4.0.0 - org.sonar.tests.jee - java-module - java-module - 1.0-SNAPSHOT - - - junit - junit - 3.8.1 - test - - - \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/jee-sample/java-module/src/main/java/org/sonar/tests/App.java b/tests/integration/tests/maven-projects/jee-sample/java-module/src/main/java/org/sonar/tests/App.java deleted file mode 100644 index ddc6d08253b..00000000000 --- a/tests/integration/tests/maven-projects/jee-sample/java-module/src/main/java/org/sonar/tests/App.java +++ /dev/null @@ -1,13 +0,0 @@ -package org.sonar.tests; - -/** - * Hello world! - * - */ -public class App -{ - public static void main( String[] args ) - { - System.out.println( "Hello World!" ); - } -} diff --git a/tests/integration/tests/maven-projects/jee-sample/java-module/src/test/java/org/sonar/tests/AppTest.java b/tests/integration/tests/maven-projects/jee-sample/java-module/src/test/java/org/sonar/tests/AppTest.java deleted file mode 100644 index ce03155a801..00000000000 --- a/tests/integration/tests/maven-projects/jee-sample/java-module/src/test/java/org/sonar/tests/AppTest.java +++ /dev/null @@ -1,38 +0,0 @@ -package org.sonar.tests; - -import junit.framework.Test; -import junit.framework.TestCase; -import junit.framework.TestSuite; - -/** - * Unit test for simple App. - */ -public class AppTest - extends TestCase -{ - /** - * Create the test case - * - * @param testName name of the test case - */ - public AppTest( String testName ) - { - super( testName ); - } - - /** - * @return the suite of tests being tested - */ - public static Test suite() - { - return new TestSuite( AppTest.class ); - } - - /** - * Rigourous Test :-) - */ - public void testApp() - { - assertTrue( true ); - } -} diff --git a/tests/integration/tests/maven-projects/jee-sample/pom.xml b/tests/integration/tests/maven-projects/jee-sample/pom.xml deleted file mode 100644 index ac56b00af03..00000000000 --- a/tests/integration/tests/maven-projects/jee-sample/pom.xml +++ /dev/null @@ -1,24 +0,0 @@ - - - 4.0.0 - org.sonar.tests.jee - parent - pom - 1.0-SNAPSHOT - JEE sample project - - - junit - junit - 3.8.1 - test - - - - java-module - ejb-module - web-module - ear-module - - \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/jee-sample/web-module/pom.xml b/tests/integration/tests/maven-projects/jee-sample/web-module/pom.xml deleted file mode 100644 index 02f8ab3b203..00000000000 --- a/tests/integration/tests/maven-projects/jee-sample/web-module/pom.xml +++ /dev/null @@ -1,56 +0,0 @@ - - - - parent - org.sonar.tests.jee - 1.0-SNAPSHOT - - 4.0.0 - org.sonar.tests.jee - web-module - war - web-module Maven Webapp - 1.0-SNAPSHOT - - web-module - - - - javax.servlet - servlet-api - 2.4 - provided - - - javax.servlet - jsp-api - 2.0 - provided - - - org.apache.geronimo.specs - geronimo-ejb_2.1_spec - 1.1 - provided - - - ${project.groupId} - java-module - ${project.version} - runtime - - - ${project.groupId} - ejb-module - ${project.version} - runtime - ejb - - - junit - junit - 3.8.1 - test - - - \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/jee-sample/web-module/src/main/webapp/WEB-INF/web.xml b/tests/integration/tests/maven-projects/jee-sample/web-module/src/main/webapp/WEB-INF/web.xml deleted file mode 100644 index 9f88c1f9632..00000000000 --- a/tests/integration/tests/maven-projects/jee-sample/web-module/src/main/webapp/WEB-INF/web.xml +++ /dev/null @@ -1,7 +0,0 @@ - - - - Archetype Created Web Application - diff --git a/tests/integration/tests/maven-projects/jee-sample/web-module/src/main/webapp/index.jsp b/tests/integration/tests/maven-projects/jee-sample/web-module/src/main/webapp/index.jsp deleted file mode 100644 index c38169bb958..00000000000 --- a/tests/integration/tests/maven-projects/jee-sample/web-module/src/main/webapp/index.jsp +++ /dev/null @@ -1,5 +0,0 @@ - - -

Hello World!

- - diff --git a/tests/integration/tests/maven-projects/many-source-dirs/pom.xml b/tests/integration/tests/maven-projects/many-source-dirs/pom.xml deleted file mode 100644 index 7a1839aba4f..00000000000 --- a/tests/integration/tests/maven-projects/many-source-dirs/pom.xml +++ /dev/null @@ -1,67 +0,0 @@ - - 4.0.0 - org.sonar.tests - many-source-dirs - 1.0-SNAPSHOT - jar - many-source-dirs - - - - - org.apache.maven.plugins - maven-compiler-plugin - - 1.5 - 1.5 - - - - - org.codehaus.mojo - build-helper-maven-plugin - LATEST - - - add-source - generate-sources - - add-source - - - - src/main/java2 - - - - - add-test-source - generate-sources - - add-test-source - - - - src/test/java2 - - - - - - - - - - - junit - junit - 4.5 - test - - - - - generate-sources - - \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/many-source-dirs/src/main/java/org/sonar/tests/FirstClass.java b/tests/integration/tests/maven-projects/many-source-dirs/src/main/java/org/sonar/tests/FirstClass.java deleted file mode 100644 index 827a8fb68a7..00000000000 --- a/tests/integration/tests/maven-projects/many-source-dirs/src/main/java/org/sonar/tests/FirstClass.java +++ /dev/null @@ -1,12 +0,0 @@ -package org.sonar.tests; - -public class FirstClass { - - public FirstClass(int i) { - int j = i++; - } - - public String hello() { - return "hello"; - } -} diff --git a/tests/integration/tests/maven-projects/many-source-dirs/src/main/java2/org/sonar/tests/SecondClass.java b/tests/integration/tests/maven-projects/many-source-dirs/src/main/java2/org/sonar/tests/SecondClass.java deleted file mode 100644 index cdcc05c23f0..00000000000 --- a/tests/integration/tests/maven-projects/many-source-dirs/src/main/java2/org/sonar/tests/SecondClass.java +++ /dev/null @@ -1,12 +0,0 @@ -package org.sonar.tests; - -public class SecondClass { - - public SecondClass(int i) { - int j = i++; - } - - public String foo() { - return "hello"; - } -} \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/many-source-dirs/src/test/java/org/sonar/tests/SecondClassTest.java b/tests/integration/tests/maven-projects/many-source-dirs/src/test/java/org/sonar/tests/SecondClassTest.java deleted file mode 100644 index 327a71d2fd8..00000000000 --- a/tests/integration/tests/maven-projects/many-source-dirs/src/test/java/org/sonar/tests/SecondClassTest.java +++ /dev/null @@ -1,17 +0,0 @@ -package org.sonar.tests; - -import org.junit.Test; -import static org.junit.Assert.assertEquals; - -public class SecondClassTest { - - @Test - public void hello() { - assertEquals("hello", new SecondClass(3).foo()); - } - - @Test - public void error() { - assertEquals("no", new SecondClass(3).foo()); - } -} \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/many-source-dirs/src/test/java2/org/sonar/tests/FirstClassTest.java b/tests/integration/tests/maven-projects/many-source-dirs/src/test/java2/org/sonar/tests/FirstClassTest.java deleted file mode 100644 index bb0b9b52e83..00000000000 --- a/tests/integration/tests/maven-projects/many-source-dirs/src/test/java2/org/sonar/tests/FirstClassTest.java +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Sonar, open source software quality management tool. - * Copyright (C) 2008-2011 SonarSource - * mailto:contact AT sonarsource DOT com - * - * Sonar is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 3 of the License, or (at your option) any later version. - * - * Sonar is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with Sonar; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02 - */ -package org.sonar.tests; - -import org.junit.Test; -import static org.junit.Assert.assertEquals; - -public class FirstClassTest { - @Test - public void hello() { - assertEquals("hello", new FirstClass(30).hello()); - } - - @Test - public void error() { - assertEquals("no", new FirstClass(323).hello()); - } -} diff --git a/tests/integration/tests/maven-projects/maven-custom-type/module.properties b/tests/integration/tests/maven-projects/maven-custom-type/module.properties deleted file mode 100644 index 79b5d81ef66..00000000000 --- a/tests/integration/tests/maven-projects/maven-custom-type/module.properties +++ /dev/null @@ -1,47 +0,0 @@ -# Licensed to the Apache Software Foundation (ASF) under one or more -# contributor license agreements. See the NOTICE file distributed with -# this work for additional information regarding copyright ownership. -# The ASF licenses this file to You under the Apache License, Version 2.0 -# (the "License"); you may not use this file except in compliance with -# the License. You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - - - -# SDK Sample module - -# ==== Beginning of Alfresco required/optional properties ====== # - -module.id=${pom.groupId}.${pom.artifactId} -#module.aliases=myModule-123, my-module -module.title=${pom.name} -module.description=${pom.description} -module.version=${pom.version} - -# The following optional properties can be used to prevent the module from being added -# to inappropriate versions of the WAR file. -# module.repo.version.min=2.0 -# module.repo.version.max=2.1 - -# FIXME: This dependencies should come out of mvn dependencies on amp - -# The following describe dependencies on other modules -# Depends on net.sf.myproject.module.SupportModuleA version ${version} or later -# module.depends.net.sf.myproject.module.SupportModuleA=${version}-* -# Depends on net.sf.myproject.module.SupportModuleA version ${version} to 2.0 -# module.depends.net.sf.myproject.module.SupportModuleB=${version}-2.0 -# Depends on net.sf.myproject.module.SupportModuleC - any version -# module.depends.net.sf.myproject.module.SupportModuleB=* - - -# ==== End of Alfresco required/optional properties ======= # - - -# ==== Beginning of module required properties/optional ====== # \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/maven-custom-type/pom.xml b/tests/integration/tests/maven-projects/maven-custom-type/pom.xml deleted file mode 100644 index 30d3ee5fc2e..00000000000 --- a/tests/integration/tests/maven-projects/maven-custom-type/pom.xml +++ /dev/null @@ -1,283 +0,0 @@ - - - - 4.0.0 - org.sonar.tests - maven-custom-type - amp - Maven custom type - 0.1-SNAPSHOT - SONAR-308 Maven custom type - - - ss-public - http://repository.sourcesense.com/nexus/content/groups/public - - - - - ss-public - http://repository.sourcesense.com/nexus/content/groups/public - - - - turbo - - local - mymodule-webapp - ./alf_data_jetty - alf_jetty - error - ${project.build.directory}/ - debug - - - - org.alfresco - alfresco-repository - 2.1.0 - labs - - - org.springframework - spring - 2.0 - provided - - - mysql - mysql-connector-java - 5.0.3 - - - - - - maven-compiler-plugin - - 1.5 - 1.5 - - - - org.alfresco.maven.plugin - maven-amp-plugin - 2.0.1 - true - - - false - - - - - - - - - - - - true - src/main/resources - - **README-* - - - - - true - src/main/config - alfresco/module/mycompany.com.mymodule - - **README-* - - - - - - - - webapp - - src/test/properties/${env}/application.properties - jetty:run-exploded - - - org.apache.maven.plugins - maven-dependency-plugin - - - unpack-amps - process-resources - - unpack-dependencies - - - amp - ${build.directory}/${webapp.name} - META* - - - - - - - org.alfresco.maven.plugin - maven-amp-plugin - 2.0.0 - - - - - org.apache.maven.plugins - maven-war-plugin - - - - it - package - - exploded - - - - - false - - ${build.directory}/${webapp.name} - - false - - licenses/** - - - - ${build.testOutputDirectory} - WEB-INF/classes - true - - ** - - - - - src/main/webapp - WEB-INF/licenses - - licenses/*.* - - false - - - - - - - org.alfresco.maven.plugin - maven-amp-plugin - 2.0.0 - - - - - org.mortbay.jetty - maven-jetty-plugin - - - - it - integration-test - - run-exploded - - - /${webapp.name} - ${pom.build.directory}/${webapp.name} - 10 - - - 8080 - 60000 - - - - - - - - - - - true - src/test/resources - - - - true - src/test/properties/${env} - alfresco/extension - - - - true - . - - module.properties - - alfresco/module/mycompany.com.mymodule - - - - - - - - alfresco.community - alfresco - 2.1.0 - war - - - - - - diff --git a/tests/integration/tests/maven-projects/maven-custom-type/src/main/config/context/service-context.xml b/tests/integration/tests/maven-projects/maven-custom-type/src/main/config/context/service-context.xml deleted file mode 100644 index 78a22ff5586..00000000000 --- a/tests/integration/tests/maven-projects/maven-custom-type/src/main/config/context/service-context.xml +++ /dev/null @@ -1,34 +0,0 @@ - - - - - - - - - - - - - - - - - - diff --git a/tests/integration/tests/maven-projects/maven-custom-type/src/main/config/log4j.properties b/tests/integration/tests/maven-projects/maven-custom-type/src/main/config/log4j.properties deleted file mode 100644 index 960dd90b27e..00000000000 --- a/tests/integration/tests/maven-projects/maven-custom-type/src/main/config/log4j.properties +++ /dev/null @@ -1,41 +0,0 @@ -# Licensed to the Apache Software Foundation (ASF) under one or more -# contributor license agreements. See the NOTICE file distributed with -# this work for additional information regarding copyright ownership. -# The ASF licenses this file to You under the Apache License, Version 2.0 -# (the "License"); you may not use this file except in compliance with -# the License. You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - #----------------------------------------------------------------------- - # ${artifactId} module log4j.properties - # - # NOTE - # ---- - # Log4j uses the following logging levels: - # debug,info,warn,error,fatal - # - # To set the logging level of {fullClassName} to {loglevel}, - # add a line to this file of the following form: - # - # log4j.logger.{fullClassName}={loglevel} - # - # For example, to make 'com.example.MyExample' produce 'debug' - # logs, add a line like this: - # - # log4j.logger.com.example.MyExample=debug - # - # - # WARNING - # ------- - # Log properties in this log4j.properties file override/augment - # those in the webapp's main log4j.properties. - # - #----------------------------------------------------------------------- - - log4j.logger.com.sourcesense.demoamp.DemoComponent=${module.log.level} \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/maven-custom-type/src/main/config/module-context.xml b/tests/integration/tests/maven-projects/maven-custom-type/src/main/config/module-context.xml deleted file mode 100644 index 2421dacb4b5..00000000000 --- a/tests/integration/tests/maven-projects/maven-custom-type/src/main/config/module-context.xml +++ /dev/null @@ -1,25 +0,0 @@ - - - - - - - - - diff --git a/tests/integration/tests/maven-projects/maven-custom-type/src/main/webapp/css/demoamp.css b/tests/integration/tests/maven-projects/maven-custom-type/src/main/webapp/css/demoamp.css deleted file mode 100644 index c24bc1bd4fd..00000000000 --- a/tests/integration/tests/maven-projects/maven-custom-type/src/main/webapp/css/demoamp.css +++ /dev/null @@ -1,16 +0,0 @@ -/* - Licensed to the Apache Software Foundation (ASF) under one or more - contributor license agreements. See the NOTICE file distributed with - this work for additional information regarding copyright ownership. - The ASF licenses this file to You under the Apache License, Version 2.0 - (the "License"); you may not use this file except in compliance with - the License. You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. - */ \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/maven-custom-type/src/main/webapp/images/sourcesense.gif b/tests/integration/tests/maven-projects/maven-custom-type/src/main/webapp/images/sourcesense.gif deleted file mode 100644 index 0b80b9d2049..00000000000 Binary files a/tests/integration/tests/maven-projects/maven-custom-type/src/main/webapp/images/sourcesense.gif and /dev/null differ diff --git a/tests/integration/tests/maven-projects/maven-custom-type/src/main/webapp/jsp/demoamp.jsp b/tests/integration/tests/maven-projects/maven-custom-type/src/main/webapp/jsp/demoamp.jsp deleted file mode 100644 index f442d2ef2a3..00000000000 --- a/tests/integration/tests/maven-projects/maven-custom-type/src/main/webapp/jsp/demoamp.jsp +++ /dev/null @@ -1,16 +0,0 @@ - \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/maven-custom-type/src/main/webapp/licenses/README-licenses.txt b/tests/integration/tests/maven-projects/maven-custom-type/src/main/webapp/licenses/README-licenses.txt deleted file mode 100644 index 2a848d025a0..00000000000 --- a/tests/integration/tests/maven-projects/maven-custom-type/src/main/webapp/licenses/README-licenses.txt +++ /dev/null @@ -1,2 +0,0 @@ -This folder (root in the AMP) gets mapped automagically in WEB-INF/licenses -in the war build \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/maven-custom-type/src/main/webapp/scripts/demoamp.js b/tests/integration/tests/maven-projects/maven-custom-type/src/main/webapp/scripts/demoamp.js deleted file mode 100644 index c24bc1bd4fd..00000000000 --- a/tests/integration/tests/maven-projects/maven-custom-type/src/main/webapp/scripts/demoamp.js +++ /dev/null @@ -1,16 +0,0 @@ -/* - Licensed to the Apache Software Foundation (ASF) under one or more - contributor license agreements. See the NOTICE file distributed with - this work for additional information regarding copyright ownership. - The ASF licenses this file to You under the Apache License, Version 2.0 - (the "License"); you may not use this file except in compliance with - the License. You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. - */ \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/maven-custom-type/src/test/properties/local/application.properties b/tests/integration/tests/maven-projects/maven-custom-type/src/test/properties/local/application.properties deleted file mode 100644 index de4e0a2e9fa..00000000000 --- a/tests/integration/tests/maven-projects/maven-custom-type/src/test/properties/local/application.properties +++ /dev/null @@ -1,139 +0,0 @@ -# Licensed to the Apache Software Foundation (ASF) under one or more -# contributor license agreements. See the NOTICE file distributed with -# this work for additional information regarding copyright ownership. -# The ASF licenses this file to You under the Apache License, Version 2.0 -# (the "License"); you may not use this file except in compliance with -# the License. You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# RUN TIME PROPERTIES -# ------------------- - -# Sample custom content and index data location -# This will create alf_data Relative to appserver run folder -# In this default file we take the property from the POM (for compatbility with local jetty and jboss deployments) but it can also be edited here. -dir.root=${alfresco.data.location} -# Allowed values are: NONE, AUTO, FULL -index.recovery.mode=AUTO - -# Fail or not when there are node integrity checker errors -integrity.failOnError=true - -# database connection properties -# MySQL connection (This is default and requires mysql-connector-java-5.0.3-bin.jar, which ships with the Alfresco server) - -db.driver=org.gjt.mm.mysql.Driver -db.url=jdbc:mysql://localhost/${alfresco.db.name} -db.username=alfresco -db.password=alfresco -db.pool.initial=10 -db.pool.max=100 - -# MySQL dialect -hibernate.dialect=org.hibernate.dialect.MySQLInnoDBDialect - - - - -# Change the following values only if you know what you're doing. -# Default should suffice in most cases when running jetty embedded -# for amp testing - - - - - -# Property to control whether schema updates are performed automatically. -# Updates must be enabled during upgrades as, apart from the static upgrade scripts, -# there are also auto-generated update scripts that will need to be executed. After -# upgrading to a new version, this can be disabled. -#db.schema.update=true - - -# File servers related properties -# For local builds we disable CIFS and FTP. Edit the following property to reenable them -smb.server.enabled=false -smb.server.name=CFS_SHARE_LOCAL -smb.server.domain=mycompany.com -smb.server.bindto=127.0.0.1 -smb.tcpip.port=1445 -netbios.session.port=1139 -netbios.name.port=1137 -netbios.datagram.port=1138 -ftp.server.enabled=false -ftp.port=1121 -ftp.authenticator=alfresco - -# This properties file is used to configure LDAP authentication -# NB: The following LDAP related properties are read only in case -Denteprise mvn build property is specified -# Wheter to allow silent deletion of users in the Alfresco UI (note: users will be then resynced in the next synchronization) -ldap.authentication.allowDeleteUser=true -# LDAP JNDI provider -ldap.authentication.provider=com.sun.jndi.ldap.LdapCtxFactory -# Url and protocol for LDAP server to carry authentication against -ldap.authentication.url=ldap://ldap.mycompany.com:636 -# can be (simple, ssl) -ldap.authentication.protcol=ssl -# Credentials with full access to the directoty used -ldap.authentication.adminUser=ou=Admin,ou=Services,o=Company -ldap.authentication.adminPassword=secret -# Wheter to allow unauthenticated guest a read only login -ldap.authentication.guestLogin.allowed=false -# Wheter users can be created on the fly upon successful external (e.g. LDAP) authentication. Useful to avoid user synchronization in case just uid and pwd are needed for a user -server.transaction.allow-writes=true -# Wheter user names are case sensitive -user.name.caseSensitive=true -# Wheter the synchronization process has to process duplicated users (e.g. synced users and users coming from the sync) -personService.processDuplicates=true -# Which action to take when processin duplicates. One of: LEAVE, SPLIT, DELETE -personService.duplicateMode=DELETE -# Which of the users (in case of SPLIT duplicates policy) should be considered valid -personService.lastIsBest=true -# Wheter auto created users should be considered when processing duplicates -personService.includeAutoCreated=true -# The query to find the people to import -ldap.synchronisation.personQuery=(objectclass=inetOrgPerson) -# The search base of the query to find people to import -ldap.synchronisation.personSearchBase=ou=Identities,ou=mycompany,o=com -# The attribute name on people objects found in LDAP to use as the uid in Alfresco -ldap.synchronisation.userIdAttributeName=cn -# The attribute on person objects in LDAP to map to the first name property in Alfresco -ldap.synchronisation.userFirstNameAttributeName=givenName -# The attribute on person objects in LDAP to map to the last name property in Alfresco -ldap.synchronisation.userLastNameAttributeName=sn -# The attribute on person objects in LDAP to map to the email property in Alfresco -ldap.synchronisation.userEmailAttributeName=cn -# The attribute on person objects in LDAP to map to the organizational id property in Alfresco -ldap.synchronisation.userOrganizationalIdAttributeName=maildomain -# The default home folder provider to use for people created via LDAP import -ldap.synchronisation.defaultHomeFolderProvider=companyHomeFolderProvider -# The query to find group objects -ldap.synchronisation.groupQuery=(objectclass=AlfrescoGroup) -# The search base to use to find group objects -ldap.synchronisation.groupSearchBase=ou=AlfrescoGroups,ou=mycompany,o=com -# The attribute on LDAP group objects to map to the gid property in Alfrecso -ldap.synchronisation.groupIdAttributeName=cn -# The group type in LDAP -ldap.synchronisation.groupType=AlfrescoGroup -# The person type in LDAP -ldap.synchronisation.personType=inetOrgPerson -# The attribute in LDAP on group objects that defines the DN for its members -ldap.synchronisation.groupMemberAttributeName=member -# The cron expression defining when people imports should take place (e.g. every evening at 22:00 hours) -ldap.synchronisation.import.person.cron=0 0 22 * * ? -# The cron expression defining when group imports should take place (e.g. every evening at 21:45 hours) -ldap.synchronisation.import.group.cron=0 45 21 * * ? -# Should all groups be cleared out at import time? -# - this is safe as groups are not used in Alfresco for other things (unlike person objects which you should never clear out during an import) -# - setting this to true means old group definitions will be tidied up. -ldap.synchronisation.import.group.clearAllChildren=false - - - diff --git a/tests/integration/tests/maven-projects/maven-custom-type/src/test/resources/alfresco/extension/custom-repository-context.xml b/tests/integration/tests/maven-projects/maven-custom-type/src/test/resources/alfresco/extension/custom-repository-context.xml deleted file mode 100644 index a5c4c4096c1..00000000000 --- a/tests/integration/tests/maven-projects/maven-custom-type/src/test/resources/alfresco/extension/custom-repository-context.xml +++ /dev/null @@ -1,53 +0,0 @@ - - - - - - - - - - - true - - - - classpath:alfresco/repository.properties - classpath:alfresco/version.properties - classpath:alfresco/domain/transaction.properties - - - classpath:alfresco/extension/application.properties - - - - - - - - classpath:alfresco/domain/hibernate-cfg.properties - - - - - \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/maven-custom-type/src/test/resources/alfresco/extension/file-servers-custom.xml b/tests/integration/tests/maven-projects/maven-custom-type/src/test/resources/alfresco/extension/file-servers-custom.xml deleted file mode 100644 index 11742c72309..00000000000 --- a/tests/integration/tests/maven-projects/maven-custom-type/src/test/resources/alfresco/extension/file-servers-custom.xml +++ /dev/null @@ -1,152 +0,0 @@ - - - - - - - - - - - - - - - - - - - - Alfresco CIFS Server - - - 255.255.255.0 - - - - - - ${smb.server.bindto} - - - - - - - - - - - - - - - - - - - ${ftp.port} - - - - - - - - - - - - workspace://SpacesStore - /app:company_home - - - - __Alfresco.url - http://${localname}/ - - - - - - - - - - alfresco/desktop/Alfresco.exe - http://${localname}/ - - - org.alfresco.filesys.smb.server.repo.desk.CheckInOutDesktopAction - CheckInOut - __CheckInOut.exe - - - org.alfresco.filesys.smb.server.repo.desk.JavaScriptDesktopAction - JavaScriptURL - __ShowDetails.exe - - anyFiles - copyToTarget - - - - - - - - - - - - - - - - - diff --git a/tests/integration/tests/maven-projects/maven-custom-type/src/test/resources/log4j.properties b/tests/integration/tests/maven-projects/maven-custom-type/src/test/resources/log4j.properties deleted file mode 100644 index 8d919e9bb17..00000000000 --- a/tests/integration/tests/maven-projects/maven-custom-type/src/test/resources/log4j.properties +++ /dev/null @@ -1,147 +0,0 @@ -# Licensed to the Apache Software Foundation (ASF) under one or more -# contributor license agreements. See the NOTICE file distributed with -# this work for additional information regarding copyright ownership. -# The ASF licenses this file to You under the Apache License, Version 2.0 -# (the "License"); you may not use this file except in compliance with -# the License. You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - - -# Customized alfresco log location -# Set root logger level to error -log4j.rootLogger=${webapp.log.level}, Console, File - -###### Console appender definition ####### - -# All outputs currently set to be a ConsoleAppender. -log4j.appender.Console=org.apache.log4j.ConsoleAppender -log4j.appender.Console.layout=org.apache.log4j.PatternLayout -log4j.appender.Console.layout.ConversionPattern=%d{ABSOLUTE} %-5p [%c{3}] %m%n -#log4j.appender.Console.layout.ConversionPattern=%d{ABSOLUTE} %-5p [%c] %m%n - -###### File appender definition ####### -log4j.appender.File=org.apache.log4j.DailyRollingFileAppender -log4j.appender.File.File=${webapp.log.dir}alfresco.log -log4j.appender.File.Append=true -log4j.appender.File.DatePattern='.'yyyy-MM-dd -log4j.appender.File.layout=org.apache.log4j.PatternLayout -log4j.appender.File.layout.ConversionPattern=%d{ABSOLUTE} %-5p [%c] %m%n - -###### Hibernate specific appender definition ####### -#log4j.appender.file=org.apache.log4j.FileAppender -#log4j.appender.file.File=hibernate.log -#log4j.appender.file.layout=org.apache.log4j.PatternLayout -#log4j.appender.file.layout.ConversionPattern=%d{ABSOLUTE} %5p %c{1}:%L - %m%n - -###### Log level overrides ####### - -log4j.logger.org.alfresco.repo.model.filefolder=info - -# Hibernate -log4j.logger.org.hibernate=error -log4j.logger.org.hibernate.util.JDBCExceptionReporter=fatal -log4j.logger.org.hibernate.event.def.AbstractFlushingEventListener=fatal -#log4j.logger.org.hibernate.cache.EhCacheProvider=warn -log4j.logger.org.hibernate.type=warn -# log4j.logger.org.hibernate.persister.collection=DEBUG - -# Spring -log4j.logger.org.springframework=warn - -# Axis/WSS4J -log4j.logger.org.apache.axis=info -log4j.logger.org.apache.ws=info - -# MyFaces -log4j.logger.org.apache.myfaces.util.DebugUtils=info -log4j.logger.org.apache.myfaces.el.VariableResolverImpl=error -log4j.logger.org.apache.myfaces.application.jsp.JspViewHandlerImpl=error -log4j.logger.org.apache.myfaces.taglib=error - -# log prepared statement cache activity ### -log4j.logger.org.hibernate.ps.PreparedStatementCache=info - -# Alfresco -log4j.logger.org.alfresco=error -log4j.logger.org.alfresco.repo.avm=info -log4j.logger.org.alfresco.config=info -log4j.logger.org.alfresco.sample=info -log4j.logger.org.alfresco.web=info -log4j.logger.org.alfresco.web.scripts=warn -#log4j.logger.org.alfresco.web.ui.repo.component.UIActions=debug -#log4j.logger.org.alfresco.web.ui.repo.tag.PageTag=debug -#log4j.logger.org.alfresco.web.bean.clipboard=debug -log4j.logger.org.alfresco.repo.webservice=info -log4j.logger.org.alfresco.service.descriptor.DescriptorService=info -#log4j.logger.org.alfresco.repo.importer.ImporterBootstrap=info -#log4j.logger.org.alfresco.web.ui.common.Utils=info -log4j.logger.org.alfresco.repo.admin.patch.PatchExecuter=info -log4j.logger.org.alfresco.repo.module.ModuleServiceImpl=info -log4j.logger.org.alfresco.repo.domain.schema.SchemaBootstrap=info -log4j.logger.org.alfresco.repo.admin.ConfigurationChecker=info -log4j.logger.org.alfresco.repo.node.index.FullIndexRecoveryComponent=info -log4j.logger.org.alfresco.util.OpenOfficeConnectionTester=warn -log4j.logger.org.alfresco.repo.node.db.hibernate.HibernateNodeDaoServiceImpl=warn -#log4j.logger.org.alfresco.web.app.DebugPhaseListener=debug -#log4j.logger.org.alfresco.repo.cache.EhCacheTracerJob=debug -#log4j.logger.org.alfresco.repo.search.Indexer=debug -#log4j.logger.org.alfresco.repo.workflow=info -#log4j.logger.org.alfresco.repo.jscript=DEBUG -log4j.logger.org.alfresco.repo.jscript.AlfrescoRhinoScriptDebugger=off - -# CIFS server debugging -#log4j.logger.org.alfresco.smb.protocol=debug -#log4j.logger.org.alfresco.smb.protocol.auth=debug -#log4j.logger.org.alfresco.acegi=debug - -# FTP server debugging -#log4j.logger.org.alfresco.ftp.protocol=debug -#log4j.logger.org.alfresco.ftp.server=debug - -# WebDAV debugging -#log4j.logger.org.alfresco.webdav.protocol=debug - -# NTLM servlet filters -#log4j.logger.org.alfresco.web.app.servlet.NTLMAuthenticationFilter=debug -#log4j.logger.org.alfresco.repo.webdav.auth.NTLMAuthenticationFilter=debug - -# Integrity message threshold - if 'failOnViolation' is off, then WARNINGS are generated -log4j.logger.org.alfresco.repo.node.integrity=ERROR - -# New indexer debugging -#log4j.logger.org.alfresco.repo.search.impl.lucene.index=DEBUG - -# Audit debugging -# log4j.logger.org.alfresco.repo.audit=DEBUG -# log4j.logger.org.alfresco.repo.audit.model=DEBUG - -# Turn off Spring remoting warnings that should really be info or debug. -log4j.logger.org.springframework.remoting.support=error - -# Templating debugging -# log4j.logger.org.alfresco.web.forms=debug -# log4j.logger.org.chiba.xml.xforms=debug - -# Property sheet and modelling debugging -# change to error to hide the warnings about missing properties and associations -log4j.logger.alfresco.missingProperties=warn -log4j.logger.org.alfresco.web.ui.repo.component.property.UIChildAssociation=warn -log4j.logger.org.alfresco.web.ui.repo.component.property.UIAssociation=warn -#log4j.logger.org.alfresco.web.ui.repo.component.property=debug -#log4j.logger.org.alfresco.repo.dictionary.DictionaryDAO=info - - -# Virtualization Server Registry -#log4j.logger.org.alfresco.mbeans.VirtServerRegistry=debug - -# Link Validation debugging -#log4j.logger.org.alfresco.linkvalidation.LinkValidationServiceImpl=debug -#log4j.logger.org.alfresco.linkvalidation.LinkValidationStoreCallbackHandler=debug - diff --git a/tests/integration/tests/maven-projects/maven-extensions/pom.xml b/tests/integration/tests/maven-projects/maven-extensions/pom.xml deleted file mode 100644 index a6e4f3b1e4c..00000000000 --- a/tests/integration/tests/maven-projects/maven-extensions/pom.xml +++ /dev/null @@ -1,42 +0,0 @@ - - 4.0.0 - org.sonar.tests - maven-extensions - 1.0-SNAPSHOT - jar - Sonar tests - maven extensions - http://jira.codehaus.org/browse/SONAR-222 - - - - org.jvnet.wagon-svn - wagon-svn - 1.8 - - - - org.apache.maven.wagon - wagon-webdav - 1.0-beta-2 - - - - - - - m.g.o-public - http://download.java.net/maven/2/ - - true - - - false - - - - - - turbo - - \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/maven-extensions/src/main/java/org/sonar/tests/mavenExtensions/Hello.java b/tests/integration/tests/maven-projects/maven-extensions/src/main/java/org/sonar/tests/mavenExtensions/Hello.java deleted file mode 100644 index 5967512fb80..00000000000 --- a/tests/integration/tests/maven-projects/maven-extensions/src/main/java/org/sonar/tests/mavenExtensions/Hello.java +++ /dev/null @@ -1,13 +0,0 @@ -package org.sonar.tests.mavenExtensions; - -public class Hello { - private String hello; - - public Hello(String s){ - this.hello = s; - } - - public String say() { - return hello; - } -} diff --git a/tests/integration/tests/maven-projects/maven-invalid-parameters/module_a/pom.xml b/tests/integration/tests/maven-projects/maven-invalid-parameters/module_a/pom.xml deleted file mode 100644 index 1731b49ae12..00000000000 --- a/tests/integration/tests/maven-projects/maven-invalid-parameters/module_a/pom.xml +++ /dev/null @@ -1,12 +0,0 @@ - - 4.0.0 - module_a - jar - Module A - - - org.sonar.tests.maven-invalid-parameters - parent - 1.0-SNAPSHOT - - \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/maven-invalid-parameters/module_a/src/main/java/org/sonar/tests/Hello.java b/tests/integration/tests/maven-projects/maven-invalid-parameters/module_a/src/main/java/org/sonar/tests/Hello.java deleted file mode 100644 index 4d61fb482fd..00000000000 --- a/tests/integration/tests/maven-projects/maven-invalid-parameters/module_a/src/main/java/org/sonar/tests/Hello.java +++ /dev/null @@ -1,10 +0,0 @@ -package org.sonar.tests; - -public class Hello { - public static String s=null; - - public String toString() { - while(true) - s="hello"; - } -} \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/maven-invalid-parameters/module_b/pom.xml b/tests/integration/tests/maven-projects/maven-invalid-parameters/module_b/pom.xml deleted file mode 100644 index fd975255a19..00000000000 --- a/tests/integration/tests/maven-projects/maven-invalid-parameters/module_b/pom.xml +++ /dev/null @@ -1,12 +0,0 @@ - - 4.0.0 - module_b - jar - Module B - - - org.sonar.tests.maven-invalid-parameters - parent - 1.0-SNAPSHOT - - \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/maven-invalid-parameters/module_b/src/main/java/org/sonar/tests/Hello.java b/tests/integration/tests/maven-projects/maven-invalid-parameters/module_b/src/main/java/org/sonar/tests/Hello.java deleted file mode 100644 index 4d61fb482fd..00000000000 --- a/tests/integration/tests/maven-projects/maven-invalid-parameters/module_b/src/main/java/org/sonar/tests/Hello.java +++ /dev/null @@ -1,10 +0,0 @@ -package org.sonar.tests; - -public class Hello { - public static String s=null; - - public String toString() { - while(true) - s="hello"; - } -} \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/maven-invalid-parameters/pom.xml b/tests/integration/tests/maven-projects/maven-invalid-parameters/pom.xml deleted file mode 100644 index 77a241f920b..00000000000 --- a/tests/integration/tests/maven-projects/maven-invalid-parameters/pom.xml +++ /dev/null @@ -1,46 +0,0 @@ - - 4.0.0 - org.sonar.tests.maven-invalid-parameters - parent - 1.0-SNAPSHOT - pom - Sonar tests - maven-invalid-parameters - - module_a - module_b - - - - - - maven-pmd-plugin - - true - true - - - - - org.apache.maven.plugins - maven-checkstyle-plugin - - true - - - - - org.codehaus.mojo - findbugs-maven-plugin - - true - - - - - - - - turbo - - - \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/modules/module_a/pom.xml b/tests/integration/tests/maven-projects/modules/module_a/pom.xml deleted file mode 100644 index 68cfa84eb36..00000000000 --- a/tests/integration/tests/maven-projects/modules/module_a/pom.xml +++ /dev/null @@ -1,16 +0,0 @@ - - 4.0.0 - module_a - pom - Module A - - - org.sonar.tests.modules - parent - 1.0-SNAPSHOT - - - submodule_a1 - submodule_a2 - - \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/modules/module_a/submodule_a1/pom.xml b/tests/integration/tests/maven-projects/modules/module_a/submodule_a1/pom.xml deleted file mode 100644 index 9f4f8596fa9..00000000000 --- a/tests/integration/tests/maven-projects/modules/module_a/submodule_a1/pom.xml +++ /dev/null @@ -1,13 +0,0 @@ - - 4.0.0 - submodule_a1 - jar - Sub-module A1 - - - org.sonar.tests.modules - module_a - 1.0-SNAPSHOT - - - \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/modules/module_a/submodule_a1/src/main/java/org/codehaus/sonar/samples/samplewithmodules/submodulea1/HelloA1.java b/tests/integration/tests/maven-projects/modules/module_a/submodule_a1/src/main/java/org/codehaus/sonar/samples/samplewithmodules/submodulea1/HelloA1.java deleted file mode 100644 index 57228b38d64..00000000000 --- a/tests/integration/tests/maven-projects/modules/module_a/submodule_a1/src/main/java/org/codehaus/sonar/samples/samplewithmodules/submodulea1/HelloA1.java +++ /dev/null @@ -1,16 +0,0 @@ -package org.codehaus.sonar.samples.samplewithmodules.submodulea1; - -public class HelloA1 { - private int i; - private HelloA1() { - - } - - public void hello() { - System.out.println("hello" + " world"); - } - - protected String getHello() { - return "hello"; - } -} \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/modules/module_a/submodule_a2/pom.xml b/tests/integration/tests/maven-projects/modules/module_a/submodule_a2/pom.xml deleted file mode 100644 index 428f37021e2..00000000000 --- a/tests/integration/tests/maven-projects/modules/module_a/submodule_a2/pom.xml +++ /dev/null @@ -1,12 +0,0 @@ - - 4.0.0 - submodule_a2 - jar - Sub-module A2 - - - org.sonar.tests.modules - module_a - 1.0-SNAPSHOT - - \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/modules/module_a/submodule_a2/src/main/java/org/codehaus/sonar/samples/samplewithmodules/submodulea2/HelloA2.java b/tests/integration/tests/maven-projects/modules/module_a/submodule_a2/src/main/java/org/codehaus/sonar/samples/samplewithmodules/submodulea2/HelloA2.java deleted file mode 100644 index 59306061168..00000000000 --- a/tests/integration/tests/maven-projects/modules/module_a/submodule_a2/src/main/java/org/codehaus/sonar/samples/samplewithmodules/submodulea2/HelloA2.java +++ /dev/null @@ -1,12 +0,0 @@ -package org.codehaus.sonar.samples.samplewithmodules.submodulea2; - -public class HelloA2 { - private int i; - private HelloA2() { - - } - - public void hello() { - System.out.println("hello" + " world"); - } -} \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/modules/module_b/pom.xml b/tests/integration/tests/maven-projects/modules/module_b/pom.xml deleted file mode 100644 index e5372f53a22..00000000000 --- a/tests/integration/tests/maven-projects/modules/module_b/pom.xml +++ /dev/null @@ -1,16 +0,0 @@ - - 4.0.0 - module_b - pom - Module B - - - org.sonar.tests.modules - parent - 1.0-SNAPSHOT - - - submodule_b1 - submodule_b2 - - \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/modules/module_b/submodule_b1/pom.xml b/tests/integration/tests/maven-projects/modules/module_b/submodule_b1/pom.xml deleted file mode 100644 index 1b52dfc3b66..00000000000 --- a/tests/integration/tests/maven-projects/modules/module_b/submodule_b1/pom.xml +++ /dev/null @@ -1,13 +0,0 @@ - - 4.0.0 - submodule_b1 - jar - Sub-module B1 - - - org.sonar.tests.modules - module_b - 1.0-SNAPSHOT - - - \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/modules/module_b/submodule_b1/src/main/java/org/codehaus/sonar/samples/samplewithmodules/submoduleb1/HelloB1.java b/tests/integration/tests/maven-projects/modules/module_b/submodule_b1/src/main/java/org/codehaus/sonar/samples/samplewithmodules/submoduleb1/HelloB1.java deleted file mode 100644 index 6977458e135..00000000000 --- a/tests/integration/tests/maven-projects/modules/module_b/submodule_b1/src/main/java/org/codehaus/sonar/samples/samplewithmodules/submoduleb1/HelloB1.java +++ /dev/null @@ -1,12 +0,0 @@ -package org.codehaus.sonar.samples.samplewithmodules.submoduleb1; - -public class HelloB1 { - private int i; - private HelloB1() { - - } - - public void hello() { - System.out.println("hello" + " world"); - } -} \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/modules/module_b/submodule_b2/pom.xml b/tests/integration/tests/maven-projects/modules/module_b/submodule_b2/pom.xml deleted file mode 100644 index 48b216c6329..00000000000 --- a/tests/integration/tests/maven-projects/modules/module_b/submodule_b2/pom.xml +++ /dev/null @@ -1,13 +0,0 @@ - - 4.0.0 - submodule_b2 - jar - Sub-module B2 - - - org.sonar.tests.modules - module_b - 1.0-SNAPSHOT - - - \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/modules/module_b/submodule_b2/src/main/java/org/codehaus/sonar/samples/samplewithmodules/submoduleb2/HelloB2.java b/tests/integration/tests/maven-projects/modules/module_b/submodule_b2/src/main/java/org/codehaus/sonar/samples/samplewithmodules/submoduleb2/HelloB2.java deleted file mode 100644 index 6451883354d..00000000000 --- a/tests/integration/tests/maven-projects/modules/module_b/submodule_b2/src/main/java/org/codehaus/sonar/samples/samplewithmodules/submoduleb2/HelloB2.java +++ /dev/null @@ -1,12 +0,0 @@ -package org.codehaus.sonar.samples.samplewithmodules.submoduleb2; - -public class HelloB2 { - private int i; - private HelloB2() { - - } - - public void hello() { - System.out.println("hello" + " world"); - } -} \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/modules/module_to_skip/pom.xml b/tests/integration/tests/maven-projects/modules/module_to_skip/pom.xml deleted file mode 100644 index 599b170a08c..00000000000 --- a/tests/integration/tests/maven-projects/modules/module_to_skip/pom.xml +++ /dev/null @@ -1,12 +0,0 @@ - - 4.0.0 - module_to_skip - jar - Module to skip - - - org.sonar.tests.modules - parent - 1.0-SNAPSHOT - - \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/modules/module_to_skip/src/main/java/org/codehaus/sonar/tests/modules/moduleToSkip/SkippedClass.java b/tests/integration/tests/maven-projects/modules/module_to_skip/src/main/java/org/codehaus/sonar/tests/modules/moduleToSkip/SkippedClass.java deleted file mode 100644 index af2db3ff70f..00000000000 --- a/tests/integration/tests/maven-projects/modules/module_to_skip/src/main/java/org/codehaus/sonar/tests/modules/moduleToSkip/SkippedClass.java +++ /dev/null @@ -1,17 +0,0 @@ -package org.codehaus.sonar.tests.modules.moduletoSkip; - -public class SkippedClass { - private int i; - private SkippedClass() { - - } - - public void skip() { - System.out.println("hello" + " world"); - int j=i+2223; - } - - protected String getFoo() { - return "fooooooooooooo"; - } -} \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/modules/pom.xml b/tests/integration/tests/maven-projects/modules/pom.xml deleted file mode 100644 index 77b9caf72bc..00000000000 --- a/tests/integration/tests/maven-projects/modules/pom.xml +++ /dev/null @@ -1,27 +0,0 @@ - - 4.0.0 - org.sonar.tests.modules - parent - 1.0-SNAPSHOT - pom - Sonar tests - modules - - module_a - module_to_skip - module_b - - - - module_to_skip,fake_module - - - - - junit - junit - 3.8.1 - test - - - \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/no-tests/pom.xml b/tests/integration/tests/maven-projects/no-tests/pom.xml deleted file mode 100644 index c3367c185e2..00000000000 --- a/tests/integration/tests/maven-projects/no-tests/pom.xml +++ /dev/null @@ -1,8 +0,0 @@ - - 4.0.0 - org.sonar.tests - no-tests - 1.0-SNAPSHOT - jar - No tests - \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/no-tests/src/main/java/org/sonar/tests/Hello.java b/tests/integration/tests/maven-projects/no-tests/src/main/java/org/sonar/tests/Hello.java deleted file mode 100644 index e762b8f3654..00000000000 --- a/tests/integration/tests/maven-projects/no-tests/src/main/java/org/sonar/tests/Hello.java +++ /dev/null @@ -1,13 +0,0 @@ -package org.sonar.tests; - -public class Hello { - private String hello; - - public Hello(String s){ - this.hello = s; - } - - public String say() { - return hello; - } -} diff --git a/tests/integration/tests/maven-projects/plugin-build-helper/pom.xml b/tests/integration/tests/maven-projects/plugin-build-helper/pom.xml deleted file mode 100644 index 52b2d054017..00000000000 --- a/tests/integration/tests/maven-projects/plugin-build-helper/pom.xml +++ /dev/null @@ -1,39 +0,0 @@ - - 4.0.0 - org.codehaus.sonar.plugins - test-build-helper - jar - Sonar maven build helper sample - 1.0.0-SNAPSHOT - - - - - org.codehaus.mojo - build-helper-maven-plugin - 1.1 - - - add-source - generate-sources - - add-source - - - - ${basedir}/src/main/java2 - ${basedir}/src/main/java3 - - - - - - - - - false - generate-sources - - \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/plugin-build-helper/src/main/java/Java1PackageClass.java b/tests/integration/tests/maven-projects/plugin-build-helper/src/main/java/Java1PackageClass.java deleted file mode 100644 index 8b64e1504f8..00000000000 --- a/tests/integration/tests/maven-projects/plugin-build-helper/src/main/java/Java1PackageClass.java +++ /dev/null @@ -1,32 +0,0 @@ -/* - * Sonar, open source software quality management tool. - * Copyright (C) 2008-2011 SonarSource - * mailto:contact AT sonarsource DOT com - * - * Sonar is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 3 of the License, or (at your option) any later version. - * - * Sonar is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with Sonar; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02 - */ - -public class Java1PackageClass { - - /** - * @param args - */ - public static void main(String[] args) { - String test1 = ""; - test1 = test1; - System.out.println("test"); - if ( true ) System.out.println("true"); - } -} diff --git a/tests/integration/tests/maven-projects/plugin-build-helper/src/main/java2/Java2PackageClass.java b/tests/integration/tests/maven-projects/plugin-build-helper/src/main/java2/Java2PackageClass.java deleted file mode 100644 index 253a5ca4b42..00000000000 --- a/tests/integration/tests/maven-projects/plugin-build-helper/src/main/java2/Java2PackageClass.java +++ /dev/null @@ -1,32 +0,0 @@ -/* - * Sonar, open source software quality management tool. - * Copyright (C) 2008-2011 SonarSource - * mailto:contact AT sonarsource DOT com - * - * Sonar is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 3 of the License, or (at your option) any later version. - * - * Sonar is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with Sonar; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02 - */ - -public class Java2PackageClass { - - /** - * @param args - */ - public static void main(String[] args) { - String test2 = ""; - test2 = test2; - System.out.println("test2"); - if ( true ) System.out.println("true"); - } -} diff --git a/tests/integration/tests/maven-projects/plugin-build-helper/src/main/java3/Java3PackageClass.java b/tests/integration/tests/maven-projects/plugin-build-helper/src/main/java3/Java3PackageClass.java deleted file mode 100644 index ee3fe206337..00000000000 --- a/tests/integration/tests/maven-projects/plugin-build-helper/src/main/java3/Java3PackageClass.java +++ /dev/null @@ -1,32 +0,0 @@ -/* - * Sonar, open source software quality management tool. - * Copyright (C) 2008-2011 SonarSource - * mailto:contact AT sonarsource DOT com - * - * Sonar is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 3 of the License, or (at your option) any later version. - * - * Sonar is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with Sonar; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02 - */ - -public class Java3PackageClass { - - /** - * @param args - */ - public static void main(String[] args) { - String test3 = ""; - test3 = test3; - if ( true ) System.out.println("true"); - } - -} diff --git a/tests/integration/tests/maven-projects/pom-without-modules/pom.xml b/tests/integration/tests/maven-projects/pom-without-modules/pom.xml deleted file mode 100644 index a38c88c6369..00000000000 --- a/tests/integration/tests/maven-projects/pom-without-modules/pom.xml +++ /dev/null @@ -1,10 +0,0 @@ - - - 4.0.0 - org.sonar.tests - pom-without-modules - pom - 1.0-SNAPSHOT - POM without modules - \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/project-to-disable/pom.xml b/tests/integration/tests/maven-projects/project-to-disable/pom.xml deleted file mode 100644 index f80bb78e012..00000000000 --- a/tests/integration/tests/maven-projects/project-to-disable/pom.xml +++ /dev/null @@ -1,25 +0,0 @@ - - 4.0.0 - org.sonar.tests - disabled-project - 1.0-SNAPSHOT - jar - Sonar tests - disabled project - - - - - org.apache.maven.plugins - maven-compiler-plugin - - 1.5 - 1.5 - - - - - - - turbo - - \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/project-to-disable/src/main/java/Hello.java b/tests/integration/tests/maven-projects/project-to-disable/src/main/java/Hello.java deleted file mode 100644 index 01e0bd0e460..00000000000 --- a/tests/integration/tests/maven-projects/project-to-disable/src/main/java/Hello.java +++ /dev/null @@ -1,14 +0,0 @@ -public class Hello { - - private Hello() { - - } - - public void hello() { - System.out.println("hello" + " world"); - } - - protected String getHello() { - return "hello"; - } -} \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/reference/pom.xml b/tests/integration/tests/maven-projects/reference/pom.xml deleted file mode 100644 index d155aad7602..00000000000 --- a/tests/integration/tests/maven-projects/reference/pom.xml +++ /dev/null @@ -1,90 +0,0 @@ - - 4.0.0 - org.sonar.tests - reference - 1.0-SNAPSHOT - jar - Sonar tests - reference - Sonar integration tests - reference project - http://foo/bar - - scm:svn:http://svn.codehaus.org/sonar/trunk/tests/integration/reference-projects/reference - scm:svn:https://svn.codehaus.org/sonar/trunk/tests/integration/reference-projects/reference - - http://svn.sonar.codehaus.org/trunk/tests/integration - - - - jira - http://jira.codehaus.org/browse/SONAR - - - - bamboo - http://bamboo.ci.codehaus.org/browse/SONAR/ - - - - - geronimo-spec - geronimo-spec-jta - 1.0-M1 - - - org.hibernate - hibernate - 3.2.6.ga - - - - javax.transaction - jta - - - - commons-logging - commons-logging - - - - - org.hibernate - hibernate-annotations - 3.3.0.ga - - - org.hibernate - hibernate-commons-annotations - 3.3.0.ga - - - org.hibernate - hibernate-entitymanager - 3.3.1.ga - - - junit - junit - 4.4 - test - - - - - - - org.apache.maven.plugins - maven-compiler-plugin - - 1.5 - 1.5 - - - - - - UTF-8 - - \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/reference/src/main/java/ClassOnDefaultPackage.java b/tests/integration/tests/maven-projects/reference/src/main/java/ClassOnDefaultPackage.java deleted file mode 100644 index dff4c90b9ba..00000000000 --- a/tests/integration/tests/maven-projects/reference/src/main/java/ClassOnDefaultPackage.java +++ /dev/null @@ -1,10 +0,0 @@ -public class ClassOnDefaultPackage { - - public ClassOnDefaultPackage(int i) { - int j = i++; - } - - private String myMethod() { - return "hello"; - } -} diff --git a/tests/integration/tests/maven-projects/reference/src/main/java/org/sonar/samples/ClassUnderTest.java b/tests/integration/tests/maven-projects/reference/src/main/java/org/sonar/samples/ClassUnderTest.java deleted file mode 100644 index 8f5453ae7cf..00000000000 --- a/tests/integration/tests/maven-projects/reference/src/main/java/org/sonar/samples/ClassUnderTest.java +++ /dev/null @@ -1,11 +0,0 @@ -package org.sonar.samples; - -public class ClassUnderTest { - public void toto() throws Exception { - int i=0; - i++; - } - public String hello() { - return "hello"; - } -} diff --git a/tests/integration/tests/maven-projects/reference/src/main/java/org/sonar/samples/ClassWithComments.java b/tests/integration/tests/maven-projects/reference/src/main/java/org/sonar/samples/ClassWithComments.java deleted file mode 100644 index f4c4948763e..00000000000 --- a/tests/integration/tests/maven-projects/reference/src/main/java/org/sonar/samples/ClassWithComments.java +++ /dev/null @@ -1,25 +0,0 @@ -package org.sonar.samples; - -/** - * - * THE JAVADOC HEADER - * - */ -public class ClassWithComments { - - public ClassWithComments(int i) { - // single comment - int j = i++; - } - - private String myMethod() { - /* - comment - on - many - lines - */ - int toto=34; // comment at end of line - return "hello"; - } -} diff --git a/tests/integration/tests/maven-projects/reference/src/main/java/org/sonar/samples/ClassWithPackageImportsComment.java b/tests/integration/tests/maven-projects/reference/src/main/java/org/sonar/samples/ClassWithPackageImportsComment.java deleted file mode 100644 index 69e20c8a31a..00000000000 --- a/tests/integration/tests/maven-projects/reference/src/main/java/org/sonar/samples/ClassWithPackageImportsComment.java +++ /dev/null @@ -1,7 +0,0 @@ -// some comment -package org.sonar.samples; - -import java.lang.Runtime; -import java.lang.String; - -// another comment \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/reference/src/main/java/org/sonar/samples/EmptyClass.java b/tests/integration/tests/maven-projects/reference/src/main/java/org/sonar/samples/EmptyClass.java deleted file mode 100644 index c89b8e1c0e4..00000000000 --- a/tests/integration/tests/maven-projects/reference/src/main/java/org/sonar/samples/EmptyClass.java +++ /dev/null @@ -1,4 +0,0 @@ -package org.sonar.samples; - -public class EmptyClass { -} diff --git a/tests/integration/tests/maven-projects/reference/src/main/java/org/sonar/samples/EmptyFile.java b/tests/integration/tests/maven-projects/reference/src/main/java/org/sonar/samples/EmptyFile.java deleted file mode 100644 index d3eb8712dee..00000000000 --- a/tests/integration/tests/maven-projects/reference/src/main/java/org/sonar/samples/EmptyFile.java +++ /dev/null @@ -1 +0,0 @@ -// empty class file with only a comment see http://jira.codehaus.org/browse/SONAR-864 \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/reference/src/main/java/org/sonar/samples/HibernateModel.java b/tests/integration/tests/maven-projects/reference/src/main/java/org/sonar/samples/HibernateModel.java deleted file mode 100644 index 6246b64620e..00000000000 --- a/tests/integration/tests/maven-projects/reference/src/main/java/org/sonar/samples/HibernateModel.java +++ /dev/null @@ -1,24 +0,0 @@ -package org.sonar.samples; - -import javax.persistence.*; - -@Entity -@Table(name = "foo") -public class HibernateModel implements java.io.Serializable { - - @Id - @Column(name = "id") - @SequenceGenerator(name = "FOO_ID_SEQ", sequenceName = "FOO_ID_SEQ") - @GeneratedValue(strategy = GenerationType.AUTO, generator = "FOO_ID_SEQ") - private Integer id; - - @Column(name = "column1", updatable = true, nullable = true, length = 32) - private String column1; - - public HibernateModel() { - } - - public HibernateModel(String column1) { - this.column1 = column1; - } -} diff --git a/tests/integration/tests/maven-projects/reference/src/main/java/org/sonar/samples/InnerClass.java b/tests/integration/tests/maven-projects/reference/src/main/java/org/sonar/samples/InnerClass.java deleted file mode 100644 index d1216665023..00000000000 --- a/tests/integration/tests/maven-projects/reference/src/main/java/org/sonar/samples/InnerClass.java +++ /dev/null @@ -1,87 +0,0 @@ -/* - * Sonar, entreprise quality control tool. - * Copyright (C) 2007-2008 Hortis-GRC SA - * mailto:be_agile HAT hortis DOT ch - * - * Sonar is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 3 of the License, or (at your option) any later version. - * - * Sonar is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with Sonar; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02 - */ -package org.sonar.samples; - -public class InnerClass { - - protected void methodOne() { - int i = 0; - i++; - } - - protected void methodTwo() { - int i = 0; - i++; - } - - protected int methodReturnThree() { - return 3; - } - - class InnerClassInside { - - InnerClassInside() { - } - - protected void innerMethodOne() { - System.out.println("in one"); - } - - protected void innerMethodTwo() { - System.out.println("in two"); - } - - protected int methodReturnFour() { - return 4; - } - - } -} - -class PrivateClass { - PrivateClass() { - - } - - void innerMethodThree() { - System.out.println("in three"); - } - - void innerMethodFour() { - System.out.println("in four"); - } - - void innerMethodFive() { - if (true) { - System.out.println("in five"); - } - } - - void innerMethodSix() { - if (true) { - System.out.println("in six"); - } - } - - int methodReturnfive() { - return 5; - } - -} \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/reference/src/main/java/org/sonar/samples/InterfaceWithConstants.java b/tests/integration/tests/maven-projects/reference/src/main/java/org/sonar/samples/InterfaceWithConstants.java deleted file mode 100644 index 850b4e2556d..00000000000 --- a/tests/integration/tests/maven-projects/reference/src/main/java/org/sonar/samples/InterfaceWithConstants.java +++ /dev/null @@ -1,11 +0,0 @@ -package org.sonar.samples; - -public interface InterfaceWithConstants { - int INT_CONSTANT = 1; - - EmptyClass OBJECT_CONSTANT = new EmptyClass(); - - void doSomething(); - - void doSomethingElse(); -} diff --git a/tests/integration/tests/maven-projects/reference/src/main/java/org/sonar/samples/PureAbstractClass.java b/tests/integration/tests/maven-projects/reference/src/main/java/org/sonar/samples/PureAbstractClass.java deleted file mode 100644 index 8840823f763..00000000000 --- a/tests/integration/tests/maven-projects/reference/src/main/java/org/sonar/samples/PureAbstractClass.java +++ /dev/null @@ -1,7 +0,0 @@ -package org.sonar.samples; - -public abstract class PureAbstractClass { - - abstract void doSomething(); - -} diff --git a/tests/integration/tests/maven-projects/reference/src/main/java/org/sonar/samples/PureInterface.java b/tests/integration/tests/maven-projects/reference/src/main/java/org/sonar/samples/PureInterface.java deleted file mode 100644 index 4a68712da0a..00000000000 --- a/tests/integration/tests/maven-projects/reference/src/main/java/org/sonar/samples/PureInterface.java +++ /dev/null @@ -1,9 +0,0 @@ -package org.sonar.samples; - -public interface PureInterface { - - void doSomething(); - - void doSomethingElse(); - -} diff --git a/tests/integration/tests/maven-projects/reference/src/main/java/org/sonar/samples/Utf8Characters.java b/tests/integration/tests/maven-projects/reference/src/main/java/org/sonar/samples/Utf8Characters.java deleted file mode 100644 index d17dcddb369..00000000000 --- a/tests/integration/tests/maven-projects/reference/src/main/java/org/sonar/samples/Utf8Characters.java +++ /dev/null @@ -1,13 +0,0 @@ -package org.sonar.samples; - -public class Utf8Characters { - String test = "voyelles accentuées"; - String test2 = "àéèûù"; - String test3 = "3 Ä"; - - public Utf8Characters(){ - String t; - if (true) - t = "éöàä$£"; - } -} diff --git a/tests/integration/tests/maven-projects/reference/src/main/java/org/sonar/samples/duplicated_lines_with_other_package1/DuplicatedLinesWithOtherPackage.java b/tests/integration/tests/maven-projects/reference/src/main/java/org/sonar/samples/duplicated_lines_with_other_package1/DuplicatedLinesWithOtherPackage.java deleted file mode 100644 index 73efdd038bc..00000000000 --- a/tests/integration/tests/maven-projects/reference/src/main/java/org/sonar/samples/duplicated_lines_with_other_package1/DuplicatedLinesWithOtherPackage.java +++ /dev/null @@ -1,60 +0,0 @@ -/* - * Sonar, entreprise quality control tool. - * Copyright (C) 2007-2008 Hortis-GRC SA - * mailto:be_agile HAT hortis DOT ch - * - * Sonar is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 3 of the License, or (at your option) any later version. - * - * Sonar is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with Sonar; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02 - */ -package org.sonar.samples.duplicated_lines_with_other_package1; - -public class DuplicatedLinesWithOtherPackage { - - public DuplicatedLinesWithOtherPackage() { - } - - public void duplicatedMethodWithOtherPackage() { - char[] charList = new char[30]; - charList[0] = 'a'; - charList[1] = 'b'; - charList[2] = 'c'; - charList[3] = 'd'; - charList[4] = 'e'; - charList[5] = 'f'; - charList[6] = 'g'; - charList[7] = 'g'; - charList[8] = 'g'; - charList[9] = 'g'; - charList[10] = 'g'; - charList[11] = 'g'; - charList[12] = 'g'; - charList[13] = 'g'; - charList[14] = 'g'; - charList[15] = 'g'; - charList[16] = 'g'; - charList[17] = 'g'; - charList[18] = 'g'; - charList[19] = 'g'; - charList[20] = 'g'; - charList[21] = 'g'; - charList[22] = 'g'; - charList[23] = 'g'; - charList[24] = 'g'; - charList[27] = 'g'; - charList[28] = 'g'; - charList[29] = 'g'; - charList[30] = 'g'; - } - -} \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/reference/src/main/java/org/sonar/samples/duplicated_lines_with_other_package2/DuplicatedLinesWithOtherPackage.java b/tests/integration/tests/maven-projects/reference/src/main/java/org/sonar/samples/duplicated_lines_with_other_package2/DuplicatedLinesWithOtherPackage.java deleted file mode 100644 index dd5f6108917..00000000000 --- a/tests/integration/tests/maven-projects/reference/src/main/java/org/sonar/samples/duplicated_lines_with_other_package2/DuplicatedLinesWithOtherPackage.java +++ /dev/null @@ -1,60 +0,0 @@ -/* - * Sonar, entreprise quality control tool. - * Copyright (C) 2007-2008 Hortis-GRC SA - * mailto:be_agile HAT hortis DOT ch - * - * Sonar is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 3 of the License, or (at your option) any later version. - * - * Sonar is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with Sonar; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02 - */ -package org.sonar.samples.duplicated_lines_with_other_package2; - -public class DuplicatedLinesWithOtherPackage { - - public DuplicatedLinesWithOtherPackage() { - } - - public void duplicatedMethodWithOtherPackage() { - char[] charList = new char[30]; - charList[0] = 'a'; - charList[1] = 'b'; - charList[2] = 'c'; - charList[3] = 'd'; - charList[4] = 'e'; - charList[5] = 'f'; - charList[6] = 'g'; - charList[7] = 'g'; - charList[8] = 'g'; - charList[9] = 'g'; - charList[10] = 'g'; - charList[11] = 'g'; - charList[12] = 'g'; - charList[13] = 'g'; - charList[14] = 'g'; - charList[15] = 'g'; - charList[16] = 'g'; - charList[17] = 'g'; - charList[18] = 'g'; - charList[19] = 'g'; - charList[20] = 'g'; - charList[21] = 'g'; - charList[22] = 'g'; - charList[23] = 'g'; - charList[24] = 'g'; - charList[27] = 'g'; - charList[28] = 'g'; - charList[29] = 'g'; - charList[30] = 'g'; - } - -} \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/reference/src/main/java/org/sonar/samples/duplicated_lines_within_package/DuplicatedLinesInSamePackage1.java b/tests/integration/tests/maven-projects/reference/src/main/java/org/sonar/samples/duplicated_lines_within_package/DuplicatedLinesInSamePackage1.java deleted file mode 100644 index c62cfe7c047..00000000000 --- a/tests/integration/tests/maven-projects/reference/src/main/java/org/sonar/samples/duplicated_lines_within_package/DuplicatedLinesInSamePackage1.java +++ /dev/null @@ -1,63 +0,0 @@ -/* - * Sonar, entreprise quality control tool. - * Copyright (C) 2007-2008 Hortis-GRC SA - * mailto:be_agile HAT hortis DOT ch - * - * Sonar is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 3 of the License, or (at your option) any later version. - * - * Sonar is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with Sonar; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02 - */ -package org.sonar.samples.duplicated_lines_within_package; - -public class DuplicatedLinesInSamePackage1 { - - public DuplicatedLinesInSamePackage1() { - } - - /* - * sddfgdfgfg - */ - public void duplicatedMethodInSameClass1() { - int intergerToBeIncremented = 0; - while (intergerToBeIncremented < 100) { - intergerToBeIncremented++; - } - int intergerToBeIncremented2 = 0; - while (intergerToBeIncremented2 < 100) { - intergerToBeIncremented2++; - } - // first - int intergerToBeIncremented3 = 0; - while (intergerToBeIncremented3 < 100) { - intergerToBeIncremented3++; - } - int intergerToBeIncremented4 = 0; - while (intergerToBeIncremented4 < 100) { - intergerToBeIncremented4++; - } - int intergerToBeIncremented5 = 0; - while (intergerToBeIncremented5 < 100) { - intergerToBeIncremented5++; - } - int intergerToBeIncremented6 = 0; - while (intergerToBeIncremented6 < 100) { - intergerToBeIncremented6++; - } - int intergerToBeIncremented7 = 0; - while (intergerToBeIncremented7 < 100) { - intergerToBeIncremented7++; - } - } - - -} \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/reference/src/main/java/org/sonar/samples/duplicated_lines_within_package/DuplicatedLinesInSamePackage2.java b/tests/integration/tests/maven-projects/reference/src/main/java/org/sonar/samples/duplicated_lines_within_package/DuplicatedLinesInSamePackage2.java deleted file mode 100644 index 4da16afae92..00000000000 --- a/tests/integration/tests/maven-projects/reference/src/main/java/org/sonar/samples/duplicated_lines_within_package/DuplicatedLinesInSamePackage2.java +++ /dev/null @@ -1,65 +0,0 @@ -/* - * Sonar, entreprise quality control tool. - * Copyright (C) 2007-2008 Hortis-GRC SA - * mailto:be_agile HAT hortis DOT ch - * - * Sonar is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 3 of the License, or (at your option) any later version. - * - * Sonar is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with Sonar; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02 - */ -package org.sonar.samples.duplicated_lines_within_package; - -public class DuplicatedLinesInSamePackage2 { - - public DuplicatedLinesInSamePackage2() { - } - - /* - * sddfgdfgfg - */ - public void duplicatedMethodInSameClass1() { - int intergerToBeIncremented = 0; - while (intergerToBeIncremented < 100) { - intergerToBeIncremented++; - } - int intergerToBeIncremented2 = 0; - while (intergerToBeIncremented2 < 100) { - intergerToBeIncremented2++; - } - // second - int intergerToBeIncremented3 = 0; - while (intergerToBeIncremented3 < 100) { - intergerToBeIncremented3++; - } - int intergerToBeIncremented4 = 0; - while (intergerToBeIncremented4 < 100) { - intergerToBeIncremented4++; - } - int intergerToBeIncremented5 = 0; - while (intergerToBeIncremented5 < 100) { - intergerToBeIncremented5++; - } - // vghgvhz - // bhjjh - int intergerToBeIncremented6 = 0; - while (intergerToBeIncremented6 < 100) { - intergerToBeIncremented6++; - } - int intergerToBeIncremented7 = 0; - while (intergerToBeIncremented7 < 100) { - intergerToBeIncremented7++; - } - } - - -} \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/reference/src/main/java/org/sonar/samples/duplicated_lines_within_same_class/DuplicatedLinesInSameClass.java b/tests/integration/tests/maven-projects/reference/src/main/java/org/sonar/samples/duplicated_lines_within_same_class/DuplicatedLinesInSameClass.java deleted file mode 100644 index 3f57c58a130..00000000000 --- a/tests/integration/tests/maven-projects/reference/src/main/java/org/sonar/samples/duplicated_lines_within_same_class/DuplicatedLinesInSameClass.java +++ /dev/null @@ -1,89 +0,0 @@ -/* - * Sonar, entreprise quality control tool. - * Copyright (C) 2007-2008 Hortis-GRC SA - * mailto:be_agile HAT hortis DOT ch - * - * Sonar is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 3 of the License, or (at your option) any later version. - * - * Sonar is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with Sonar; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02 - */ -package org.sonar.samples.duplicated_lines_within_same_class; - -public class DuplicatedLinesInSameClass { - - public DuplicatedLinesInSameClass() { - } - - public void duplicatedMethodInSameClass1() { - String temp = ""; - for (int i=0; i<10; i++){ - temp += "say something"+i; - } - for (int i=0; i<20; i++){ - temp += "say nothing"+i; - } - for (int i=0; i<30; i++){ - temp += "always say nothing"+i; - } - for (int i=0; i<40; i++){ - temp += "really nothing to say "+i; - } - for (int i=0; i<50; i++){ - temp += "really really nothing to say "+i; - } - for (int i=0; i<60; i++){ - temp += ".. "+i; - } - for (int i=0; i<70; i++){ - temp += "you say something? "+i; - } - for (int i=0; i<80; i++){ - temp += "ah no..."+i; - } - for (int i=0; i<90; i++){ - temp += "bye"+i; - } - } - - public void duplicatedMethodInSameClass2() { - String temp = ""; - for (int i=0; i<10; i++){ - temp += "say something"+i; - } - for (int i=0; i<20; i++){ - temp += "say nothing"+i; - } - for (int i=0; i<30; i++){ - temp += "always say nothing"+i; - } - for (int i=0; i<40; i++){ - temp += "really nothing to say "+i; - } - for (int i=0; i<50; i++){ - temp += "really really nothing to say "+i; - } - for (int i=0; i<60; i++){ - temp += ".. "+i; - } - for (int i=0; i<70; i++){ - temp += "you say something? "+i; - } - for (int i=0; i<80; i++){ - temp += "ah no..."+i; - } - for (int i=0; i<90; i++){ - temp += "bye"+i; - } - } - -} diff --git a/tests/integration/tests/maven-projects/reference/src/main/resources/META-INF/persistence.xml b/tests/integration/tests/maven-projects/reference/src/main/resources/META-INF/persistence.xml deleted file mode 100644 index a182ecce7ef..00000000000 --- a/tests/integration/tests/maven-projects/reference/src/main/resources/META-INF/persistence.xml +++ /dev/null @@ -1,20 +0,0 @@ - - - - org.sonar.samples.HibernateModel - - - - - - - - - - - - - \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/reference/src/test/java/org/sonar/samples/ClassUnderTestTest.java b/tests/integration/tests/maven-projects/reference/src/test/java/org/sonar/samples/ClassUnderTestTest.java deleted file mode 100644 index 4e0562ee7af..00000000000 --- a/tests/integration/tests/maven-projects/reference/src/test/java/org/sonar/samples/ClassUnderTestTest.java +++ /dev/null @@ -1,16 +0,0 @@ -package org.sonar.samples; - -import junit.framework.TestCase; - -public class ClassUnderTestTest extends TestCase { - - public void testHello() { - ClassUnderTest instance = new ClassUnderTest(); - assertEquals("hello", instance.hello()); - } - - public void testToto() throws Exception { - ClassUnderTest instance = new ClassUnderTest(); - instance.toto(); - } -} diff --git a/tests/integration/tests/maven-projects/reference/src/test/java/org/sonar/samples/InnerClassTest.java b/tests/integration/tests/maven-projects/reference/src/test/java/org/sonar/samples/InnerClassTest.java deleted file mode 100644 index 29892a066af..00000000000 --- a/tests/integration/tests/maven-projects/reference/src/test/java/org/sonar/samples/InnerClassTest.java +++ /dev/null @@ -1,45 +0,0 @@ -/* - * Sonar, entreprise quality control tool. - * Copyright (C) 2007-2008 Hortis-GRC SA - * mailto:be_agile HAT hortis DOT ch - * - * Sonar is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 3 of the License, or (at your option) any later version. - * - * Sonar is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with Sonar; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02 - */ -package org.sonar.samples; - -import static junit.framework.Assert.assertEquals; -import org.junit.Test; - -public class InnerClassTest { - - @Test - public void shouldTestMethodToTest() { - InnerClass innerClass = new InnerClass(); - assertEquals(3, innerClass.methodReturnThree()); - } - - @Test - public void shouldTestInnerClassInside() { - InnerClass innerClass = new InnerClass(); - InnerClass.InnerClassInside innerClassInside = innerClass.new InnerClassInside(); - assertEquals(4, innerClassInside.methodReturnFour()); - } - - @Test - public void shouldTestPrivateClass() { - PrivateClass privateClass = new PrivateClass(); - assertEquals(5, privateClass.methodReturnfive()); - } -} diff --git a/tests/integration/tests/maven-projects/rules-on-tests/pom.xml b/tests/integration/tests/maven-projects/rules-on-tests/pom.xml deleted file mode 100644 index 3ea8256ac97..00000000000 --- a/tests/integration/tests/maven-projects/rules-on-tests/pom.xml +++ /dev/null @@ -1,51 +0,0 @@ - - 4.0.0 - org.sonar.tests - rulesOnTests - 1.0-SNAPSHOT - jar - Sonar tests - rules on tests (SONAR-413) - - - junit - junit - 4.4 - test - - - - - - - org.apache.maven.plugins - maven-compiler-plugin - - 1.5 - 1.5 - - - - - maven-pmd-plugin - 2.4 - - true - - - - - maven-checkstyle-plugin - 2.2 - - true - - - - - - - Sonar way - - - \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/rules-on-tests/src/main/java/org/sonar/tests/rulesOnTests/Hello.java b/tests/integration/tests/maven-projects/rules-on-tests/src/main/java/org/sonar/tests/rulesOnTests/Hello.java deleted file mode 100644 index 9058064315f..00000000000 --- a/tests/integration/tests/maven-projects/rules-on-tests/src/main/java/org/sonar/tests/rulesOnTests/Hello.java +++ /dev/null @@ -1,16 +0,0 @@ -package org.sonar.tests.rulesOnTests; - -public class Hello { - public void foo() throws Exception { - int i=0; - i++; - hello(); - } - public String hello() { - return "hello"; - } - public boolean equals(Object o) { - // TODO - return true; - } -} diff --git a/tests/integration/tests/maven-projects/rules-on-tests/src/main/java/org/sonar/tests/rulesOnTests/World.java b/tests/integration/tests/maven-projects/rules-on-tests/src/main/java/org/sonar/tests/rulesOnTests/World.java deleted file mode 100644 index 4693e9eeef2..00000000000 --- a/tests/integration/tests/maven-projects/rules-on-tests/src/main/java/org/sonar/tests/rulesOnTests/World.java +++ /dev/null @@ -1,25 +0,0 @@ -package org.sonar.tests.rulesOnTests; - -/** - * - * THE JAVADOC HEADER - * - */ -public class World { - - public World(int i) { - // single comment - int j = i++; - } - - private String myMethod() { - /* - comment - on - many - lines - */ - int toto=34; // comment at end of line - return "hello"; - } -} diff --git a/tests/integration/tests/maven-projects/rules-on-tests/src/test/java/org/sonar/tests/rulesOnTests/HelloTest.java b/tests/integration/tests/maven-projects/rules-on-tests/src/test/java/org/sonar/tests/rulesOnTests/HelloTest.java deleted file mode 100644 index f1d6dd5806e..00000000000 --- a/tests/integration/tests/maven-projects/rules-on-tests/src/test/java/org/sonar/tests/rulesOnTests/HelloTest.java +++ /dev/null @@ -1,16 +0,0 @@ -package org.sonar.tests.rulesOnTests; - -import junit.framework.TestCase; - -public class HelloTest extends TestCase { - - public void testHello() { - Hello instance = new Hello(); - assertEquals("hello", instance.hello()); - } - - public void testToto() throws Exception { - Hello instance = new Hello(); - instance.foo(); - } -} diff --git a/tests/integration/tests/maven-projects/rules-on-tests/src/test/java/org/sonar/tests/rulesOnTests/WorldTest.java b/tests/integration/tests/maven-projects/rules-on-tests/src/test/java/org/sonar/tests/rulesOnTests/WorldTest.java deleted file mode 100644 index 84e89e8a978..00000000000 --- a/tests/integration/tests/maven-projects/rules-on-tests/src/test/java/org/sonar/tests/rulesOnTests/WorldTest.java +++ /dev/null @@ -1,24 +0,0 @@ -package org.sonar.tests.rulesOnTests; - -import static junit.framework.Assert.assertTrue; -import org.junit.Test; - -public class WorldTest { - - @Test - public void testFoo() { - int i=0; - i++; - } - - @Test - public void shouldFoo() { - Object o = new World(30); - String s = o.toString(); - assertTrue(s==o); - } - - public boolean equals(Object o) { - return false; -} -} diff --git a/tests/integration/tests/maven-projects/single-classes/pom.xml b/tests/integration/tests/maven-projects/single-classes/pom.xml deleted file mode 100644 index 9e7b9d5c30b..00000000000 --- a/tests/integration/tests/maven-projects/single-classes/pom.xml +++ /dev/null @@ -1,25 +0,0 @@ - - 4.0.0 - org.sonar.tests - single-classes - 1.0-SNAPSHOT - jar - Single classes - - - - org.apache.maven.plugins - maven-compiler-plugin - - 1.5 - 1.5 - - - - - - - single-classes - - \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/single-classes/src/main/java/org/sonar/tests/SONAR582ViolationsWithoutLines.java b/tests/integration/tests/maven-projects/single-classes/src/main/java/org/sonar/tests/SONAR582ViolationsWithoutLines.java deleted file mode 100644 index 1506d09e64d..00000000000 --- a/tests/integration/tests/maven-projects/single-classes/src/main/java/org/sonar/tests/SONAR582ViolationsWithoutLines.java +++ /dev/null @@ -1,10 +0,0 @@ -package org.sonar.tests; - -public class SONAR582ViolationsWithoutLines { - public static String s=null; - - public String toString() { - while(true) - s="hello"; - } -} \ No newline at end of file diff --git a/tests/integration/tests/maven-projects/single-classes/src/main/java/org/sonar/tests/SONAR684EncodeViolationMessages.java b/tests/integration/tests/maven-projects/single-classes/src/main/java/org/sonar/tests/SONAR684EncodeViolationMessages.java deleted file mode 100644 index ca04b3340f4..00000000000 --- a/tests/integration/tests/maven-projects/single-classes/src/main/java/org/sonar/tests/SONAR684EncodeViolationMessages.java +++ /dev/null @@ -1,19 +0,0 @@ -package org.sonar.tests; - -public class SONAR684EncodeViolationMessages { - - private void bar() { - buz(""); - buz(""); - buz(""); - buz(""); - buz("