You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@maven.apache.org by sl...@apache.org on 2020/06/19 21:41:03 UTC

[maven-resolver] branch MRESOLVER-62_tests updated (10f3e85 -> d16fca7)

This is an automated email from the ASF dual-hosted git repository.

slachiewicz pushed a change to branch MRESOLVER-62_tests
in repository https://gitbox.apache.org/repos/asf/maven-resolver.git.


 discard 10f3e85  Add tests for MRESOLVER-62 (currently inversed)
     add 8e8a4f1  [MRESOLVER-56] Support SHA-256 and SHA-512 as checksums
     add 7699c99  Fix Javadoc link
     add e0d665d  Convert http:// to https://
     add 1679d47  [MRESOLVER-117] Upgrade SLF4J to 1.7.30
     add 885dfc0  [MRESOLVER-118] Upgrade Sisu Components to 0.3.4
     add 3c2a514  [MRESOLVER-119] Turn log messages to SLF4J placeholders
     add 194808a  use try with resources (#56)
     add 86c1cb2  deprecate yet another StringUtils class (#57)
     add d271894  Bump maven-enforcer-plugin from 3.0.0-M2 to 3.0.0-M3
     add dd23364  Bump maven-invoker-plugin from 3.0.1 to 3.2.1
     add 812d071  Bump maven-bundle-plugin from 3.5.0 to 4.2.1
     add 8cf9660  Upgrade maven-bundle-plugin 4.1.0
     add e73be26  Upgrade maven-bundle-plugin 4.0.0
     add a7a5f70  Revert bundle plugin upgrade
     add 2112029  Fixed typo
     add 768d781  Fixed typo
     add b418a7b  [MRESOLVER-115] Make checksum algorithms configurable
     new d16fca7  Add tests for MRESOLVER-62 (currently inversed)

This update added new revisions after undoing existing revisions.
That is to say, some revisions that were in the old version of the
branch are not in the new version.  This situation occurs
when a user --force pushes a change and generates a repository
containing something like this:

 * -- * -- B -- O -- O -- O   (10f3e85)
            \
             N -- N -- N   refs/heads/MRESOLVER-62_tests (d16fca7)

You should already have received notification emails for all of the O
revisions, and so the following emails describe only the N revisions
from the common base, B.

Any revisions marked "omit" are not gone; other references still
refer to them.  Any revisions marked "discard" are gone forever.

The 1 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 .../connector/basic/BasicRepositoryConnector.java  |   36 +-
 .../aether/connector/basic/ChecksumValidator.java  |    6 +-
 .../aether/connector/basic/PartialFile.java        |    7 +-
 .../connector/basic/ChecksumCalculatorTest.java    |   44 +-
 .../connector/basic/ChecksumValidatorTest.java     |    4 +-
 .../maven-resolver-demo-maven-plugin/pom.xml       |    2 +-
 .../manual/ManualRepositorySystemFactory.java      |    8 +-
 maven-resolver-demos/src/site/xdoc/download.xml.vm |    8 +-
 maven-resolver-impl/pom.xml                        |    5 +
 .../impl/DefaultLocalRepositoryProvider.java       |    7 +-
 .../impl/DefaultRemoteRepositoryManager.java       |    2 +-
 .../impl/DefaultRepositoryConnectorProvider.java   |    7 +-
 .../impl/DefaultRepositoryEventDispatcher.java     |   16 +-
 .../impl/DefaultRepositoryLayoutProvider.java      |    7 +-
 .../internal/impl/DefaultTransporterProvider.java  |    7 +-
 .../internal/impl/DefaultUpdateCheckManager.java   |   22 +-
 .../impl/Maven2RepositoryLayoutFactory.java        |   36 +-
 .../eclipse/aether/internal/impl/SimpleDigest.java |   19 +-
 .../aether/internal/impl/TrackingFileManager.java  |    7 +-
 .../aether/internal/impl/WarnChecksumPolicy.java   |   16 +-
 .../impl/collect/DefaultDependencyCollector.java   |   13 +-
 .../impl/Maven2RepositoryLayoutFactoryTest.java    |   67 +-
 .../internal/impl/StubRemoteRepositoryManager.java |    2 +-
 .../aether/spi/connector/layout/ChecksumTest.java  |   14 +-
 .../aether/transport/wagon/WagonTransporter.java   |  167 +---
 .../java/org/eclipse/aether/util/StringUtils.java  |    2 +
 .../org/eclipse/aether/util/ChecksumUtilTest.java  |   40 +-
 .../org/eclipse/aether/util/StringUtilsTest.java   |    3 +-
 pom.xml                                            | 1026 ++++++++++----------
 src/site/site.xml                                  |    6 +-
 src/site/xdoc/download.xml.vm                      |    8 +-
 src/site/xdoc/index.xml                            |    4 +-
 32 files changed, 791 insertions(+), 827 deletions(-)


[maven-resolver] 01/01: Add tests for MRESOLVER-62 (currently inversed)

Posted by sl...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

slachiewicz pushed a commit to branch MRESOLVER-62_tests
in repository https://gitbox.apache.org/repos/asf/maven-resolver.git

commit d16fca743b5cfe7220ea746a012d38452f63a2db
Author: Michael Osipov <mi...@apache.org>
AuthorDate: Sun May 12 19:45:56 2019 +0200

    Add tests for MRESOLVER-62 (currently inversed)
---
 .../transformer/NearestVersionSelectorTest.java    | 33 ++++++++++++++++++++--
 .../cycle-underneath-removed-node.txt              | 20 +++++++++++++
 .../cycle-underneath-removed-node2.txt             | 17 +++++++++++
 3 files changed, 68 insertions(+), 2 deletions(-)

diff --git a/maven-resolver-util/src/test/java/org/eclipse/aether/util/graph/transformer/NearestVersionSelectorTest.java b/maven-resolver-util/src/test/java/org/eclipse/aether/util/graph/transformer/NearestVersionSelectorTest.java
index b71adab..ab40650 100644
--- a/maven-resolver-util/src/test/java/org/eclipse/aether/util/graph/transformer/NearestVersionSelectorTest.java
+++ b/maven-resolver-util/src/test/java/org/eclipse/aether/util/graph/transformer/NearestVersionSelectorTest.java
@@ -8,9 +8,9 @@ package org.eclipse.aether.util.graph.transformer;
  * 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
@@ -82,6 +82,35 @@ public class NearestVersionSelectorTest
         assertEquals( 5, trail.size() );
     }
 
+    // This test must be assertTrue() as soon as MRESOLVER-62 is fixed
+    @Test
+    public void testCycleUnderneathRemovedNode()
+        throws Exception
+    {
+        DependencyNode root = parseResource("cycle-underneath-removed-node.txt" );
+
+        assertSame( root, transform( root ) );
+        List<DependencyNode> trail = find( root, "y" );
+        assertEquals( 6, trail.size() );
+
+        // Node y should have children removed
+        assertFalse( trail.get(0).getChildren().isEmpty() );
+    }
+
+    // This test must be assertFalse() as soon as MRESOLVER-62 is fixed
+    @Test
+    public void testCycleUnderneathRemovedNode2()
+        throws Exception
+    {
+        DependencyNode root = parseResource("cycle-underneath-removed-node2.txt" );
+
+        assertSame( root, transform( root ) );
+
+        // Node x should be present
+        List<DependencyNode> trail = find( root, "x" );
+        assertTrue( trail.isEmpty() );
+    }
+
     @Test
     public void testViolationOfHardConstraintFallsBackToNearestSeenNotFirstSeen()
         throws Exception
diff --git a/maven-resolver-util/src/test/resources/transformer/version-resolver/cycle-underneath-removed-node.txt b/maven-resolver-util/src/test/resources/transformer/version-resolver/cycle-underneath-removed-node.txt
new file mode 100644
index 0000000..5406c72
--- /dev/null
+++ b/maven-resolver-util/src/test/resources/transformer/version-resolver/cycle-underneath-removed-node.txt
@@ -0,0 +1,20 @@
+# This graph has a cycle (x <-> y) underneath a node that is removed from the tree (a:1).
+# However, this cycle also appears as a child of another cycle. Specifically, (q <-> p) depends on d, which depends on x.
+# When conflicts are resolved, the cycle between x and y should be broken.
+(null)
++- gid:a:1
+|  \- gid:x:1                  (x)
+|     \- gid:y:1
+|        \- ^x
++- gid:a:2
++- gid:b:1
+|  +- gid:c:1
+|     \- gid:d:1               (d)
+|        \- ^x
+\- gid:m:1
+   \- gid:n:1
+      +- gid:p:1
+      |  \- gid:q:1
+      \- gid:q:2
+         \- gid:p:2
+            \- ^d
\ No newline at end of file
diff --git a/maven-resolver-util/src/test/resources/transformer/version-resolver/cycle-underneath-removed-node2.txt b/maven-resolver-util/src/test/resources/transformer/version-resolver/cycle-underneath-removed-node2.txt
new file mode 100644
index 0000000..23e4a91
--- /dev/null
+++ b/maven-resolver-util/src/test/resources/transformer/version-resolver/cycle-underneath-removed-node2.txt
@@ -0,0 +1,17 @@
+# This graph has a cycle (x <-> y) underneath a node that is removed from the tree (a:1).
+# However, this cycle also appears as a child of another cycle.
+# Specifically, q:2 depends on x and is part of a cycle (p <-> q).
+# When conflicts are resolved, x should be included.
+(null)
++- gid:a:1
+|  \- gid:x:1                  (x)
+|     \- gid:y:1
+|        \- ^x
++- gid:a:2
+\- gid:m:1
+   \- gid:n:1
+      +- gid:p:1
+      |  \- gid:q:1
+      \- gid:q:2
+         |- gid:p:2
+         \- ^x
\ No newline at end of file