aboutsummaryrefslogtreecommitdiffstats
path: root/sonar-plugin-api/src/test/java
diff options
context:
space:
mode:
authorsimonbrandhof <simon.brandhof@gmail.com>2011-02-04 10:42:21 +0100
committersimonbrandhof <simon.brandhof@gmail.com>2011-02-04 10:42:21 +0100
commita14a0644c2a27ddec22f23925578a40aa6fa8302 (patch)
treeaa5c078cc8ec7c4e2020960ad9a343fb7e79a16c /sonar-plugin-api/src/test/java
parent0f44a42b85093a3dcef64b52f6e15337b119ec88 (diff)
downloadsonarqube-a14a0644c2a27ddec22f23925578a40aa6fa8302.tar.gz
sonarqube-a14a0644c2a27ddec22f23925578a40aa6fa8302.zip
Upgrade copyright headers
Diffstat (limited to 'sonar-plugin-api/src/test/java')
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/BaseModelTestCase.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/batch/AbstractCoverageExtensionTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/batch/AbstractDivisionDecoratorTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/batch/AbstractFileComplexityDecoratorTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/batch/AbstractFunctionComplexityDecoratorTest.java176
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/batch/AbstractSourceImporterTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/batch/AbstractSumChildrenDecoratorTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/batch/BatchExtensionDictionnaryTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/batch/DefaultFormulaDataTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/batch/SquidUtilsTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/batch/TimeMachineQueryTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/batch/maven/MavenPluginTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/batch/maven/MavenSurefireUtilsTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/batch/maven/MavenUtilsTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/charts/AbstractChartTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/charts/ChartParametersTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/checks/AnnotationCheckFactoryTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/checks/CheckWithIntegerProperty.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/checks/CheckWithKey.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/checks/CheckWithOverriddenPropertyKey.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/checks/CheckWithPrimitiveProperties.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/checks/CheckWithStringProperty.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/checks/CheckWithUnsupportedPropertyType.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/checks/CheckWithoutProperties.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/checks/NoSonarFilterTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/database/model/RuleFailureModelTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/database/model/SnapshotTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/design/DependencyTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/measures/AverageComplexityFormulaTest.java260
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/measures/CountDistributionBuilderTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/measures/MeanAggregationFormulaTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/measures/MeasureTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/measures/MeasureUtilsTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/measures/MeasuresFiltersTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/measures/PersistenceModeTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/measures/PropertiesBuilderTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/measures/RangeDistributionBuilderTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/measures/RuleMeasureTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/measures/SumChildDistributionFormulaTest.java282
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/measures/SumChildValuesFormulaTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/platform/EnvironmentTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/profiles/AnnotationProfileParserTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/profiles/ProfileExporterTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/profiles/ProfileImporterTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/profiles/RulesProfileTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/profiles/XMLProfileParserTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/profiles/XMLProfileSerializerTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/qualitymodel/CharacteristicPropertyTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/qualitymodel/CharacteristicTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/qualitymodel/ModelTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/resources/AbstractLanguageTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/resources/CoreMetricsTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/resources/DefaultProjectFileSystemTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/resources/DirectoryTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/resources/FileTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/resources/JavaFileTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/resources/JavaPackageTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/resources/LanguagesTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/resources/LibraryTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/resources/ProjectLinkTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/resources/ProjectTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/resources/QualifiersTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/resources/ResourceUtilsTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/resources/ScopesTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/rules/AnnotatedCheck.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/rules/AnnotatedCheckWithParameters.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/rules/AnnotationRuleParserTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/rules/DeprecatedAnnotatedCheck.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/rules/RuleAnnotationUtilsTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/rules/RulePriorityTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/rules/RuleTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/rules/RuleUtilsTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/rules/XMLRuleParserTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/security/GroupRoleTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/test/IsMeasure.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/test/IsResource.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/test/IsRuleMeasure.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/test/IsViolation.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/test/MavenTestUtils.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/test/ProjectTestBuilder.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/test/SimpleProjectFileSystem.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/utils/AnnotationUtilsTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/utils/FakeServlet.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/utils/HttpDownloaderTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/utils/IocContainerTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/utils/KeyValueFormatTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/utils/LocalizedMessagesTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/utils/ManifestUtilsTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/utils/ParsingUtilsTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/utils/RedirectServlet.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/utils/ServerHttpClientTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/utils/StaxParserTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/utils/TempFileUtilsTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/utils/TimeProfilerTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/utils/ValidationMessagesTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/utils/WildcardPatternTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/utils/XpathParserTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/utils/ZipUtilsTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/utils/dag/DirectAcyclicGraphTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/web/AbstractRubyTemplateTest.java2
-rw-r--r--sonar-plugin-api/src/test/java/org/sonar/api/web/CodeColorizerFormatTest.java2
101 files changed, 457 insertions, 457 deletions
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/BaseModelTestCase.java b/sonar-plugin-api/src/test/java/org/sonar/api/BaseModelTestCase.java
index 358a3ae61e1..28d1ac15e2d 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/BaseModelTestCase.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/BaseModelTestCase.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/batch/AbstractCoverageExtensionTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/batch/AbstractCoverageExtensionTest.java
index 036b8647878..56e5074fe82 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/batch/AbstractCoverageExtensionTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/batch/AbstractCoverageExtensionTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/batch/AbstractDivisionDecoratorTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/batch/AbstractDivisionDecoratorTest.java
index 3bce6e7cc91..ffb4c6e0bc4 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/batch/AbstractDivisionDecoratorTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/batch/AbstractDivisionDecoratorTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/batch/AbstractFileComplexityDecoratorTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/batch/AbstractFileComplexityDecoratorTest.java
index 60ad51521be..815df0c99ff 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/batch/AbstractFileComplexityDecoratorTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/batch/AbstractFileComplexityDecoratorTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/batch/AbstractFunctionComplexityDecoratorTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/batch/AbstractFunctionComplexityDecoratorTest.java
index 895e2a0c445..35a9e7be525 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/batch/AbstractFunctionComplexityDecoratorTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/batch/AbstractFunctionComplexityDecoratorTest.java
@@ -1,88 +1,88 @@
-/*
- * Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
- * 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.api.batch;
-
-import org.junit.Test;
-import static org.mockito.Mockito.*;
-import org.sonar.api.measures.CoreMetrics;
-import org.sonar.api.measures.Measure;
-import org.sonar.api.resources.Directory;
-import org.sonar.api.resources.File;
-import org.sonar.api.resources.Java;
-import org.sonar.api.resources.Resource;
-
-public class AbstractFunctionComplexityDecoratorTest {
-
- @Test
- public void calculateFunctionComplexity() {
-
- Resource directory = new Directory("fake");
- DecoratorContext context = mock(DecoratorContext.class);
- when(context.getMeasure(CoreMetrics.FUNCTIONS)).thenReturn(new Measure(CoreMetrics.FUNCTIONS, 200.0));
- when(context.getMeasure(CoreMetrics.COMPLEXITY)).thenReturn(new Measure(CoreMetrics.COMPLEXITY, 500.0));
-
- new AbstractFunctionComplexityDecorator(Java.INSTANCE) {
- }.decorate(directory, context);
-
- verify(context).saveMeasure(CoreMetrics.FUNCTION_COMPLEXITY, 2.5);
- }
-
- @Test
- public void noAverageIfMissingData() {
-
- DecoratorContext context = mock(DecoratorContext.class);
- when(context.getMeasure(CoreMetrics.FUNCTIONS)).thenReturn(new Measure(CoreMetrics.FUNCTIONS, 20.0));
- Resource directory = new Directory("fake");
-
- new AbstractFunctionComplexityDecorator(Java.INSTANCE) {
- }.decorate(directory, context);
-
- verify(context, never()).saveMeasure(eq(CoreMetrics.FUNCTION_COMPLEXITY), anyDouble());
- }
-
- @Test
- public void noAverageIfZeroFiles() {
- AbstractFunctionComplexityDecorator decorator = new AbstractFunctionComplexityDecorator(Java.INSTANCE) {
- };
-
- Resource directory = new Directory("fake");
- DecoratorContext context = mock(DecoratorContext.class);
- when(context.getMeasure(CoreMetrics.FUNCTIONS)).thenReturn(new Measure(CoreMetrics.FUNCTIONS, 0.0));
- when(context.getMeasure(CoreMetrics.COMPLEXITY)).thenReturn(new Measure(CoreMetrics.COMPLEXITY, 500.0));
-
- decorator.decorate(directory, context);
-
- verify(context, never()).saveMeasure(eq(CoreMetrics.FUNCTION_COMPLEXITY), anyDouble());
- }
-
- @Test
- public void doNotCalculateOnFiles() {
-
- Resource file = new File("fake");
- DecoratorContext context = mock(DecoratorContext.class);
- when(context.getMeasure(CoreMetrics.FUNCTIONS)).thenReturn(new Measure(CoreMetrics.FUNCTIONS, 1.0));
- when(context.getMeasure(CoreMetrics.COMPLEXITY)).thenReturn(new Measure(CoreMetrics.COMPLEXITY, 25.0));
-
- new AbstractFunctionComplexityDecorator(Java.INSTANCE) {
- }.decorate(file, context);
-
- verify(context).saveMeasure(eq(CoreMetrics.FUNCTION_COMPLEXITY), anyDouble());
- }
-}
+/*
+ * 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.api.batch;
+
+import org.junit.Test;
+import static org.mockito.Mockito.*;
+import org.sonar.api.measures.CoreMetrics;
+import org.sonar.api.measures.Measure;
+import org.sonar.api.resources.Directory;
+import org.sonar.api.resources.File;
+import org.sonar.api.resources.Java;
+import org.sonar.api.resources.Resource;
+
+public class AbstractFunctionComplexityDecoratorTest {
+
+ @Test
+ public void calculateFunctionComplexity() {
+
+ Resource directory = new Directory("fake");
+ DecoratorContext context = mock(DecoratorContext.class);
+ when(context.getMeasure(CoreMetrics.FUNCTIONS)).thenReturn(new Measure(CoreMetrics.FUNCTIONS, 200.0));
+ when(context.getMeasure(CoreMetrics.COMPLEXITY)).thenReturn(new Measure(CoreMetrics.COMPLEXITY, 500.0));
+
+ new AbstractFunctionComplexityDecorator(Java.INSTANCE) {
+ }.decorate(directory, context);
+
+ verify(context).saveMeasure(CoreMetrics.FUNCTION_COMPLEXITY, 2.5);
+ }
+
+ @Test
+ public void noAverageIfMissingData() {
+
+ DecoratorContext context = mock(DecoratorContext.class);
+ when(context.getMeasure(CoreMetrics.FUNCTIONS)).thenReturn(new Measure(CoreMetrics.FUNCTIONS, 20.0));
+ Resource directory = new Directory("fake");
+
+ new AbstractFunctionComplexityDecorator(Java.INSTANCE) {
+ }.decorate(directory, context);
+
+ verify(context, never()).saveMeasure(eq(CoreMetrics.FUNCTION_COMPLEXITY), anyDouble());
+ }
+
+ @Test
+ public void noAverageIfZeroFiles() {
+ AbstractFunctionComplexityDecorator decorator = new AbstractFunctionComplexityDecorator(Java.INSTANCE) {
+ };
+
+ Resource directory = new Directory("fake");
+ DecoratorContext context = mock(DecoratorContext.class);
+ when(context.getMeasure(CoreMetrics.FUNCTIONS)).thenReturn(new Measure(CoreMetrics.FUNCTIONS, 0.0));
+ when(context.getMeasure(CoreMetrics.COMPLEXITY)).thenReturn(new Measure(CoreMetrics.COMPLEXITY, 500.0));
+
+ decorator.decorate(directory, context);
+
+ verify(context, never()).saveMeasure(eq(CoreMetrics.FUNCTION_COMPLEXITY), anyDouble());
+ }
+
+ @Test
+ public void doNotCalculateOnFiles() {
+
+ Resource file = new File("fake");
+ DecoratorContext context = mock(DecoratorContext.class);
+ when(context.getMeasure(CoreMetrics.FUNCTIONS)).thenReturn(new Measure(CoreMetrics.FUNCTIONS, 1.0));
+ when(context.getMeasure(CoreMetrics.COMPLEXITY)).thenReturn(new Measure(CoreMetrics.COMPLEXITY, 25.0));
+
+ new AbstractFunctionComplexityDecorator(Java.INSTANCE) {
+ }.decorate(file, context);
+
+ verify(context).saveMeasure(eq(CoreMetrics.FUNCTION_COMPLEXITY), anyDouble());
+ }
+}
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/batch/AbstractSourceImporterTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/batch/AbstractSourceImporterTest.java
index d0048d72e0c..23a237c555d 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/batch/AbstractSourceImporterTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/batch/AbstractSourceImporterTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/batch/AbstractSumChildrenDecoratorTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/batch/AbstractSumChildrenDecoratorTest.java
index 90a4417dc4b..15eb4858607 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/batch/AbstractSumChildrenDecoratorTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/batch/AbstractSumChildrenDecoratorTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/batch/BatchExtensionDictionnaryTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/batch/BatchExtensionDictionnaryTest.java
index 267bdfdd468..210da5a4c59 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/batch/BatchExtensionDictionnaryTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/batch/BatchExtensionDictionnaryTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/batch/DefaultFormulaDataTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/batch/DefaultFormulaDataTest.java
index 8b526306754..e98ccf5d963 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/batch/DefaultFormulaDataTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/batch/DefaultFormulaDataTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/batch/SquidUtilsTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/batch/SquidUtilsTest.java
index 3b9d1a6ab6b..38378daf688 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/batch/SquidUtilsTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/batch/SquidUtilsTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/batch/TimeMachineQueryTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/batch/TimeMachineQueryTest.java
index 310f0ee739c..66637d92b83 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/batch/TimeMachineQueryTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/batch/TimeMachineQueryTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/batch/maven/MavenPluginTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/batch/maven/MavenPluginTest.java
index 92a12cd7704..e6dacbe1afc 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/batch/maven/MavenPluginTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/batch/maven/MavenPluginTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/batch/maven/MavenSurefireUtilsTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/batch/maven/MavenSurefireUtilsTest.java
index 195044b8b60..ffada43c8c8 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/batch/maven/MavenSurefireUtilsTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/batch/maven/MavenSurefireUtilsTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/batch/maven/MavenUtilsTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/batch/maven/MavenUtilsTest.java
index 8f52c63c927..06dc28eee49 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/batch/maven/MavenUtilsTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/batch/maven/MavenUtilsTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/charts/AbstractChartTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/charts/AbstractChartTest.java
index d9d265e7e3e..2a653d153e0 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/charts/AbstractChartTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/charts/AbstractChartTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/charts/ChartParametersTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/charts/ChartParametersTest.java
index 223d0f9b495..44f02154d80 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/charts/ChartParametersTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/charts/ChartParametersTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/checks/AnnotationCheckFactoryTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/checks/AnnotationCheckFactoryTest.java
index 9b0e286506c..396ec88653b 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/checks/AnnotationCheckFactoryTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/checks/AnnotationCheckFactoryTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/checks/CheckWithIntegerProperty.java b/sonar-plugin-api/src/test/java/org/sonar/api/checks/CheckWithIntegerProperty.java
index 3df303974ec..64858732615 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/checks/CheckWithIntegerProperty.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/checks/CheckWithIntegerProperty.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/checks/CheckWithKey.java b/sonar-plugin-api/src/test/java/org/sonar/api/checks/CheckWithKey.java
index ca8457d9ade..6d0587dc124 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/checks/CheckWithKey.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/checks/CheckWithKey.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/checks/CheckWithOverriddenPropertyKey.java b/sonar-plugin-api/src/test/java/org/sonar/api/checks/CheckWithOverriddenPropertyKey.java
index f1ecc47e0d3..6dbc137e72d 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/checks/CheckWithOverriddenPropertyKey.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/checks/CheckWithOverriddenPropertyKey.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/checks/CheckWithPrimitiveProperties.java b/sonar-plugin-api/src/test/java/org/sonar/api/checks/CheckWithPrimitiveProperties.java
index 35f3c7702ea..3b9669158c6 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/checks/CheckWithPrimitiveProperties.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/checks/CheckWithPrimitiveProperties.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/checks/CheckWithStringProperty.java b/sonar-plugin-api/src/test/java/org/sonar/api/checks/CheckWithStringProperty.java
index 0167652ca10..6ef9cf34293 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/checks/CheckWithStringProperty.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/checks/CheckWithStringProperty.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/checks/CheckWithUnsupportedPropertyType.java b/sonar-plugin-api/src/test/java/org/sonar/api/checks/CheckWithUnsupportedPropertyType.java
index 16f7fd36083..f5189b39d49 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/checks/CheckWithUnsupportedPropertyType.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/checks/CheckWithUnsupportedPropertyType.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/checks/CheckWithoutProperties.java b/sonar-plugin-api/src/test/java/org/sonar/api/checks/CheckWithoutProperties.java
index 6667ea9efb6..59c47ef159d 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/checks/CheckWithoutProperties.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/checks/CheckWithoutProperties.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/checks/NoSonarFilterTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/checks/NoSonarFilterTest.java
index bca7706b9c6..895c38bfc97 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/checks/NoSonarFilterTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/checks/NoSonarFilterTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/database/model/RuleFailureModelTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/database/model/RuleFailureModelTest.java
index 5f4d2e61fa8..776739af041 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/database/model/RuleFailureModelTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/database/model/RuleFailureModelTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/database/model/SnapshotTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/database/model/SnapshotTest.java
index 29458cb9fd7..a98ffe7835f 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/database/model/SnapshotTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/database/model/SnapshotTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/design/DependencyTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/design/DependencyTest.java
index 53702adb118..63815f8ec0f 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/design/DependencyTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/design/DependencyTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/measures/AverageComplexityFormulaTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/measures/AverageComplexityFormulaTest.java
index 6ab8cffe522..0739e62be46 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/measures/AverageComplexityFormulaTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/measures/AverageComplexityFormulaTest.java
@@ -1,130 +1,130 @@
-/*
- * Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
- * 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.api.measures;
-
-import com.google.common.collect.Lists;
-import org.junit.Before;
-import org.junit.Test;
-import org.sonar.api.resources.JavaFile;
-
-import java.util.List;
-
-import static junit.framework.Assert.assertNull;
-import static org.hamcrest.CoreMatchers.is;
-import static org.junit.Assert.assertThat;
-import static org.mockito.Mockito.mock;
-import static org.mockito.Mockito.when;
-
-public class AverageComplexityFormulaTest {
-
- private FormulaContext context;
- private FormulaData data;
-
- @Before
- public void before() {
- context = mock(FormulaContext.class);
- when(context.getTargetMetric()).thenReturn(CoreMetrics.FUNCTION_COMPLEXITY);
- data = mock(FormulaData.class);
- }
-
- @Test
- public void testAverageCalculation() {
- List<FormulaData> childrenData = Lists.newArrayList();
- FormulaData data1 = mock(FormulaData.class);
- childrenData.add(data1);
- when(data1.getMeasure(CoreMetrics.FUNCTIONS)).thenReturn(new Measure(CoreMetrics.FUNCTIONS, 43.0));
- when(data1.getMeasure(CoreMetrics.COMPLEXITY)).thenReturn(new Measure(CoreMetrics.FUNCTIONS, 107.0));
-
- FormulaData data2 = mock(FormulaData.class);
- childrenData.add(data2);
- when(data2.getMeasure(CoreMetrics.FUNCTIONS)).thenReturn(new Measure(CoreMetrics.FUNCTIONS, 127.0));
- when(data2.getMeasure(CoreMetrics.COMPLEXITY)).thenReturn(new Measure(CoreMetrics.FUNCTIONS, 233.0));
-
- when(data.getChildren()).thenReturn(childrenData);
-
- Measure measure = new AverageComplexityFormula(CoreMetrics.FUNCTIONS).calculate(data, context);
-
- assertThat(measure.getValue(), is(2.0));
- }
-
- @Test
- public void testWhenNoChildrenMesaures() {
- List<FormulaData> childrenData = Lists.newArrayList();
- when(data.getChildren()).thenReturn(childrenData);
- Measure measure = new AverageComplexityFormula(CoreMetrics.FUNCTIONS).calculate(data, context);
- assertNull(measure);
- }
-
- @Test
- public void testWhenNoComplexityMesaures() {
- List<FormulaData> childrenData = Lists.newArrayList();
- FormulaData data1 = mock(FormulaData.class);
- childrenData.add(data1);
- when(data1.getMeasure(CoreMetrics.FUNCTIONS)).thenReturn(new Measure(CoreMetrics.FUNCTIONS, 43.0));
-
- when(data.getChildren()).thenReturn(childrenData);
- Measure measure = new AverageComplexityFormula(CoreMetrics.FUNCTIONS).calculate(data, context);
-
- assertNull(measure);
- }
-
- @Test
- public void testWhenNoByMetricMesaures() {
- List<FormulaData> childrenData = Lists.newArrayList();
- FormulaData data1 = mock(FormulaData.class);
- childrenData.add(data1);
- when(data1.getMeasure(CoreMetrics.COMPLEXITY)).thenReturn(new Measure(CoreMetrics.COMPLEXITY, 43.0));
-
- when(data.getChildren()).thenReturn(childrenData);
- Measure measure = new AverageComplexityFormula(CoreMetrics.FUNCTIONS).calculate(data, context);
-
- assertNull(measure);
- }
-
- @Test
- public void testWhenMixedMetrics() {
- List<FormulaData> childrenData = Lists.newArrayList();
- FormulaData data1 = mock(FormulaData.class);
- childrenData.add(data1);
- when(data1.getMeasure(CoreMetrics.FUNCTIONS)).thenReturn(new Measure(CoreMetrics.FUNCTIONS, 43.0));
- when(data1.getMeasure(CoreMetrics.COMPLEXITY)).thenReturn(new Measure(CoreMetrics.FUNCTIONS, 107.0));
-
- FormulaData data2 = mock(FormulaData.class);
- childrenData.add(data2);
- when(data2.getMeasure(CoreMetrics.PARAGRAPHS)).thenReturn(new Measure(CoreMetrics.PARAGRAPHS, 127.0));
- when(data2.getMeasure(CoreMetrics.COMPLEXITY)).thenReturn(new Measure(CoreMetrics.FUNCTIONS, 233.0));
-
- when(data.getChildren()).thenReturn(childrenData);
-
- Measure measure = new AverageComplexityFormula(CoreMetrics.FUNCTIONS).calculate(data, context);
-
- assertThat(measure.getValue(), is(2.5));
- }
-
- @Test
- public void testCalculationForFIle() {
- when(data.getMeasure(CoreMetrics.COMPLEXITY)).thenReturn(new Measure(CoreMetrics.COMPLEXITY, 60.0));
- when(data.getMeasure(CoreMetrics.FUNCTIONS)).thenReturn(new Measure(CoreMetrics.FUNCTIONS, 20.0));
- when(context.getResource()).thenReturn(new JavaFile("foo"));
-
- Measure measure = new AverageComplexityFormula(CoreMetrics.FUNCTIONS).calculate(data, context);
- assertThat(measure.getValue(), is(3.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.api.measures;
+
+import com.google.common.collect.Lists;
+import org.junit.Before;
+import org.junit.Test;
+import org.sonar.api.resources.JavaFile;
+
+import java.util.List;
+
+import static junit.framework.Assert.assertNull;
+import static org.hamcrest.CoreMatchers.is;
+import static org.junit.Assert.assertThat;
+import static org.mockito.Mockito.mock;
+import static org.mockito.Mockito.when;
+
+public class AverageComplexityFormulaTest {
+
+ private FormulaContext context;
+ private FormulaData data;
+
+ @Before
+ public void before() {
+ context = mock(FormulaContext.class);
+ when(context.getTargetMetric()).thenReturn(CoreMetrics.FUNCTION_COMPLEXITY);
+ data = mock(FormulaData.class);
+ }
+
+ @Test
+ public void testAverageCalculation() {
+ List<FormulaData> childrenData = Lists.newArrayList();
+ FormulaData data1 = mock(FormulaData.class);
+ childrenData.add(data1);
+ when(data1.getMeasure(CoreMetrics.FUNCTIONS)).thenReturn(new Measure(CoreMetrics.FUNCTIONS, 43.0));
+ when(data1.getMeasure(CoreMetrics.COMPLEXITY)).thenReturn(new Measure(CoreMetrics.FUNCTIONS, 107.0));
+
+ FormulaData data2 = mock(FormulaData.class);
+ childrenData.add(data2);
+ when(data2.getMeasure(CoreMetrics.FUNCTIONS)).thenReturn(new Measure(CoreMetrics.FUNCTIONS, 127.0));
+ when(data2.getMeasure(CoreMetrics.COMPLEXITY)).thenReturn(new Measure(CoreMetrics.FUNCTIONS, 233.0));
+
+ when(data.getChildren()).thenReturn(childrenData);
+
+ Measure measure = new AverageComplexityFormula(CoreMetrics.FUNCTIONS).calculate(data, context);
+
+ assertThat(measure.getValue(), is(2.0));
+ }
+
+ @Test
+ public void testWhenNoChildrenMesaures() {
+ List<FormulaData> childrenData = Lists.newArrayList();
+ when(data.getChildren()).thenReturn(childrenData);
+ Measure measure = new AverageComplexityFormula(CoreMetrics.FUNCTIONS).calculate(data, context);
+ assertNull(measure);
+ }
+
+ @Test
+ public void testWhenNoComplexityMesaures() {
+ List<FormulaData> childrenData = Lists.newArrayList();
+ FormulaData data1 = mock(FormulaData.class);
+ childrenData.add(data1);
+ when(data1.getMeasure(CoreMetrics.FUNCTIONS)).thenReturn(new Measure(CoreMetrics.FUNCTIONS, 43.0));
+
+ when(data.getChildren()).thenReturn(childrenData);
+ Measure measure = new AverageComplexityFormula(CoreMetrics.FUNCTIONS).calculate(data, context);
+
+ assertNull(measure);
+ }
+
+ @Test
+ public void testWhenNoByMetricMesaures() {
+ List<FormulaData> childrenData = Lists.newArrayList();
+ FormulaData data1 = mock(FormulaData.class);
+ childrenData.add(data1);
+ when(data1.getMeasure(CoreMetrics.COMPLEXITY)).thenReturn(new Measure(CoreMetrics.COMPLEXITY, 43.0));
+
+ when(data.getChildren()).thenReturn(childrenData);
+ Measure measure = new AverageComplexityFormula(CoreMetrics.FUNCTIONS).calculate(data, context);
+
+ assertNull(measure);
+ }
+
+ @Test
+ public void testWhenMixedMetrics() {
+ List<FormulaData> childrenData = Lists.newArrayList();
+ FormulaData data1 = mock(FormulaData.class);
+ childrenData.add(data1);
+ when(data1.getMeasure(CoreMetrics.FUNCTIONS)).thenReturn(new Measure(CoreMetrics.FUNCTIONS, 43.0));
+ when(data1.getMeasure(CoreMetrics.COMPLEXITY)).thenReturn(new Measure(CoreMetrics.FUNCTIONS, 107.0));
+
+ FormulaData data2 = mock(FormulaData.class);
+ childrenData.add(data2);
+ when(data2.getMeasure(CoreMetrics.PARAGRAPHS)).thenReturn(new Measure(CoreMetrics.PARAGRAPHS, 127.0));
+ when(data2.getMeasure(CoreMetrics.COMPLEXITY)).thenReturn(new Measure(CoreMetrics.FUNCTIONS, 233.0));
+
+ when(data.getChildren()).thenReturn(childrenData);
+
+ Measure measure = new AverageComplexityFormula(CoreMetrics.FUNCTIONS).calculate(data, context);
+
+ assertThat(measure.getValue(), is(2.5));
+ }
+
+ @Test
+ public void testCalculationForFIle() {
+ when(data.getMeasure(CoreMetrics.COMPLEXITY)).thenReturn(new Measure(CoreMetrics.COMPLEXITY, 60.0));
+ when(data.getMeasure(CoreMetrics.FUNCTIONS)).thenReturn(new Measure(CoreMetrics.FUNCTIONS, 20.0));
+ when(context.getResource()).thenReturn(new JavaFile("foo"));
+
+ Measure measure = new AverageComplexityFormula(CoreMetrics.FUNCTIONS).calculate(data, context);
+ assertThat(measure.getValue(), is(3.0));
+ }
+}
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/measures/CountDistributionBuilderTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/measures/CountDistributionBuilderTest.java
index 2870e5911a9..8d793c1be21 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/measures/CountDistributionBuilderTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/measures/CountDistributionBuilderTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/measures/MeanAggregationFormulaTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/measures/MeanAggregationFormulaTest.java
index 1ff79ef1f8d..0d34d5bf5b1 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/measures/MeanAggregationFormulaTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/measures/MeanAggregationFormulaTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/measures/MeasureTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/measures/MeasureTest.java
index 430e2131e98..50f2a329574 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/measures/MeasureTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/measures/MeasureTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/measures/MeasureUtilsTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/measures/MeasureUtilsTest.java
index cb1a653f764..81faf56e385 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/measures/MeasureUtilsTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/measures/MeasureUtilsTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/measures/MeasuresFiltersTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/measures/MeasuresFiltersTest.java
index 7d0e417f734..82bb96efad2 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/measures/MeasuresFiltersTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/measures/MeasuresFiltersTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/measures/PersistenceModeTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/measures/PersistenceModeTest.java
index 0f5425013a4..1103978f5fc 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/measures/PersistenceModeTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/measures/PersistenceModeTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/measures/PropertiesBuilderTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/measures/PropertiesBuilderTest.java
index 6c2aa919f38..781e783bdcd 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/measures/PropertiesBuilderTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/measures/PropertiesBuilderTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/measures/RangeDistributionBuilderTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/measures/RangeDistributionBuilderTest.java
index fd51bc32fb7..cd26092601f 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/measures/RangeDistributionBuilderTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/measures/RangeDistributionBuilderTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/measures/RuleMeasureTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/measures/RuleMeasureTest.java
index 92c601e1d7f..12e25cb675a 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/measures/RuleMeasureTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/measures/RuleMeasureTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/measures/SumChildDistributionFormulaTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/measures/SumChildDistributionFormulaTest.java
index 6c6b6100c50..1e307e47237 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/measures/SumChildDistributionFormulaTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/measures/SumChildDistributionFormulaTest.java
@@ -1,141 +1,141 @@
-/*
- * Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
- * 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.api.measures;
-
-import com.google.common.collect.Lists;
-import org.junit.Before;
-import org.junit.Test;
-import org.sonar.api.resources.File;
-import org.sonar.api.resources.JavaFile;
-import org.sonar.api.resources.JavaPackage;
-import org.sonar.api.resources.Scopes;
-
-import java.util.Collections;
-import java.util.List;
-
-import static junit.framework.Assert.assertNull;
-import static org.hamcrest.CoreMatchers.is;
-import static org.hamcrest.CoreMatchers.nullValue;
-import static org.hamcrest.MatcherAssert.assertThat;
-import static org.mockito.Mockito.mock;
-import static org.mockito.Mockito.when;
-
-public class SumChildDistributionFormulaTest {
- SumChildDistributionFormula formula;
- FormulaContext context;
- FormulaData data;
-
- @Before
- public void init() {
- formula = new SumChildDistributionFormula();
- context = mock(FormulaContext.class);
- when(context.getResource()).thenReturn(new File("foo"));
- data = mock(FormulaData.class);
- }
-
- @Test
- public void testWhenGetChildrenReturnsNull() {
- when(context.getTargetMetric()).thenReturn(new Metric("foo"));
- when(data.getChildrenMeasures(new Metric("foo"))).thenReturn(null);
- assertNull(formula.calculate(data, context));
- }
-
- @Test
- public void testWhenGetChildrenReturnsEmpty() {
- when(context.getTargetMetric()).thenReturn(new Metric("foo"));
- when(data.getChildrenMeasures(new Metric("foo"))).thenReturn((List) Collections.emptyList());
- assertNull(formula.calculate(data, context));
- }
-
- @Test
- public void shouldNotSumDifferentRanges() {
- Metric m = new Metric("foo", Metric.ValueType.DATA);
- when(context.getTargetMetric()).thenReturn(m);
-
- List<Measure> list = Lists.newArrayList(
- new Measure(m, "1=0;2=2;5=0;10=10;20=2"),
- new Measure(m, "1=0;2=2;5=0;10=10;30=3")
- );
- when(data.getChildrenMeasures(new Metric("foo"))).thenReturn(list);
- assertThat(formula.calculate(data, context), nullValue());
- }
-
- @Test
- public void shouldSumSameIntRanges() {
- Metric m = new Metric("foo", Metric.ValueType.DATA);
- when(context.getTargetMetric()).thenReturn(m);
-
- List<Measure> list = Lists.newArrayList(
- new Measure(m, "1=0;2=2;5=0;10=10;20=2"),
- new Measure(m, "1=3;2=2;5=3;10=12;20=0")
- );
- when(data.getChildrenMeasures(new Metric("foo"))).thenReturn(list);
- assertThat(formula.calculate(data, context).getData(), is("1=3;2=4;5=3;10=22;20=2"));
- }
-
- @Test
- public void shouldSumSameDoubleRanges() {
- initContextWithChildren();
- assertThat(formula.calculate(data, context).getData(), is("0.5=3;2.5=6"));
- }
-
- @Test
- public void shouldNotPersistWhenScopeLowerThanMinimun() throws Exception {
- when(context.getResource()).thenReturn(JavaFile.fromRelativePath("org/Foo.java", false));
-
- initContextWithChildren();
- formula.setMinimumScopeToPersist(Scopes.DIRECTORY);
-
- Measure distribution = formula.calculate(data, context);
- assertThat(distribution.getPersistenceMode().useDatabase(), is(false));
- }
-
- @Test
- public void shouldPersistWhenScopeEqualsMinimun() throws Exception {
- when(context.getResource()).thenReturn(JavaFile.fromRelativePath("org/Foo.java", false));
-
- initContextWithChildren();
- formula.setMinimumScopeToPersist(Scopes.FILE);
-
- Measure distribution = formula.calculate(data, context);
- assertThat(distribution.getPersistenceMode().useDatabase(), is(true));
- }
-
- @Test
- public void shouldPersistWhenScopeHigherThanMinimun() throws Exception {
- when(context.getResource()).thenReturn(new JavaPackage("org.foo"));
-
- initContextWithChildren();
- formula.setMinimumScopeToPersist(Scopes.FILE);
-
- Measure distribution = formula.calculate(data, context);
- assertThat(distribution.getPersistenceMode().useDatabase(), is(true));
- }
-
- private void initContextWithChildren() {
- Metric m = new Metric("foo", Metric.ValueType.DATA);
- when(context.getTargetMetric()).thenReturn(m);
- List<Measure> list = Lists.newArrayList(
- new Measure(m, "0.5=0;2.5=2"),
- new Measure(m, "0.5=3;2.5=4")
- );
- when(data.getChildrenMeasures(new Metric("foo"))).thenReturn(list);
- }
-}
+/*
+ * 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.api.measures;
+
+import com.google.common.collect.Lists;
+import org.junit.Before;
+import org.junit.Test;
+import org.sonar.api.resources.File;
+import org.sonar.api.resources.JavaFile;
+import org.sonar.api.resources.JavaPackage;
+import org.sonar.api.resources.Scopes;
+
+import java.util.Collections;
+import java.util.List;
+
+import static junit.framework.Assert.assertNull;
+import static org.hamcrest.CoreMatchers.is;
+import static org.hamcrest.CoreMatchers.nullValue;
+import static org.hamcrest.MatcherAssert.assertThat;
+import static org.mockito.Mockito.mock;
+import static org.mockito.Mockito.when;
+
+public class SumChildDistributionFormulaTest {
+ SumChildDistributionFormula formula;
+ FormulaContext context;
+ FormulaData data;
+
+ @Before
+ public void init() {
+ formula = new SumChildDistributionFormula();
+ context = mock(FormulaContext.class);
+ when(context.getResource()).thenReturn(new File("foo"));
+ data = mock(FormulaData.class);
+ }
+
+ @Test
+ public void testWhenGetChildrenReturnsNull() {
+ when(context.getTargetMetric()).thenReturn(new Metric("foo"));
+ when(data.getChildrenMeasures(new Metric("foo"))).thenReturn(null);
+ assertNull(formula.calculate(data, context));
+ }
+
+ @Test
+ public void testWhenGetChildrenReturnsEmpty() {
+ when(context.getTargetMetric()).thenReturn(new Metric("foo"));
+ when(data.getChildrenMeasures(new Metric("foo"))).thenReturn((List) Collections.emptyList());
+ assertNull(formula.calculate(data, context));
+ }
+
+ @Test
+ public void shouldNotSumDifferentRanges() {
+ Metric m = new Metric("foo", Metric.ValueType.DATA);
+ when(context.getTargetMetric()).thenReturn(m);
+
+ List<Measure> list = Lists.newArrayList(
+ new Measure(m, "1=0;2=2;5=0;10=10;20=2"),
+ new Measure(m, "1=0;2=2;5=0;10=10;30=3")
+ );
+ when(data.getChildrenMeasures(new Metric("foo"))).thenReturn(list);
+ assertThat(formula.calculate(data, context), nullValue());
+ }
+
+ @Test
+ public void shouldSumSameIntRanges() {
+ Metric m = new Metric("foo", Metric.ValueType.DATA);
+ when(context.getTargetMetric()).thenReturn(m);
+
+ List<Measure> list = Lists.newArrayList(
+ new Measure(m, "1=0;2=2;5=0;10=10;20=2"),
+ new Measure(m, "1=3;2=2;5=3;10=12;20=0")
+ );
+ when(data.getChildrenMeasures(new Metric("foo"))).thenReturn(list);
+ assertThat(formula.calculate(data, context).getData(), is("1=3;2=4;5=3;10=22;20=2"));
+ }
+
+ @Test
+ public void shouldSumSameDoubleRanges() {
+ initContextWithChildren();
+ assertThat(formula.calculate(data, context).getData(), is("0.5=3;2.5=6"));
+ }
+
+ @Test
+ public void shouldNotPersistWhenScopeLowerThanMinimun() throws Exception {
+ when(context.getResource()).thenReturn(JavaFile.fromRelativePath("org/Foo.java", false));
+
+ initContextWithChildren();
+ formula.setMinimumScopeToPersist(Scopes.DIRECTORY);
+
+ Measure distribution = formula.calculate(data, context);
+ assertThat(distribution.getPersistenceMode().useDatabase(), is(false));
+ }
+
+ @Test
+ public void shouldPersistWhenScopeEqualsMinimun() throws Exception {
+ when(context.getResource()).thenReturn(JavaFile.fromRelativePath("org/Foo.java", false));
+
+ initContextWithChildren();
+ formula.setMinimumScopeToPersist(Scopes.FILE);
+
+ Measure distribution = formula.calculate(data, context);
+ assertThat(distribution.getPersistenceMode().useDatabase(), is(true));
+ }
+
+ @Test
+ public void shouldPersistWhenScopeHigherThanMinimun() throws Exception {
+ when(context.getResource()).thenReturn(new JavaPackage("org.foo"));
+
+ initContextWithChildren();
+ formula.setMinimumScopeToPersist(Scopes.FILE);
+
+ Measure distribution = formula.calculate(data, context);
+ assertThat(distribution.getPersistenceMode().useDatabase(), is(true));
+ }
+
+ private void initContextWithChildren() {
+ Metric m = new Metric("foo", Metric.ValueType.DATA);
+ when(context.getTargetMetric()).thenReturn(m);
+ List<Measure> list = Lists.newArrayList(
+ new Measure(m, "0.5=0;2.5=2"),
+ new Measure(m, "0.5=3;2.5=4")
+ );
+ when(data.getChildrenMeasures(new Metric("foo"))).thenReturn(list);
+ }
+}
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/measures/SumChildValuesFormulaTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/measures/SumChildValuesFormulaTest.java
index b4cd0d3c88e..db4b96ed33e 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/measures/SumChildValuesFormulaTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/measures/SumChildValuesFormulaTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/platform/EnvironmentTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/platform/EnvironmentTest.java
index 1ca9a50518f..81ecf2389c4 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/platform/EnvironmentTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/platform/EnvironmentTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/profiles/AnnotationProfileParserTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/profiles/AnnotationProfileParserTest.java
index f80beac42c7..997ba213b73 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/profiles/AnnotationProfileParserTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/profiles/AnnotationProfileParserTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/profiles/ProfileExporterTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/profiles/ProfileExporterTest.java
index 7db9a3f6897..f8955ead0ef 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/profiles/ProfileExporterTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/profiles/ProfileExporterTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/profiles/ProfileImporterTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/profiles/ProfileImporterTest.java
index f13af1eaae2..c21d8ce499f 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/profiles/ProfileImporterTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/profiles/ProfileImporterTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/profiles/RulesProfileTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/profiles/RulesProfileTest.java
index 0e54a3a824d..944805f866c 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/profiles/RulesProfileTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/profiles/RulesProfileTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/profiles/XMLProfileParserTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/profiles/XMLProfileParserTest.java
index 765c58ae667..1ec43920ffd 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/profiles/XMLProfileParserTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/profiles/XMLProfileParserTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/profiles/XMLProfileSerializerTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/profiles/XMLProfileSerializerTest.java
index 23df4ead208..e75d87e6a32 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/profiles/XMLProfileSerializerTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/profiles/XMLProfileSerializerTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/qualitymodel/CharacteristicPropertyTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/qualitymodel/CharacteristicPropertyTest.java
index 77062d8a372..73b08a80ddd 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/qualitymodel/CharacteristicPropertyTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/qualitymodel/CharacteristicPropertyTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/qualitymodel/CharacteristicTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/qualitymodel/CharacteristicTest.java
index 6d6a23ce5ea..16232faa310 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/qualitymodel/CharacteristicTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/qualitymodel/CharacteristicTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/qualitymodel/ModelTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/qualitymodel/ModelTest.java
index e9fcf8053ec..3f610c7d25a 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/qualitymodel/ModelTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/qualitymodel/ModelTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/resources/AbstractLanguageTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/resources/AbstractLanguageTest.java
index 7e673064348..8f1fbae73ef 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/resources/AbstractLanguageTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/resources/AbstractLanguageTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/resources/CoreMetricsTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/resources/CoreMetricsTest.java
index 7861c2cd2c5..4dbc3c59035 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/resources/CoreMetricsTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/resources/CoreMetricsTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/resources/DefaultProjectFileSystemTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/resources/DefaultProjectFileSystemTest.java
index 64733907b85..a32c84bc3dd 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/resources/DefaultProjectFileSystemTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/resources/DefaultProjectFileSystemTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/resources/DirectoryTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/resources/DirectoryTest.java
index cb10b2d7ef9..57a0e1d64c6 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/resources/DirectoryTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/resources/DirectoryTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/resources/FileTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/resources/FileTest.java
index 2e0f718b46c..e96122c5aa6 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/resources/FileTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/resources/FileTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/resources/JavaFileTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/resources/JavaFileTest.java
index 123a56ce252..33b597c7f68 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/resources/JavaFileTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/resources/JavaFileTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/resources/JavaPackageTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/resources/JavaPackageTest.java
index 827bbd55d61..7c157c591aa 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/resources/JavaPackageTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/resources/JavaPackageTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/resources/LanguagesTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/resources/LanguagesTest.java
index 1b621f2d092..d4eb5114704 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/resources/LanguagesTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/resources/LanguagesTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/resources/LibraryTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/resources/LibraryTest.java
index 473e127f384..92d9f8c2ea5 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/resources/LibraryTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/resources/LibraryTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/resources/ProjectLinkTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/resources/ProjectLinkTest.java
index 5d65d1e1aaa..32f682ae3cd 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/resources/ProjectLinkTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/resources/ProjectLinkTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/resources/ProjectTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/resources/ProjectTest.java
index 5ebd9565d24..d52bbd6a746 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/resources/ProjectTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/resources/ProjectTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/resources/QualifiersTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/resources/QualifiersTest.java
index 5927017cd95..f5c809c335b 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/resources/QualifiersTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/resources/QualifiersTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/resources/ResourceUtilsTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/resources/ResourceUtilsTest.java
index 319b2975954..a5240345f6d 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/resources/ResourceUtilsTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/resources/ResourceUtilsTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/resources/ScopesTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/resources/ScopesTest.java
index 71fff1d16e4..1cd288c5543 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/resources/ScopesTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/resources/ScopesTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/rules/AnnotatedCheck.java b/sonar-plugin-api/src/test/java/org/sonar/api/rules/AnnotatedCheck.java
index 38bd46e2149..c2439df2151 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/rules/AnnotatedCheck.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/rules/AnnotatedCheck.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/rules/AnnotatedCheckWithParameters.java b/sonar-plugin-api/src/test/java/org/sonar/api/rules/AnnotatedCheckWithParameters.java
index 9780f4b18a1..4e960708d25 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/rules/AnnotatedCheckWithParameters.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/rules/AnnotatedCheckWithParameters.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/rules/AnnotationRuleParserTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/rules/AnnotationRuleParserTest.java
index eb1258c82da..73a5185f57a 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/rules/AnnotationRuleParserTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/rules/AnnotationRuleParserTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/rules/DeprecatedAnnotatedCheck.java b/sonar-plugin-api/src/test/java/org/sonar/api/rules/DeprecatedAnnotatedCheck.java
index 8455d02e5ac..cc9e709eea9 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/rules/DeprecatedAnnotatedCheck.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/rules/DeprecatedAnnotatedCheck.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/rules/RuleAnnotationUtilsTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/rules/RuleAnnotationUtilsTest.java
index 455102461d1..0a715dafbf4 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/rules/RuleAnnotationUtilsTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/rules/RuleAnnotationUtilsTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/rules/RulePriorityTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/rules/RulePriorityTest.java
index a3ed40321b8..0751628b403 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/rules/RulePriorityTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/rules/RulePriorityTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/rules/RuleTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/rules/RuleTest.java
index 56285ed10f2..95d76b48ea0 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/rules/RuleTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/rules/RuleTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/rules/RuleUtilsTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/rules/RuleUtilsTest.java
index c60a5fdf604..d7256fd23a7 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/rules/RuleUtilsTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/rules/RuleUtilsTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/rules/XMLRuleParserTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/rules/XMLRuleParserTest.java
index dab65bfc564..bb76ef7a4c4 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/rules/XMLRuleParserTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/rules/XMLRuleParserTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/security/GroupRoleTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/security/GroupRoleTest.java
index db82ca57482..8de913abd9b 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/security/GroupRoleTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/security/GroupRoleTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/test/IsMeasure.java b/sonar-plugin-api/src/test/java/org/sonar/api/test/IsMeasure.java
index 4f738f15111..5156a28e931 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/test/IsMeasure.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/test/IsMeasure.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/test/IsResource.java b/sonar-plugin-api/src/test/java/org/sonar/api/test/IsResource.java
index 2dfb8cb7311..98df8d4a8a5 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/test/IsResource.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/test/IsResource.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/test/IsRuleMeasure.java b/sonar-plugin-api/src/test/java/org/sonar/api/test/IsRuleMeasure.java
index 8a86d4414ec..61469320dbb 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/test/IsRuleMeasure.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/test/IsRuleMeasure.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/test/IsViolation.java b/sonar-plugin-api/src/test/java/org/sonar/api/test/IsViolation.java
index cecea4005d6..f348ef3af87 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/test/IsViolation.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/test/IsViolation.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/test/MavenTestUtils.java b/sonar-plugin-api/src/test/java/org/sonar/api/test/MavenTestUtils.java
index 609d86cc913..6986d4bfe93 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/test/MavenTestUtils.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/test/MavenTestUtils.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/test/ProjectTestBuilder.java b/sonar-plugin-api/src/test/java/org/sonar/api/test/ProjectTestBuilder.java
index 895c29a436d..47725aebd79 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/test/ProjectTestBuilder.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/test/ProjectTestBuilder.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/test/SimpleProjectFileSystem.java b/sonar-plugin-api/src/test/java/org/sonar/api/test/SimpleProjectFileSystem.java
index 32e7670176a..0f2ba88c5db 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/test/SimpleProjectFileSystem.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/test/SimpleProjectFileSystem.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/utils/AnnotationUtilsTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/utils/AnnotationUtilsTest.java
index b29a86787c9..55ff0903f19 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/utils/AnnotationUtilsTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/utils/AnnotationUtilsTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/utils/FakeServlet.java b/sonar-plugin-api/src/test/java/org/sonar/api/utils/FakeServlet.java
index 9bf5eda61a2..c9862e79ea7 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/utils/FakeServlet.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/utils/FakeServlet.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/utils/HttpDownloaderTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/utils/HttpDownloaderTest.java
index 18324b4e799..9378f5be342 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/utils/HttpDownloaderTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/utils/HttpDownloaderTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/utils/IocContainerTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/utils/IocContainerTest.java
index 08fa942029d..abe3578c40c 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/utils/IocContainerTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/utils/IocContainerTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/utils/KeyValueFormatTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/utils/KeyValueFormatTest.java
index 61cb7f02a52..6c041417eca 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/utils/KeyValueFormatTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/utils/KeyValueFormatTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/utils/LocalizedMessagesTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/utils/LocalizedMessagesTest.java
index 0d7f35b79b8..038462a914e 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/utils/LocalizedMessagesTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/utils/LocalizedMessagesTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/utils/ManifestUtilsTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/utils/ManifestUtilsTest.java
index c7a5870e602..f95d5a91b5d 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/utils/ManifestUtilsTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/utils/ManifestUtilsTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/utils/ParsingUtilsTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/utils/ParsingUtilsTest.java
index c589230007d..8f90ceeb1f7 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/utils/ParsingUtilsTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/utils/ParsingUtilsTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/utils/RedirectServlet.java b/sonar-plugin-api/src/test/java/org/sonar/api/utils/RedirectServlet.java
index 902bb45932f..a46d1f94f31 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/utils/RedirectServlet.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/utils/RedirectServlet.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/utils/ServerHttpClientTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/utils/ServerHttpClientTest.java
index f5108fd9c80..1798123d7c1 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/utils/ServerHttpClientTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/utils/ServerHttpClientTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/utils/StaxParserTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/utils/StaxParserTest.java
index cafb64169ed..ed916e1ee98 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/utils/StaxParserTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/utils/StaxParserTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/utils/TempFileUtilsTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/utils/TempFileUtilsTest.java
index a6a48a303bf..034d052f0ed 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/utils/TempFileUtilsTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/utils/TempFileUtilsTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/utils/TimeProfilerTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/utils/TimeProfilerTest.java
index a46e941549c..bc82b2c529f 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/utils/TimeProfilerTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/utils/TimeProfilerTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/utils/ValidationMessagesTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/utils/ValidationMessagesTest.java
index ea52c4c3c73..f202e439b1b 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/utils/ValidationMessagesTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/utils/ValidationMessagesTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/utils/WildcardPatternTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/utils/WildcardPatternTest.java
index 970544c7152..98396d0e4a5 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/utils/WildcardPatternTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/utils/WildcardPatternTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/utils/XpathParserTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/utils/XpathParserTest.java
index 7a1ddd71926..aca0ef5c75e 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/utils/XpathParserTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/utils/XpathParserTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/utils/ZipUtilsTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/utils/ZipUtilsTest.java
index 62a00f11e01..024d994f7a5 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/utils/ZipUtilsTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/utils/ZipUtilsTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/utils/dag/DirectAcyclicGraphTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/utils/dag/DirectAcyclicGraphTest.java
index 599c8b5c8ef..f255a1a9a59 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/utils/dag/DirectAcyclicGraphTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/utils/dag/DirectAcyclicGraphTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/web/AbstractRubyTemplateTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/web/AbstractRubyTemplateTest.java
index 03fe60171a8..3f300194c61 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/web/AbstractRubyTemplateTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/web/AbstractRubyTemplateTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/web/CodeColorizerFormatTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/web/CodeColorizerFormatTest.java
index 142262ee0a5..a6b9dc1702d 100644
--- a/sonar-plugin-api/src/test/java/org/sonar/api/web/CodeColorizerFormatTest.java
+++ b/sonar-plugin-api/src/test/java/org/sonar/api/web/CodeColorizerFormatTest.java
@@ -1,6 +1,6 @@
/*
* Sonar, open source software quality management tool.
- * Copyright (C) 2009 SonarSource SA
+ * Copyright (C) 2008-2011 SonarSource
* mailto:contact AT sonarsource DOT com
*
* Sonar is free software; you can redistribute it and/or