[ 
https://issues.apache.org/jira/browse/MNG-7185?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Michael Osipov closed MNG-7185.
-------------------------------
    Fix Version/s:     (was: 3.8.x-candidate)
                       (was: 4.0.x-candidate)
                   4.0.0-alpha-1
                   4.0.0
                   3.8.2
       Resolution: Fixed

Fixed with 
[e29a6610865f674f6d9b856c03d156074d0d2df8|https://gitbox.apache.org/repos/asf?p=maven.git;a=commit;h=e29a6610865f674f6d9b856c03d156074d0d2df8]
 and 
[176b272f30c4fbd62013b4702ab28518c21628ac|https://gitbox.apache.org/repos/asf?p=maven.git;a=commit;h=176b272f30c4fbd62013b4702ab28518c21628ac]
 for {{maven-3.8.x}} branch.

> Describe explicit and recommended version for 
> VersionRange.createFromVersionSpec()
> ----------------------------------------------------------------------------------
>
>                 Key: MNG-7185
>                 URL: https://issues.apache.org/jira/browse/MNG-7185
>             Project: Maven
>          Issue Type: Improvement
>    Affects Versions: 3.8.1
>            Reporter: Nils Breunese
>            Assignee: Michael Osipov
>            Priority: Minor
>             Fix For: 3.8.2, 4.0.0, 4.0.0-alpha-1
>
>
> I would expect a version range for a single version to not contain any other 
> versions, but it seems this is not the case, because this test fails on the 
> second assertion:
> {code}
> @Test
> void range_with_single_version_should_not_contain_other_version() {
>         VersionRange singleVersionRange = 
> VersionRange.createFromVersionSpec("1.0.0");
>         assertThat(singleVersionRange.containsVersion(new 
> DefaultArtifactVersion("1.0.0"))).isTrue();
>         assertThat(singleVersionRange.containsVersion(new 
> DefaultArtifactVersion("2.0.0"))).isFalse();
> }
> {code}
> Is this a bug, or do I misinterpret what a single version range is? Does 
> {{maven-artifact}} have a concept for a version range that only contains a 
> single version?



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to