You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@ant.apache.org by gi...@apache.org on 2017/12/05 15:45:31 UTC

ant-ivy git commit: tidy up the code

Repository: ant-ivy
Updated Branches:
  refs/heads/master da461de2d -> 47061a88c


tidy up the code

Project: http://git-wip-us.apache.org/repos/asf/ant-ivy/repo
Commit: http://git-wip-us.apache.org/repos/asf/ant-ivy/commit/47061a88
Tree: http://git-wip-us.apache.org/repos/asf/ant-ivy/tree/47061a88
Diff: http://git-wip-us.apache.org/repos/asf/ant-ivy/diff/47061a88

Branch: refs/heads/master
Commit: 47061a88cefcaaedacd1d570699f30a4266c23af
Parents: da461de
Author: Gintas Grigelionis <gi...@apache.org>
Authored: Tue Dec 5 16:44:53 2017 +0100
Committer: Gintas Grigelionis <gi...@apache.org>
Committed: Tue Dec 5 16:44:53 2017 +0100

----------------------------------------------------------------------
 test/java/org/apache/ivy/TestHelper.java                  |  2 +-
 test/java/org/apache/ivy/ant/IvyBuildNumberTest.java      |  1 -
 test/java/org/apache/ivy/ant/IvyCacheFilesetTest.java     | 10 ++--------
 test/java/org/apache/ivy/ant/IvyCachePathTest.java        |  2 --
 test/java/org/apache/ivy/ant/IvyCleanCacheTest.java       |  2 --
 test/java/org/apache/ivy/ant/IvyConfigureTest.java        |  5 -----
 test/java/org/apache/ivy/ant/IvyDependencyTreeTest.java   |  3 ---
 .../apache/ivy/ant/IvyDependencyUpdateCheckerTest.java    | 10 ----------
 test/java/org/apache/ivy/ant/IvyInfoTest.java             |  2 --
 test/java/org/apache/ivy/ant/IvyInstallTest.java          |  4 ----
 test/java/org/apache/ivy/ant/IvyListModulesTest.java      |  2 +-
 test/java/org/apache/ivy/ant/IvyPublishTest.java          |  5 +----
 test/java/org/apache/ivy/ant/IvyResolveTest.java          |  5 -----
 test/java/org/apache/ivy/ant/IvyRetrieveTest.java         |  7 -------
 test/java/org/apache/ivy/core/resolve/ResolveTest.java    |  2 +-
 test/java/org/apache/ivy/core/sort/SortTest.java          |  3 ---
 .../ivy/plugins/repository/vfs/VfsResourceTest.java       |  8 --------
 17 files changed, 6 insertions(+), 67 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ant-ivy/blob/47061a88/test/java/org/apache/ivy/TestHelper.java
