You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@ant.apache.org by bo...@apache.org on 2016/03/29 18:18:43 UTC
[3/3] ant-antlibs-antunit git commit: make javadoc8 happy
make javadoc8 happy
Project: http://git-wip-us.apache.org/repos/asf/ant-antlibs-antunit/repo
Commit: http://git-wip-us.apache.org/repos/asf/ant-antlibs-antunit/commit/ac56fd46
Tree: http://git-wip-us.apache.org/repos/asf/ant-antlibs-antunit/tree/ac56fd46
Diff: http://git-wip-us.apache.org/repos/asf/ant-antlibs-antunit/diff/ac56fd46
Branch: refs/heads/master
Commit: ac56fd4677ed0ed210e370eb81f68255e515e0c3
Parents: 08b3a72
Author: Stefan Bodewig <bo...@apache.org>
Authored: Tue Mar 29 18:18:20 2016 +0200
Committer: Stefan Bodewig <bo...@apache.org>
Committed: Tue Mar 29 18:18:20 2016 +0200
----------------------------------------------------------------------
src/main/org/apache/ant/antunit/AntUnit.java | 14 +++++++--
.../org/apache/ant/antunit/AntUnitListener.java | 14 ++++++++-
.../apache/ant/antunit/AntUnitScriptRunner.java | 12 ++++----
src/main/org/apache/ant/antunit/AssertTask.java | 5 ++--
.../apache/ant/antunit/ExpectFailureTask.java | 4 ++-
.../org/apache/ant/antunit/LogCapturer.java | 10 +++++++
.../org/apache/ant/antunit/LogContains.java | 3 ++
src/main/org/apache/ant/antunit/LogContent.java | 11 ++++---
.../org/apache/ant/antunit/ProjectFactory.java | 11 +++----
.../org/apache/ant/antunit/ResourceExists.java | 3 ++
.../apache/ant/antunit/junit3/AntUnitSuite.java | 18 ++++++------
.../ant/antunit/junit3/AntUnitTestCase.java | 30 +++++++++++---------
.../ant/antunit/junit3/ErrorTestCase.java | 3 --
.../ant/antunit/junit4/AntUnitSuiteRunner.java | 10 +++----
.../antunit/listener/BaseAntUnitListener.java | 11 +++++--
.../listener/FailureAntUnitListener.java | 2 +-
.../ant/antunit/listener/XMLConstants.java | 6 ++--
17 files changed, 111 insertions(+), 56 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/ant-antlibs-antunit/blob/ac56fd46/src/main/org/apache/ant/antunit/AntUnit.java
----------------------------------------------------------------------
diff --git a/src/main/org/apache/ant/antunit/AntUnit.java b/src/main/org/apache/ant/antunit/AntUnit.java
index fa652dd..a074166 100644
--- a/src/main/org/apache/ant/antunit/AntUnit.java
+++ b/src/main/org/apache/ant/antunit/AntUnit.java
@@ -176,6 +176,7 @@ public class AntUnit extends Task {
/**
* Add a set of inherited references.
+ * @return set of inherited references
*/
public ReferenceSet createReferenceSet() {
ReferenceSet set = new ReferenceSet();
@@ -185,7 +186,8 @@ public class AntUnit extends Task {
}
/**
- * Add an inherited reference
+ * Add an inherited reference.
+ * @param reference inherited reference
*/
public void addReference(Reference reference) {
//wrap in a singleton reference set.
@@ -478,7 +480,12 @@ public class AntUnit extends Task {
}
}
- /** configure a single mapper to translate reference IDs */
+ /**
+ * Configure a single mapper to translate reference IDs.
+ * @param typeName the mapper type
+ * @param from the from attribute
+ * @param to the to attribute
+ */
public void setMapper(String typeName, String from, String to) {
Mapper mapper = createMapper();
Mapper.MapperType type = new Mapper.MapperType();
@@ -493,6 +500,7 @@ public class AntUnit extends Task {
* Copy all identified references into the target project,
* applying any name mapping required by a nested mapper
* element.
+ * @param newProject the target project to copy references into
*/
public void copyReferencesInto(Project newProject) {
FileNameMapper mapper = this.mapper == null
@@ -597,7 +605,7 @@ public class AntUnit extends Task {
/**
* Set a regular expression to match references.
- * @param regex
+ * @param regex the regular expression
*/
public void setRegex(String regex) {
this.regex = regex;
http://git-wip-us.apache.org/repos/asf/ant-antlibs-antunit/blob/ac56fd46/src/main/org/apache/ant/antunit/AntUnitListener.java
----------------------------------------------------------------------
diff --git a/src/main/org/apache/ant/antunit/AntUnitListener.java b/src/main/org/apache/ant/antunit/AntUnitListener.java
index 828088c..0a52fcb 100644
--- a/src/main/org/apache/ant/antunit/AntUnitListener.java
+++ b/src/main/org/apache/ant/antunit/AntUnitListener.java
@@ -31,6 +31,7 @@ public interface AntUnitListener {
* Set a reference to the AntUnit task executing the tests, this
* provides access to the containing project, target or Ant's
* logging system.
+ * @param t the parent task
*/
void setParentTask(Task t);
/**
@@ -40,31 +41,42 @@ public interface AntUnitListener {
* <p>This provides access to the logging system or the properties
* of the project under test. Note that different test targets
* will be executed in different Ant Project instances.</p>
+ * @param p the test project
*/
void setCurrentTestProject(Project p);
/**
* Invoked once per build file, before any targets get executed.
+ * @param testProject the project
+ * @param buildFile the build file
*/
void startTestSuite(Project testProject, String buildFile);
/**
* Invoked once per build file, after all targets have been executed.
+ * @param testProject the project
+ * @param buildFile the build file
*/
void endTestSuite(Project testProject, String buildFile);
/**
* Invoked before a test target gets executed.
+ * @param target name of the target
*/
void startTest(String target);
/**
* Invoked after a test target has been executed.
+ * @param target name of the target
*/
void endTest(String target);
/**
* Invoked if an assert tasked caused an error during execution.
+ * @param target name of the target
+ * @param ae the failure
*/
void addFailure(String target, AssertionFailedException ae);
/**
* Invoked if any error other than a failed assertion occured
* during execution.
+ * @param target name of the target
+ * @param ae the error
*/
void addError(String target, Throwable ae);
-}
\ No newline at end of file
+}
http://git-wip-us.apache.org/repos/asf/ant-antlibs-antunit/blob/ac56fd46/src/main/org/apache/ant/antunit/AntUnitScriptRunner.java
----------------------------------------------------------------------
diff --git a/src/main/org/apache/ant/antunit/AntUnitScriptRunner.java b/src/main/org/apache/ant/antunit/AntUnitScriptRunner.java
index 6d49f91..a5b92a8 100644
--- a/src/main/org/apache/ant/antunit/AntUnitScriptRunner.java
+++ b/src/main/org/apache/ant/antunit/AntUnitScriptRunner.java
@@ -141,6 +141,7 @@ public class AntUnitScriptRunner {
* Get the project currently in use. The caller is not allowed to invoke a target or
* do anything that would break the isolation of the test targets.
* @throws BuildException The project can not be parsed
+ * @return the current project
*/
public final Project getCurrentProject() throws BuildException {
//Method is final because it is called from the constructor
@@ -165,7 +166,7 @@ public class AntUnitScriptRunner {
}
/**
- * @return List<String> List of test targets of the script file
+ * @return List<String> List of test targets of the script file
*/
public List getTestTartgets() {
return testTargets;
@@ -173,6 +174,7 @@ public class AntUnitScriptRunner {
/**
* Provides the name of the active script.
+ * @return name of the project
*/
public String getName() {
return getCurrentProject().getName();
@@ -180,8 +182,8 @@ public class AntUnitScriptRunner {
/**
* Executes the suiteSetUp target if presents and report any execution error.
- * A failure is reported to the notifier and by returning false.
- * Note that if the method return false, you are not allowed to run targets.
+ * <p>A failure is reported to the notifier and by returning false.
+ * Note that if the method return false, you are not allowed to run targets.</p>
* @return false in case of execution failure. true in case of success.
*/
private boolean startSuite(AntUnitExecutionNotifier notifier) {
@@ -289,7 +291,7 @@ public class AntUnitScriptRunner {
/**
* Executes the suite.
* @param suiteTargets An ordered list of test targets. It must be a sublist of getTestTargets
- * @param notifier
+ * @param notifier is notified on test progress
*/
public void runSuite(List suiteTargets, AntUnitExecutionNotifier notifier) {
Throwable caught = null;
@@ -309,4 +311,4 @@ public class AntUnitScriptRunner {
}
}
-}
\ No newline at end of file
+}
http://git-wip-us.apache.org/repos/asf/ant-antlibs-antunit/blob/ac56fd46/src/main/org/apache/ant/antunit/AssertTask.java
----------------------------------------------------------------------
diff --git a/src/main/org/apache/ant/antunit/AssertTask.java b/src/main/org/apache/ant/antunit/AssertTask.java
index 45ca462..837051f 100644
--- a/src/main/org/apache/ant/antunit/AssertTask.java
+++ b/src/main/org/apache/ant/antunit/AssertTask.java
@@ -28,7 +28,7 @@ import org.apache.tools.ant.taskdefs.condition.ConditionBase;
* Exits the active build, giving an additional message if the single
* nested condition fails or if there is no condition at all.
*
- * <p>This one could as well be implemented as
+ * <p>This one could as well be implemented as</p>
*
* <pre>
* <macrodef name="assertTrue">
@@ -44,7 +44,7 @@ import org.apache.tools.ant.taskdefs.condition.ConditionBase;
* </macrodef>
* </pre>
*
- * but wouldn't be able to throw a specialized exception that way -
+ * <p>but wouldn't be able to throw a specialized exception that way -
* and the macrodef would nest the exception in yet another
* BuildException.</p>
*/
@@ -57,6 +57,7 @@ public class AssertTask extends ConditionBase {
/**
* Message to use when the assertion fails.
+ * @param value message to use when the assertion fails
*/
public void setMessage(String value) {
this.message = value;
http://git-wip-us.apache.org/repos/asf/ant-antlibs-antunit/blob/ac56fd46/src/main/org/apache/ant/antunit/ExpectFailureTask.java
----------------------------------------------------------------------
diff --git a/src/main/org/apache/ant/antunit/ExpectFailureTask.java b/src/main/org/apache/ant/antunit/ExpectFailureTask.java
index 59c59bf..2d8699d 100644
--- a/src/main/org/apache/ant/antunit/ExpectFailureTask.java
+++ b/src/main/org/apache/ant/antunit/ExpectFailureTask.java
@@ -37,6 +37,7 @@ public class ExpectFailureTask extends Sequential {
/**
* The exception message to expect.
+ * @param m the exception message to expect
*/
public void setExpectedMessage(String m) {
expectedMessage = m;
@@ -45,6 +46,7 @@ public class ExpectFailureTask extends Sequential {
/**
* The message to use in the AssertionFailedException if the nested
* tasks fail to raise the "correct" exception.
+ * @param m message to use in the AssertionFailedException
*/
public void setMessage(String m) {
message = m;
@@ -81,4 +83,4 @@ public class ExpectFailureTask extends Sequential {
}
}
}
-}
\ No newline at end of file
+}
http://git-wip-us.apache.org/repos/asf/ant-antlibs-antunit/blob/ac56fd46/src/main/org/apache/ant/antunit/LogCapturer.java
----------------------------------------------------------------------
diff --git a/src/main/org/apache/ant/antunit/LogCapturer.java b/src/main/org/apache/ant/antunit/LogCapturer.java
index 85ce623..3dee342 100644
--- a/src/main/org/apache/ant/antunit/LogCapturer.java
+++ b/src/main/org/apache/ant/antunit/LogCapturer.java
@@ -52,6 +52,7 @@ public class LogCapturer implements BuildListener {
/**
* All messages with <code>logLevel == Project.MSG_ERR</code>
* merging messages into a single line.
+ * @return All messages with <code>logLevel == Project.MSG_ERR</code>
*/
public String getErrLog() {
return getErrLog(true);
@@ -59,6 +60,7 @@ public class LogCapturer implements BuildListener {
/**
* All messages with <code>logLevel == Project.MSG_WARN</code> or
* more severe merging messages into a single line.
+ * @return All messages with <code>logLevel == Project.MSG_WARN</code> or above
*/
public String getWarnLog() {
return getWarnLog(true);
@@ -66,6 +68,7 @@ public class LogCapturer implements BuildListener {
/**
* All messages with <code>logLevel == Project.MSG_INFO</code> or
* more severe merging messages into a single line.
+ * @return All messages with <code>logLevel == Project.MSG_INFO</code> or above
*/
public String getInfoLog() {
return getInfoLog(true);
@@ -73,6 +76,7 @@ public class LogCapturer implements BuildListener {
/**
* All messages with <code>logLevel == Project.MSG_VERBOSE</code> or
* more severe merging messages into a single line.
+ * @return All messages with <code>logLevel == Project.MSG_VERBOSE</code> or above
*/
public String getVerboseLog() {
return getVerboseLog(true);
@@ -80,6 +84,7 @@ public class LogCapturer implements BuildListener {
/**
* All messages with <code>logLevel == Project.MSG_DEBUG</code> or
* more severe merging messages into a single line.
+ * @return All messages with <code>logLevel == Project.MSG_DEBUG</code> or above
*/
public String getDebugLog() {
return getDebugLog(true);
@@ -89,6 +94,7 @@ public class LogCapturer implements BuildListener {
* All messages with <code>logLevel == Project.MSG_ERR</code>.
* @param mergeLines whether to merge messages into a single line
* or split them into multiple lines
+ * @return All messages with <code>logLevel == Project.MSG_ERR</code>
*/
public String getErrLog(boolean mergeLines) {
return getLog(Project.MSG_ERR, mergeLines);
@@ -98,6 +104,7 @@ public class LogCapturer implements BuildListener {
* more severe.
* @param mergeLines whether to merge messages into a single line
* or split them into multiple lines
+ * @return All messages with <code>logLevel == Project.MSG_WARN</code> or above
* @since AntUnit 1.3
*/
public String getWarnLog(boolean mergeLines) {
@@ -108,6 +115,7 @@ public class LogCapturer implements BuildListener {
* more severe.
* @param mergeLines whether to merge messages into a single line
* or split them into multiple lines
+ * @return All messages with <code>logLevel == Project.MSG_INFO</code> or above
* @since AntUnit 1.3
*/
public String getInfoLog(boolean mergeLines) {
@@ -118,6 +126,7 @@ public class LogCapturer implements BuildListener {
* more severe.
* @param mergeLines whether to merge messages into a single line
* or split them into multiple lines
+ * @return All messages with <code>logLevel == Project.MSG_VERBOSE</code> or above
* @since AntUnit 1.3
*/
public String getVerboseLog(boolean mergeLines) {
@@ -128,6 +137,7 @@ public class LogCapturer implements BuildListener {
* more severe.
* @param mergeLines whether to merge messages into a single line
* or split them into multiple lines
+ * @return All messages with <code>logLevel == Project.MSG_DEBUG</code> or above
* @since AntUnit 1.3
*/
public String getDebugLog(boolean mergeLines) {
http://git-wip-us.apache.org/repos/asf/ant-antlibs-antunit/blob/ac56fd46/src/main/org/apache/ant/antunit/LogContains.java
----------------------------------------------------------------------
diff --git a/src/main/org/apache/ant/antunit/LogContains.java b/src/main/org/apache/ant/antunit/LogContains.java
index 0a491c3..7a11396 100644
--- a/src/main/org/apache/ant/antunit/LogContains.java
+++ b/src/main/org/apache/ant/antunit/LogContains.java
@@ -41,6 +41,7 @@ public class LogContains extends ProjectComponent implements Condition {
/**
* Test the log shall contain.
+ * @param t text to look for
*/
public void setText(String t) {
text = t;
@@ -48,6 +49,7 @@ public class LogContains extends ProjectComponent implements Condition {
/**
* minimal log priority to consult.
+ * @param echoLevel minimal log priority
*/
public void setLevel(Echo.EchoLevel echoLevel) {
logLevel = echoLevel.getLevel();
@@ -57,6 +59,7 @@ public class LogContains extends ProjectComponent implements Condition {
* Whether to merge messages into a single line or split them into
* multiple lines.
* @since AntUnit 1.3
+ * @param b whether to merge messages into a single line
*/
public void setMergeLines(boolean b) {
mergeLines = b;
http://git-wip-us.apache.org/repos/asf/ant-antlibs-antunit/blob/ac56fd46/src/main/org/apache/ant/antunit/LogContent.java
----------------------------------------------------------------------
diff --git a/src/main/org/apache/ant/antunit/LogContent.java b/src/main/org/apache/ant/antunit/LogContent.java
index 37ca189..590fe67 100644
--- a/src/main/org/apache/ant/antunit/LogContent.java
+++ b/src/main/org/apache/ant/antunit/LogContent.java
@@ -45,8 +45,9 @@ public class LogContent extends Resource {
/**
* Create a new LogContent resource, specifying Project and log level.
- * This constructor is provided primarily for convenience during
- * programmatic usage.
+ * <p>This constructor is provided primarily for convenience during
+ * programmatic usage.</p>
+ * @param p the test project
* @param level the LogLevel.
*/
public LogContent(Project p, LogLevel level) {
@@ -55,8 +56,9 @@ public class LogContent extends Resource {
/**
* Create a new LogContent resource, specifying Project and log level.
- * This constructor is provided primarily for convenience during
- * programmatic usage.
+ * <p>This constructor is provided primarily for convenience during
+ * programmatic usage.</p>
+ * @param p the test project
* @param level the LogLevel.
* @param mergeLines whether to merge messages into a single line
* or split them into multiple lines
@@ -81,6 +83,7 @@ public class LogContent extends Resource {
* Whether to merge messages into a single line or split them into
* multiple lines.
* @since AntUnit 1.3
+ * @param b whether to merge messages into a single line
*/
public final void setMergeLines(boolean b) {
mergeLines = b;
http://git-wip-us.apache.org/repos/asf/ant-antlibs-antunit/blob/ac56fd46/src/main/org/apache/ant/antunit/ProjectFactory.java
----------------------------------------------------------------------
diff --git a/src/main/org/apache/ant/antunit/ProjectFactory.java b/src/main/org/apache/ant/antunit/ProjectFactory.java
index 4171c7b..ca77f94 100644
--- a/src/main/org/apache/ant/antunit/ProjectFactory.java
+++ b/src/main/org/apache/ant/antunit/ProjectFactory.java
@@ -24,11 +24,11 @@ import org.apache.tools.ant.BuildException;
import org.apache.tools.ant.Project;
/**
- * Provides project instances for AntUnit execution.<br/>
- * The approach to creates a project depends on the context. When invoked from an
+ * Provides project instances for AntUnit execution.
+ * <p>The approach to creates a project depends on the context. When invoked from an
* ant project, some elements might be intialized from the parent project. When
- * executed in a junit runner, a brand new project must be initialized.<br/>
- * The AntScriptRunner will usually creates multiple project in order to provide test isolation.
+ * executed in a junit runner, a brand new project must be initialized.</p>
+ * <p>The AntScriptRunner will usually create multiple project in order to provide test isolation.</p>
* @since 1.2
*/
public interface ProjectFactory {
@@ -36,7 +36,8 @@ public interface ProjectFactory {
/**
* Creates a new project instance and configures it according to the execution context.
* @throws BuildException The project can not be created (probably parsed)
+ * @return a new project
*/
- public Project createProject() throws BuildException;
+ Project createProject() throws BuildException;
}
http://git-wip-us.apache.org/repos/asf/ant-antlibs-antunit/blob/ac56fd46/src/main/org/apache/ant/antunit/ResourceExists.java
----------------------------------------------------------------------
diff --git a/src/main/org/apache/ant/antunit/ResourceExists.java b/src/main/org/apache/ant/antunit/ResourceExists.java
index 53d9e56..20c12c3 100644
--- a/src/main/org/apache/ant/antunit/ResourceExists.java
+++ b/src/main/org/apache/ant/antunit/ResourceExists.java
@@ -40,6 +40,7 @@ public class ResourceExists extends ProjectComponent implements Condition {
*
* <p>Exactly one resource must be specfied either as attribute or
* nested element.</p>
+ * @param r resource to check
*/
public void setResource(Resource r) {
onlyOne();
@@ -49,6 +50,7 @@ public class ResourceExists extends ProjectComponent implements Condition {
/**
* The resource to check as a refid.
* @since AntUnit 1.3
+ * @param refid resource to check as a refid
*/
public void setRefid(String refid) {
onlyOne();
@@ -60,6 +62,7 @@ public class ResourceExists extends ProjectComponent implements Condition {
*
* <p>Exactly one resource must be specfied either as attribute or
* nested element.</p>
+ * @param r resource to check
*/
public void add(Resource r) {
setResource(r);
http://git-wip-us.apache.org/repos/asf/ant-antlibs-antunit/blob/ac56fd46/src/main/org/apache/ant/antunit/junit3/AntUnitSuite.java
----------------------------------------------------------------------
diff --git a/src/main/org/apache/ant/antunit/junit3/AntUnitSuite.java b/src/main/org/apache/ant/antunit/junit3/AntUnitSuite.java
index b8212d9..ac7717a 100644
--- a/src/main/org/apache/ant/antunit/junit3/AntUnitSuite.java
+++ b/src/main/org/apache/ant/antunit/junit3/AntUnitSuite.java
@@ -52,11 +52,11 @@ public class AntUnitSuite extends TestSuite {
/**
* Create a JUnit TestSuite that when executed will run the given ant
- * script.<br/>
- * Note that it is the responsibility of the caller to give the correct
+ * script.
+ * <p>Note that it is the responsibility of the caller to give the correct
* File reference. Namely, if the File is a relative file, it will
* be resolve relatively to the execution directory (which might be
- * different different from the project root directory).
+ * different different from the project root directory).</p>
*
* @param scriptFile
* AntUnit script file
@@ -108,7 +108,8 @@ public class AntUnitSuite extends TestSuite {
}
/**
- * @Override Run the full AntUnit suite
+ * {@inheritDoc}
+ * <p>Run the full AntUnit suite.</p>
*/
public void run(TestResult testResult) {
if (initializationReportingTest!=null) {
@@ -122,8 +123,9 @@ public class AntUnitSuite extends TestSuite {
}
/**
- * @Override Run a single test target of the AntUnit suite. suiteSetUp,
- * setUp, tearDown and suiteTearDown are executed around it.
+ * {@inheritDoc}
+ * <p>Run a single test target of the AntUnit suite. suiteSetUp,
+ * setUp, tearDown and suiteTearDown are executed around it.</p>
*/
public void runTest(Test test, TestResult result) {
if (initializationReportingTest!=null) {
@@ -139,9 +141,9 @@ public class AntUnitSuite extends TestSuite {
/**
* Execute the test suite in a 'container' similar to the ant 'container'.
- * When ant executes a project it redirect the input and the output. In this
+ * <p>When ant executes a project it redirect the input and the output. In this
* context we will only redirect output (unit test are not supposed to be
- * interactive).<br/>
+ * interactive).</p>
*
* @param targetList
* The list of test target to execute
http://git-wip-us.apache.org/repos/asf/ant-antlibs-antunit/blob/ac56fd46/src/main/org/apache/ant/antunit/junit3/AntUnitTestCase.java
----------------------------------------------------------------------
diff --git a/src/main/org/apache/ant/antunit/junit3/AntUnitTestCase.java b/src/main/org/apache/ant/antunit/junit3/AntUnitTestCase.java
index 346b040..5766b44 100644
--- a/src/main/org/apache/ant/antunit/junit3/AntUnitTestCase.java
+++ b/src/main/org/apache/ant/antunit/junit3/AntUnitTestCase.java
@@ -28,9 +28,10 @@ import junit.framework.TestCase;
import junit.framework.TestResult;
/**
- * JUnit TestCase that will executes a single AntUnit target. This class is not
- * supposed to be used directly. <br/>
- * It is public only because junit must access it as a public.
+ * JUnit TestCase that will executes a single AntUnit target.
+ * <p>This class is not
+ * supposed to be used directly.</p>
+ * <p>It is public only because junit must access it as a public.</p>
*/
public class AntUnitTestCase extends TestCase {
// We have to extends TestCase, and not implements Test because otherwise
@@ -60,11 +61,12 @@ public class AntUnitTestCase extends TestCase {
private final BuildException initialisationException;
/**
- * Prepare an AntUnitTestCase that will be executed alone. This constructor
+ * Prepare an AntUnitTestCase that will be executed alone.
+ * <p>This constructor
* is typically used by a junit 3 runner that will reexecute a specific
- * test.</br>
- * The execution of this test will be embed in a suiteSetUp and
- * suiteTearDown.
+ * test.</p>
+ * <p>The execution of this test will be embed in a suiteSetUp and
+ * suiteTearDown.</p>
* @param name The name of the AntUnitTestCase, normally obtained from a
* previous execution.
*/
@@ -91,9 +93,9 @@ public class AntUnitTestCase extends TestCase {
* is the responsibility of the suite to execute the suiteSetUp and the
* suiteTearDown.
*
- * @param target
- * @param antScriptRunner
- * @param executionEnv
+ * @param target test target
+ * @param suite test suite
+ * @param scriptFile test file
*/
public AntUnitTestCase(AntUnitSuite suite, File scriptFile, String target) {
// The name can be reused by eclipse when running a single test
@@ -103,7 +105,10 @@ public class AntUnitTestCase extends TestCase {
this.initialisationException = null;
}
- /** Get the AntUnit test target name */
+ /**
+ * Get the AntUnit test target name.
+ * @return target name
+ */
public String getTarget() {
return target;
}
@@ -111,8 +116,7 @@ public class AntUnitTestCase extends TestCase {
/**
* Called by a Junit Runner that want to executes specifically
* this test target.
- * This implementation delegates the call to the suite.
- * @Overwrite
+ * <p>This implementation delegates the call to the suite.</p>
*/
public void run(TestResult result) {
if (initialisationException==null && suite!=null) {
http://git-wip-us.apache.org/repos/asf/ant-antlibs-antunit/blob/ac56fd46/src/main/org/apache/ant/antunit/junit3/ErrorTestCase.java
----------------------------------------------------------------------
diff --git a/src/main/org/apache/ant/antunit/junit3/ErrorTestCase.java b/src/main/org/apache/ant/antunit/junit3/ErrorTestCase.java
index b731551..7975a43 100644
--- a/src/main/org/apache/ant/antunit/junit3/ErrorTestCase.java
+++ b/src/main/org/apache/ant/antunit/junit3/ErrorTestCase.java
@@ -45,9 +45,6 @@ public class ErrorTestCase extends TestCase {
this.ex = antScriptError;
}
- /**
- * @overwrite
- */
protected void runTest() throws BuildException {
throw ex;
}
http://git-wip-us.apache.org/repos/asf/ant-antlibs-antunit/blob/ac56fd46/src/main/org/apache/ant/antunit/junit4/AntUnitSuiteRunner.java
----------------------------------------------------------------------
diff --git a/src/main/org/apache/ant/antunit/junit4/AntUnitSuiteRunner.java b/src/main/org/apache/ant/antunit/junit4/AntUnitSuiteRunner.java
index 7adb4ff..e52485b 100644
--- a/src/main/org/apache/ant/antunit/junit4/AntUnitSuiteRunner.java
+++ b/src/main/org/apache/ant/antunit/junit4/AntUnitSuiteRunner.java
@@ -58,7 +58,7 @@ import org.junit.runner.notification.RunNotifier;
* run junit3 test. However, the test may be faster with this Runner (with the
* default junit4 adapter, the suiteSetUp and suiteTearDown will be executed
* around every test target). Also, more features are available when this runner
- * is used (filtering & sorting)
+ * is used (filtering & sorting)
*/
public class AntUnitSuiteRunner extends Runner implements Filterable, Sortable {
@@ -114,7 +114,7 @@ public class AntUnitSuiteRunner extends Runner implements Filterable, Sortable {
}
/**
- * @Overwrite Filterable implementation
+ * Filterable implementation
*/
public void filter(Filter filter) throws NoTestsRemainException {
for (Iterator iter= targetDescriptions.entrySet().iterator(); iter.hasNext();) {
@@ -126,7 +126,7 @@ public class AntUnitSuiteRunner extends Runner implements Filterable, Sortable {
}
/**
- * @Overwrite Sortable implementation
+ * Sortable implementation
*/
public void sort(final Sorter sorter) {
Collections.sort(targetsOrder, new Comparator/*<String>*/() {
@@ -142,7 +142,7 @@ public class AntUnitSuiteRunner extends Runner implements Filterable, Sortable {
}
/**
- * @Overwrite Runner implementation
+ * Runner implementation
*/
public Description getDescription() {
Description r = Description.createSuiteDescription(
@@ -157,7 +157,7 @@ public class AntUnitSuiteRunner extends Runner implements Filterable, Sortable {
}
/**
- * @Overwrite Runner implementation
+ * Runner implementation
*/
public void run(final RunNotifier junitNotifier) {
LinkedList targetList = new LinkedList(targetDescriptions.keySet());
http://git-wip-us.apache.org/repos/asf/ant-antlibs-antunit/blob/ac56fd46/src/main/org/apache/ant/antunit/listener/BaseAntUnitListener.java
----------------------------------------------------------------------
diff --git a/src/main/org/apache/ant/antunit/listener/BaseAntUnitListener.java b/src/main/org/apache/ant/antunit/listener/BaseAntUnitListener.java
index 1c3c21a..ac6c510 100644
--- a/src/main/org/apache/ant/antunit/listener/BaseAntUnitListener.java
+++ b/src/main/org/apache/ant/antunit/listener/BaseAntUnitListener.java
@@ -70,6 +70,7 @@ public abstract class BaseAntUnitListener
/**
* Directory to write reports to.
+ * @return directory to write reports to
*/
protected final File getToDir() {
return toDir;
@@ -77,6 +78,7 @@ public abstract class BaseAntUnitListener
/**
* Sets the directory to write test reports to.
+ * @param f directory to write reports to
*/
public void setToDir(File f) {
toDir = f;
@@ -89,6 +91,7 @@ public abstract class BaseAntUnitListener
/**
* Where to send the test report.
+ * @param logTo where to send the test report
*/
protected void setSendLogTo(SendLogTo logTo) {
this.logTo = logTo;
@@ -170,6 +173,8 @@ public abstract class BaseAntUnitListener
* Turns the build file name into something that vaguely looks
* like a Java classname. Close enough to be suitable for
* junitreport.
+ * @param buildFile the test file name
+ * @return the normalized name
*/
protected final String normalize(String buildFile) {
File base = parentTask != null
@@ -217,6 +222,7 @@ public abstract class BaseAntUnitListener
/**
* Sets the minimum level a log message must be logged at to be
* included in the output.
+ * @param l minimum level
*/
public void setLogLevel(AntUnitLogLevel l) {
logLevel = l;
@@ -225,9 +231,10 @@ public abstract class BaseAntUnitListener
/**
* Gets messages from the project running the test target if their
* level is at least of the level specified with {@link
- * #setLoglevel setLogLevel}.
+ * #setLogLevel setLogLevel}.
*
* <p>This implementation is empty.</p>
+ * @param event the logged message
*/
protected void messageLogged(BuildEvent event) {}
@@ -300,4 +307,4 @@ public abstract class BaseAntUnitListener
}
}
}
-}
\ No newline at end of file
+}
http://git-wip-us.apache.org/repos/asf/ant-antlibs-antunit/blob/ac56fd46/src/main/org/apache/ant/antunit/listener/FailureAntUnitListener.java
----------------------------------------------------------------------
diff --git a/src/main/org/apache/ant/antunit/listener/FailureAntUnitListener.java b/src/main/org/apache/ant/antunit/listener/FailureAntUnitListener.java
index 22944bd..4337f32 100644
--- a/src/main/org/apache/ant/antunit/listener/FailureAntUnitListener.java
+++ b/src/main/org/apache/ant/antunit/listener/FailureAntUnitListener.java
@@ -160,7 +160,7 @@ public class FailureAntUnitListener extends BaseAntUnitListener {
}
/**
- * Creates an <ant> call according to the stored information.
+ * Creates an <ant> call according to the stored information.
* @see java.lang.Object#toString()
*/
public String toString() {
http://git-wip-us.apache.org/repos/asf/ant-antlibs-antunit/blob/ac56fd46/src/main/org/apache/ant/antunit/listener/XMLConstants.java
----------------------------------------------------------------------
diff --git a/src/main/org/apache/ant/antunit/listener/XMLConstants.java b/src/main/org/apache/ant/antunit/listener/XMLConstants.java
index f28fec6..52ce4ae 100644
--- a/src/main/org/apache/ant/antunit/listener/XMLConstants.java
+++ b/src/main/org/apache/ant/antunit/listener/XMLConstants.java
@@ -25,10 +25,10 @@ package org.apache.ant.antunit.listener;
* Interface that groups all constants used throughout the <tt>XML</tt>
* documents that are generated by the <tt>XMLJUnitResultFormatter</tt>
* As of now the DTD is:
- * <code><pre>
- * <----------------- @todo describe DTDs ---------------------->
+ * <pre>
+ * <----------------- @todo describe DTDs ---------------------->
*
- * </pre></code>
+ * </pre>
* @see XMLAntUnitListener
*/
public interface XMLConstants {