diff --git a/maven-plugin-testing-harness/src/main/java/org/apache/maven/plugin/testing/ConfigurationException.java b/maven-plugin-testing-harness/src/main/java/org/apache/maven/plugin/testing/ConfigurationException.java index 0f84d4e..3b85c8f 100644 --- a/maven-plugin-testing-harness/src/main/java/org/apache/maven/plugin/testing/ConfigurationException.java +++ b/maven-plugin-testing-harness/src/main/java/org/apache/maven/plugin/testing/ConfigurationException.java @@ -25,20 +25,34 @@ package org.apache.maven.plugin.testing; * @author jesse * @version $Id$ */ -public class ConfigurationException extends Exception +public class ConfigurationException + extends Exception { + /** serialVersionUID */ + static final long serialVersionUID = -6180939638742159065L; + + /** + * @param message The detailed message. + */ public ConfigurationException( String message ) { - super(message); + super( message ); } + /** + * @param cause The detailed cause. + */ public ConfigurationException( Throwable cause ) { - super(cause); + super( cause ); } + /** + * @param message The detailed message. + * @param cause The detailed cause. + */ public ConfigurationException( String message, Throwable cause ) { - super(message, cause); + super( message, cause ); } } diff --git a/maven-plugin-testing-harness/src/main/java/org/apache/maven/plugin/testing/stubs/StubArtifactResolver.java b/maven-plugin-testing-harness/src/main/java/org/apache/maven/plugin/testing/stubs/StubArtifactResolver.java index bbec69d..bf0df6c 100644 --- a/maven-plugin-testing-harness/src/main/java/org/apache/maven/plugin/testing/stubs/StubArtifactResolver.java +++ b/maven-plugin-testing-harness/src/main/java/org/apache/maven/plugin/testing/stubs/StubArtifactResolver.java @@ -65,13 +65,10 @@ public class StubArtifactResolver this.factory = factory; } - /* + /** * Creates dummy file and sets it in the artifact to simulate resolution - * (non-Javadoc) * - * @see org.apache.maven.artifact.resolver.ArtifactResolver#resolve(org.apache.maven.artifact.Artifact, - * java.util.List, - * org.apache.maven.artifact.repository.ArtifactRepository) + * @see org.apache.maven.artifact.resolver.ArtifactResolver#resolve(org.apache.maven.artifact.Artifact, java.util.List, org.apache.maven.artifact.repository.ArtifactRepository) */ public void resolve( Artifact artifact, List remoteRepositories, ArtifactRepository localRepository ) throws ArtifactResolutionException, ArtifactNotFoundException diff --git a/maven-plugin-testing-harness/src/test/java/org/apache/maven/plugin/testing/ArtifactStubFactoryTest.java b/maven-plugin-testing-harness/src/test/java/org/apache/maven/plugin/testing/ArtifactStubFactoryTest.java index a1ed447..75d7836 100644 --- a/maven-plugin-testing-harness/src/test/java/org/apache/maven/plugin/testing/ArtifactStubFactoryTest.java +++ b/maven-plugin-testing-harness/src/test/java/org/apache/maven/plugin/testing/ArtifactStubFactoryTest.java @@ -1,5 +1,24 @@ package org.apache.maven.plugin.testing; +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + import java.io.IOException; import junit.framework.TestCase; @@ -14,9 +33,8 @@ public class ArtifactStubFactoryTest assertFalse(factory.getReleaseArtifact().isSnapshot()); assertTrue(factory.getSnapshotArtifact().isSnapshot()); assertFalse(factory.getSnapshotArtifact().isRelease()); - } - + public void testCreateFiles() throws IOException { ArtifactStubFactory factory = new ArtifactStubFactory(); diff --git a/maven-plugin-testing-harness/src/test/java/org/apache/maven/plugin/testing/ExpressionEvaluatorMojo.java b/maven-plugin-testing-harness/src/test/java/org/apache/maven/plugin/testing/ExpressionEvaluatorMojo.java index a884f07..e57c14d 100644 --- a/maven-plugin-testing-harness/src/test/java/org/apache/maven/plugin/testing/ExpressionEvaluatorMojo.java +++ b/maven-plugin-testing-harness/src/test/java/org/apache/maven/plugin/testing/ExpressionEvaluatorMojo.java @@ -38,6 +38,7 @@ public class ExpressionEvaluatorMojo private String workdir; + /** {@inheritDoc} */ public void execute() throws MojoExecutionException, MojoFailureException { diff --git a/maven-plugin-testing-harness/src/test/java/org/apache/maven/plugin/testing/ExpressionEvaluatorTest.java b/maven-plugin-testing-harness/src/test/java/org/apache/maven/plugin/testing/ExpressionEvaluatorTest.java index 51d2b94..2c8fe05 100644 --- a/maven-plugin-testing-harness/src/test/java/org/apache/maven/plugin/testing/ExpressionEvaluatorTest.java +++ b/maven-plugin-testing-harness/src/test/java/org/apache/maven/plugin/testing/ExpressionEvaluatorTest.java @@ -37,6 +37,7 @@ public class ExpressionEvaluatorTest private PlexusConfiguration pluginConfiguration; + /** {@inheritDoc} */ protected void setUp() throws Exception { @@ -64,6 +65,9 @@ public class ExpressionEvaluatorTest pluginConfiguration = extractPluginConfiguration( "maven-test-mojo", pomDom ); } + /** + * @throws Exception if any + */ public void testInjection() throws Exception { diff --git a/maven-plugin-testing-harness/src/test/java/org/apache/maven/plugin/testing/MojoTestCaseTest.java b/maven-plugin-testing-harness/src/test/java/org/apache/maven/plugin/testing/MojoTestCaseTest.java index 84c8835..e3b190c 100644 --- a/maven-plugin-testing-harness/src/test/java/org/apache/maven/plugin/testing/MojoTestCaseTest.java +++ b/maven-plugin-testing-harness/src/test/java/org/apache/maven/plugin/testing/MojoTestCaseTest.java @@ -39,6 +39,7 @@ public class MojoTestCaseTest private PlexusConfiguration pluginConfiguration; + /** {@inheritDoc} */ protected void setUp() throws Exception { @@ -64,6 +65,9 @@ public class MojoTestCaseTest pluginConfiguration = extractPluginConfiguration( "maven-simple-plugin", pomDom ); } + /** + * @throws Exception if any + */ public void testPluginConfigurationExtraction() throws Exception { @@ -72,6 +76,9 @@ public class MojoTestCaseTest assertEquals( "valueTwo", pluginConfiguration.getChild( "keyTwo" ).getValue() ); } + /** + * @throws Exception if any + */ public void testMojoConfiguration() throws Exception { @@ -84,6 +91,9 @@ public class MojoTestCaseTest assertEquals( "valueTwo", mojo.getKeyTwo() ); } + /** + * @throws Exception if any + */ public void testVariableAccessWithoutGetter() throws Exception { @@ -96,7 +106,9 @@ public class MojoTestCaseTest assertEquals( "valueTwo", (String)getVariableValueFromObject( mojo, "keyTwo" ) ); } - + /** + * @throws Exception if any + */ public void testVariableAccessWithoutGetter2() throws Exception { @@ -111,7 +123,9 @@ public class MojoTestCaseTest assertEquals( "valueTwo", (String)map.get( "keyTwo" ) ); } - + /** + * @throws Exception if any + */ public void testSettingMojoVariables() throws Exception {