----------------------------------------------------------------------
diff --git a/test/java/org/apache/ivy/TestHelper.java b/test/java/org/apache/ivy/TestHelper.java
index 2a131e9..25c156c 100644
--- a/test/java/org/apache/ivy/TestHelper.java
+++ b/test/java/org/apache/ivy/TestHelper.java
@@ -203,7 +203,7 @@ public class TestHelper {
 
     /**
      * Parses a collection of module descriptors in the micro ivy format, separated by double
-     * semicolumns.
+     * semicolons.
      *
      * @param microIvy
      *            the text representation of the collection of module descriptors

http://git-wip-us.apache.org/repos/asf/ant-ivy/blob/47061a88/test/java/org/apache/ivy/ant/IvyBuildNumberTest.java
----------------------------------------------------------------------
diff --git a/test/java/org/apache/ivy/ant/IvyBuildNumberTest.java b/test/java/org/apache/ivy/ant/IvyBuildNumberTest.java
index f688684..043d997 100644
--- a/test/java/org/apache/ivy/ant/IvyBuildNumberTest.java
+++ b/test/java/org/apache/ivy/ant/IvyBuildNumberTest.java
@@ -183,7 +183,6 @@ public class IvyBuildNumberTest {
     /**
      * Test case for IVY-1037.
      *
-     * @throws Exception if something goes wrong
      * @see <a href="https://issues.apache.org/jira/browse/IVY-1037">IVY-1037</a>
      */
     @Test

http://git-wip-us.apache.org/repos/asf/ant-ivy/blob/47061a88/test/java/org/apache/ivy/ant/IvyCacheFilesetTest.java
----------------------------------------------------------------------
diff --git a/test/java/org/apache/ivy/ant/IvyCacheFilesetTest.java b/test/java/org/apache/ivy/ant/IvyCacheFilesetTest.java
index 63ee091..0fb2d2e 100644
--- a/test/java/org/apache/ivy/ant/IvyCacheFilesetTest.java
+++ b/test/java/org/apache/ivy/ant/IvyCacheFilesetTest.java
@@ -111,8 +111,6 @@ public class IvyCacheFilesetTest {
 
     /**
      * Test must fail with default haltonfailure setting.
-     *
-     * @throws Exception if something goes wrong
      */
     @Test(expected = BuildException.class)
     public void testFailure() {
@@ -123,8 +121,6 @@ public class IvyCacheFilesetTest {
 
     /**
      * Test must fail with default haltonfailure setting.
-     *
-     * @throws Exception if something goes wrong
      */
     @Test(expected = BuildException.class)
     public void testInvalidPattern() {
@@ -136,8 +132,6 @@ public class IvyCacheFilesetTest {
 
     /**
      * Test must pass with haltonfailure set to false.
-     *
-     * @throws Exception if something goes wrong
      */
     @Test
     public void testHaltOnFailure() {
@@ -190,8 +184,8 @@ public class IvyCacheFilesetTest {
         assertEquals(new File("x").getAbsoluteFile(), base);
 
         // A common base only on the fs-root.
-        final File[] filesytemRoots = File.listRoots();
-        final File root1 = filesytemRoots[0];
+        final File[] filesystemRoots = File.listRoots();
+        final File root1 = filesystemRoots[0];
         final File file4 = new File(root1, "abcd/xyz");
         final File file5 = new File(root1, "pqrs/xyz");
         final File commonBase = fileset.getBaseDir(file4, file5);

http://git-wip-us.apache.org/repos/asf/ant-ivy/blob/47061a88/test/java/org/apache/ivy/ant/IvyCachePathTest.java
----------------------------------------------------------------------
diff --git a/test/java/org/apache/ivy/ant/IvyCachePathTest.java b/test/java/org/apache/ivy/ant/IvyCachePathTest.java
index 81519f6..27a676a 100644
--- a/test/java/org/apache/ivy/ant/IvyCachePathTest.java
+++ b/test/java/org/apache/ivy/ant/IvyCachePathTest.java
@@ -136,8 +136,6 @@ public class IvyCachePathTest {
 
     /**
      * Test must fail with default haltonfailure setting.
-     *
-     * @throws Exception if something goes wrong
      */
     @Test(expected = BuildException.class)
     public void testFailure() {

http://git-wip-us.apache.org/repos/asf/ant-ivy/blob/47061a88/test/java/org/apache/ivy/ant/IvyCleanCacheTest.java
----------------------------------------------------------------------
diff --git a/test/java/org/apache/ivy/ant/IvyCleanCacheTest.java b/test/java/org/apache/ivy/ant/IvyCleanCacheTest.java
index 8a38237..0db7991 100644
--- a/test/java/org/apache/ivy/ant/IvyCleanCacheTest.java
+++ b/test/java/org/apache/ivy/ant/IvyCleanCacheTest.java
@@ -103,8 +103,6 @@ public class IvyCleanCacheTest {
 
     /**
      * clean cache must fail with unknown cache
-     *
-     * @throws Exception if something goes wrong
      */
     @Test
     public void testUnknownCache() {

http://git-wip-us.apache.org/repos/asf/ant-ivy/blob/47061a88/test/java/org/apache/ivy/ant/IvyConfigureTest.java
----------------------------------------------------------------------
diff --git a/test/java/org/apache/ivy/ant/IvyConfigureTest.java b/test/java/org/apache/ivy/ant/IvyConfigureTest.java
index 02e4a5d..a748e13 100644
--- a/test/java/org/apache/ivy/ant/IvyConfigureTest.java
+++ b/test/java/org/apache/ivy/ant/IvyConfigureTest.java
@@ -225,7 +225,6 @@ public class IvyConfigureTest {
     /**
      * Test case for IVY-601.
      *
-     * @throws Exception if something goes wrong
      * @see <a href="https://issues.apache.org/jira/browse/IVY-601">IVY-601</a>
      */
     @Test
@@ -274,8 +273,6 @@ public class IvyConfigureTest {
 
     /**
      * Calling settings twice with the same id with override=notallowed must fail
-     *
-     * @throws Exception if something goes wrong
      */
     @Test
     public void testOverrideNotAllowed() {
@@ -299,8 +296,6 @@ public class IvyConfigureTest {
 
     /**
      * Settings override with invalid value must fail.
-     *
-     * @throws Exception if something goes wrong
      */
     @Test
     public void testInvalidOverride() {

http://git-wip-us.apache.org/repos/asf/ant-ivy/blob/47061a88/test/java/org/apache/ivy/ant/IvyDependencyTreeTest.java
----------------------------------------------------------------------
diff --git a/test/java/org/apache/ivy/ant/IvyDependencyTreeTest.java b/test/java/org/apache/ivy/ant/IvyDependencyTreeTest.java
index 8485973..0f3462a 100644
--- a/test/java/org/apache/ivy/ant/IvyDependencyTreeTest.java
+++ b/test/java/org/apache/ivy/ant/IvyDependencyTreeTest.java
@@ -86,8 +86,6 @@ public class IvyDependencyTreeTest extends AntTaskTestCase {
 
     /**
      * Task must fail because no resolve was performed.
-     *
-     * @throws Exception if something goes wrong
      */
     @Test(expected = BuildException.class)
     public void testWithResolveIdWithoutResolve() {
@@ -121,7 +119,6 @@ public class IvyDependencyTreeTest extends AntTaskTestCase {
      * Test case for IVY-1540.
      * Dependency tree task must not run into an infinite loop due to circular dependencies.
      *
-     * @throws Exception if something goes wrong
      * @see <a href="https://issues.apache.org/jira/browse/IVY-1540">IVY-1540</a>
      */
     @Test

http://git-wip-us.apache.org/repos/asf/ant-ivy/blob/47061a88/test/java/org/apache/ivy/ant/IvyDependencyUpdateCheckerTest.java
----------------------------------------------------------------------
diff --git a/test/java/org/apache/ivy/ant/IvyDependencyUpdateCheckerTest.java b/test/java/org/apache/ivy/ant/IvyDependencyUpdateCheckerTest.java
index 5e9a0d6..c54c972 100644
--- a/test/java/org/apache/ivy/ant/IvyDependencyUpdateCheckerTest.java
+++ b/test/java/org/apache/ivy/ant/IvyDependencyUpdateCheckerTest.java
@@ -120,8 +120,6 @@ public class IvyDependencyUpdateCheckerTest extends AntTaskTestCase {
 
     /**
      * Test must fail with default haltonfailure setting.
-     *
-     * @throws Exception if something goes wrong
      */
     @Test(expected = BuildException.class)
     public void testInlineForNonExistingModule() {
@@ -135,8 +133,6 @@ public class IvyDependencyUpdateCheckerTest extends AntTaskTestCase {
 
     /**
      * Test must fail with default haltonfailure setting.
-     *
-     * @throws Exception if something goes wrong
      */
     @Test(expected = BuildException.class)
     public void testFailure() {
@@ -147,8 +143,6 @@ public class IvyDependencyUpdateCheckerTest extends AntTaskTestCase {
 
     /**
      * Test must fail because of missing configurations.
-     *
-     * @throws Exception if something goes wrong
      */
     @Test
     public void testFailureWithMissingConfigurations() {
@@ -163,8 +157,6 @@ public class IvyDependencyUpdateCheckerTest extends AntTaskTestCase {
 
     /**
      * Test must fail with default haltonfailure setting.
-     *
-     * @throws Exception if something goes wrong
      */
     @Test(expected = BuildException.class)
     public void testFailureOnBadDependencyIvyFile() {
@@ -175,8 +167,6 @@ public class IvyDependencyUpdateCheckerTest extends AntTaskTestCase {
 
     /**
      * Test must fail with default haltonfailure setting.
-     *
-     * @throws Exception if something goes wrong
      */
     @Test(expected = BuildException.class)
     public void testFailureOnBadStatusInDependencyIvyFile() {

http://git-wip-us.apache.org/repos/asf/ant-ivy/blob/47061a88/test/java/org/apache/ivy/ant/IvyInfoTest.java
----------------------------------------------------------------------
diff --git a/test/java/org/apache/ivy/ant/IvyInfoTest.java b/test/java/org/apache/ivy/ant/IvyInfoTest.java
index 6c9ae94..2773b20 100644
--- a/test/java/org/apache/ivy/ant/IvyInfoTest.java
+++ b/test/java/org/apache/ivy/ant/IvyInfoTest.java
@@ -77,7 +77,6 @@ public class IvyInfoTest {
     /**
      * Test case for IVY-726.
      *
-     * @throws Exception if something goes wrong
      * @see <a href="https://issues.apache.org/jira/browse/IVY-726">IVY-726</a>
      */
     @Test
@@ -91,7 +90,6 @@ public class IvyInfoTest {
     /**
      * Test case for IVY-395.
      *
-     * @throws Exception if something goes wrong
      * @see <a href="https://issues.apache.org/jira/browse/IVY-395">IVY-395</a>
      */
     @Test

http://git-wip-us.apache.org/repos/asf/ant-ivy/blob/47061a88/test/java/org/apache/ivy/ant/IvyInstallTest.java
----------------------------------------------------------------------
diff --git a/test/java/org/apache/ivy/ant/IvyInstallTest.java b/test/java/org/apache/ivy/ant/IvyInstallTest.java
index 749b500..89999e2 100644
--- a/test/java/org/apache/ivy/ant/IvyInstallTest.java
+++ b/test/java/org/apache/ivy/ant/IvyInstallTest.java
@@ -291,8 +291,6 @@ public class IvyInstallTest {
 
     /**
      * Installing a module with namespace coordinates instead of system one must fail.
-     *
-     * @throws Exception if something goes wrong
      */
     @Test(expected = BuildException.class)
     public void testInstallWithNamespace2() {
@@ -324,8 +322,6 @@ public class IvyInstallTest {
 
     /**
      * Fail on unknown dependency when haltonfailure=true.
-     *
-     * @throws Exception if something goes wrong
      */
     @Test(expected = BuildException.class)
     public void testDependencyNotFoundFailure() {

http://git-wip-us.apache.org/repos/asf/ant-ivy/blob/47061a88/test/java/org/apache/ivy/ant/IvyListModulesTest.java
----------------------------------------------------------------------
diff --git a/test/java/org/apache/ivy/ant/IvyListModulesTest.java b/test/java/org/apache/ivy/ant/IvyListModulesTest.java
index 19dff06..72fde0c 100644
--- a/test/java/org/apache/ivy/ant/IvyListModulesTest.java
+++ b/test/java/org/apache/ivy/ant/IvyListModulesTest.java
@@ -58,7 +58,7 @@ public class IvyListModulesTest {
     }
 
     @Test
-    public void testAllRevs() throws Exception {
+    public void testAllRevs() {
         findModules.setOrganisation("org1");
         findModules.setModule("mod1.1");
         findModules.setRevision("*");

http://git-wip-us.apache.org/repos/asf/ant-ivy/blob/47061a88/test/java/org/apache/ivy/ant/IvyPublishTest.java
----------------------------------------------------------------------
diff --git a/test/java/org/apache/ivy/ant/IvyPublishTest.java b/test/java/org/apache/ivy/ant/IvyPublishTest.java
index 4cdc3e2..73a13e7 100644
--- a/test/java/org/apache/ivy/ant/IvyPublishTest.java
+++ b/test/java/org/apache/ivy/ant/IvyPublishTest.java
@@ -171,7 +171,6 @@ public class IvyPublishTest {
      * Test case for IVY-1248.
      *
      * @throws IOException if something goes wrong
-     * @throws ParseException if something goes wrong
      * @see <a href="https://issues.apache.org/jira/browse/IVY-1248">IVY-1248</a>
      */
     @Test
@@ -203,12 +202,10 @@ public class IvyPublishTest {
      * the module parent is not published not yet in cache.
      *
      * @throws IOException if something goes wrong
-     * @throws ParseException if something goes wrong
      * @see <a href="https://issues.apache.org/jira/browse/IVY-1248">IVY-1248</a>
      */
     @Test
-    public void testMergeParentWithoutPublishingParentForceDeliver()
-            throws IOException {
+    public void testMergeParentWithoutPublishingParentForceDeliver() throws IOException {
         IvyResolve resolve = new IvyResolve();
         resolve.setProject(project);
         resolve.setFile(new File("test/java/org/apache/ivy/ant/ivy-extends-multiconf.xml"));

http://git-wip-us.apache.org/repos/asf/ant-ivy/blob/47061a88/test/java/org/apache/ivy/ant/IvyResolveTest.java
----------------------------------------------------------------------
diff --git a/test/java/org/apache/ivy/ant/IvyResolveTest.java b/test/java/org/apache/ivy/ant/IvyResolveTest.java
index d12d3c5..46e9f62 100644
--- a/test/java/org/apache/ivy/ant/IvyResolveTest.java
+++ b/test/java/org/apache/ivy/ant/IvyResolveTest.java
@@ -69,7 +69,6 @@ public class IvyResolveTest {
     /**
      * Test case for IVY-1455.
      *
-     * @throws Exception if something goes wrong
      * @see <a href="https://issues.apache.org/jira/browse/IVY-1455">IVY-1455</a>
      */
     @Test
@@ -100,7 +99,6 @@ public class IvyResolveTest {
     /**
      * Test case for IVY-779.
      *
-     * @throws Exception if something goes wrong
      * @see <a href="https://issues.apache.org/jira/browse/IVY-779">IVY-779</a>
      */
     @Test
@@ -141,7 +139,6 @@ public class IvyResolveTest {
     /**
      * Test case for IVY-630.
      *
-     * @throws Exception if something goes wrong
      * @see <a href="https://issues.apache.org/jira/browse/IVY-630">IVY-630</a>
      */
     @Test
@@ -638,8 +635,6 @@ public class IvyResolveTest {
 
     /**
      * Test a failing resolve.
-     *
-     * @throws Exception if something goes wrong
      */
     @Test(expected = BuildException.class)
     public void testChildsFail() {

http://git-wip-us.apache.org/repos/asf/ant-ivy/blob/47061a88/test/java/org/apache/ivy/ant/IvyRetrieveTest.java
----------------------------------------------------------------------
diff --git a/test/java/org/apache/ivy/ant/IvyRetrieveTest.java b/test/java/org/apache/ivy/ant/IvyRetrieveTest.java
index de9ec7c..7d49f10 100644
--- a/test/java/org/apache/ivy/ant/IvyRetrieveTest.java
+++ b/test/java/org/apache/ivy/ant/IvyRetrieveTest.java
@@ -91,7 +91,6 @@ public class IvyRetrieveTest {
     /**
      * Test case for IVY-992.
      *
-     * @throws Exception if something goes wrong
      * @see <a href="https://issues.apache.org/jira/browse/IVY-992">IVY-992</a>
      */
     @Test
@@ -229,7 +228,6 @@ public class IvyRetrieveTest {
     /**
      * Test case for IVY-304.
      *
-     * @throws Exception if something goes wrong
      * @see <a href="https://issues.apache.org/jira/browse/IVY-304">IVY-304</a>
      */
     @Test
@@ -280,7 +278,6 @@ public class IvyRetrieveTest {
     /**
      * Test case for IVY-631.
      *
-     * @throws Exception if something goes wrong
      * @see <a href="https://issues.apache.org/jira/browse/IVY-631">IVY-631</a>
      */
     @Test
@@ -296,8 +293,6 @@ public class IvyRetrieveTest {
 
     /**
      * Retrieve without previous resolve must fail.
-     *
-     * @throws Exception if something goes wrong
      */
     @Test(expected = BuildException.class)
     public void testFailureWithoutAPreviousResolve() {
@@ -309,8 +304,6 @@ public class IvyRetrieveTest {
 
     /**
      * Test must fail with default haltonfailure setting.
-     *
-     * @throws Exception if something goes wrong
      */
     @Test(expected = BuildException.class)
     public void testFailure() {

http://git-wip-us.apache.org/repos/asf/ant-ivy/blob/47061a88/test/java/org/apache/ivy/core/resolve/ResolveTest.java
----------------------------------------------------------------------
diff --git a/test/java/org/apache/ivy/core/resolve/ResolveTest.java b/test/java/org/apache/ivy/core/resolve/ResolveTest.java
index eff5454..a41f91f 100644
--- a/test/java/org/apache/ivy/core/resolve/ResolveTest.java
+++ b/test/java/org/apache/ivy/core/resolve/ResolveTest.java
@@ -4866,7 +4866,7 @@ public class ResolveTest {
         // parent(2.0)
         // then parent2. Both parents have a dependencyManagement element for test2, and each list
         // the version as
-        // ${pom.version}. The parent version should take precidence over parent2,
+        // ${pom.version}. The parent version should take precedence over parent2,
         // so the version should be test2 version 2.0. Test3 is also a dependency of parent, and
         // it's version is listed
         // as 1.0 in parent2 (dependencies inherited from parent comes after).

http://git-wip-us.apache.org/repos/asf/ant-ivy/blob/47061a88/test/java/org/apache/ivy/core/sort/SortTest.java
----------------------------------------------------------------------
diff --git a/test/java/org/apache/ivy/core/sort/SortTest.java b/test/java/org/apache/ivy/core/sort/SortTest.java
index 0660884..c3eb0a9 100644
--- a/test/java/org/apache/ivy/core/sort/SortTest.java
+++ b/test/java/org/apache/ivy/core/sort/SortTest.java
@@ -91,8 +91,6 @@ public class SortTest {
      * Sorter does not throw circular dependency, circular dependencies are handled at resolve time
      * only. However the sort respect the transitive order when it is unambiguous. (If A depends
      * transitively of B, but B doesn't depends transitively on A, then B always comes before A.)
-     *
-     * @throws Exception if something goes wrong
      */
     @Test
     public void testCircularDependency() {
@@ -129,7 +127,6 @@ public class SortTest {
     /**
      * Test case for IVY-624
      *
-     * @throws Exception if something goes wrong
      * @see <a href="https://issues.apache.org/jira/browse/IVY-624">IVY-624</a>
      */
     @Test

http://git-wip-us.apache.org/repos/asf/ant-ivy/blob/47061a88/test/java/org/apache/ivy/plugins/repository/vfs/VfsResourceTest.java
----------------------------------------------------------------------
diff --git a/test/java/org/apache/ivy/plugins/repository/vfs/VfsResourceTest.java b/test/java/org/apache/ivy/plugins/repository/vfs/VfsResourceTest.java
index c33d8c4..be84e22 100644
--- a/test/java/org/apache/ivy/plugins/repository/vfs/VfsResourceTest.java
+++ b/test/java/org/apache/ivy/plugins/repository/vfs/VfsResourceTest.java
@@ -116,8 +116,6 @@ public class VfsResourceTest {
 
     /**
      * Validate VFSResource creation when given a poorly formed VFS identifier
-     *
-     * @throws Exception if something goes wrong
      */
     @Test
     public void testBadURI() {
@@ -138,8 +136,6 @@ public class VfsResourceTest {
 
     /**
      * Validate getChildren when given a VFS URI for a directory
-     *
-     * @throws Exception if something goes wrong
      */
     @Test
     public void testListFolderChildren() {
@@ -173,8 +169,6 @@ public class VfsResourceTest {
     /**
      * Validate that we don't get any results when we query a VFSResource file object for its
      * children
-     *
-     * @throws Exception if something goes wrong
      */
     @Test
     public void testListFileChildren() {
@@ -189,8 +183,6 @@ public class VfsResourceTest {
     /**
      * Validate that we don't get any results if we ask an IMAGINARY VFSResource - a nonexistent
      * file - for a list of its children
-     *
-     * @throws Exception if something goes wrong
      */
     @Test
     public void testListImaginary() {