|
|
|
@ -57,7 +57,7 @@ public void testRange()
|
|
|
|
|
VersionRange range = VersionRange.createFromVersionSpec( "(,1.0]" );
|
|
|
|
|
List<Restriction> restrictions = range.getRestrictions();
|
|
|
|
|
assertEquals( CHECK_NUM_RESTRICTIONS, 1, restrictions.size() );
|
|
|
|
|
Restriction restriction = (Restriction) restrictions.get( 0 );
|
|
|
|
|
Restriction restriction = restrictions.get( 0 );
|
|
|
|
|
assertNull( CHECK_LOWER_BOUND, restriction.getLowerBound() );
|
|
|
|
|
assertFalse( CHECK_LOWER_BOUND_INCLUSIVE, restriction.isLowerBoundInclusive() );
|
|
|
|
|
assertEquals( CHECK_UPPER_BOUND, "1.0", restriction.getUpperBound().toString() );
|
|
|
|
@ -70,7 +70,7 @@ public void testRange()
|
|
|
|
|
assertEquals( CHECK_VERSION_RECOMMENDATION, "1.0", range.getRecommendedVersion().toString() );
|
|
|
|
|
restrictions = range.getRestrictions();
|
|
|
|
|
assertEquals( CHECK_NUM_RESTRICTIONS, 1, restrictions.size() );
|
|
|
|
|
restriction = (Restriction) restrictions.get( 0 );
|
|
|
|
|
restriction = restrictions.get( 0 );
|
|
|
|
|
assertNull( CHECK_LOWER_BOUND, restriction.getLowerBound() );
|
|
|
|
|
assertFalse( CHECK_LOWER_BOUND_INCLUSIVE, restriction.isLowerBoundInclusive() );
|
|
|
|
|
assertNull( CHECK_UPPER_BOUND, restriction.getUpperBound() );
|
|
|
|
@ -81,7 +81,7 @@ public void testRange()
|
|
|
|
|
range = VersionRange.createFromVersionSpec( "[1.0]" );
|
|
|
|
|
restrictions = range.getRestrictions();
|
|
|
|
|
assertEquals( CHECK_NUM_RESTRICTIONS, 1, restrictions.size() );
|
|
|
|
|
restriction = (Restriction) restrictions.get( 0 );
|
|
|
|
|
restriction = restrictions.get( 0 );
|
|
|
|
|
assertEquals( CHECK_LOWER_BOUND, "1.0", restriction.getLowerBound().toString() );
|
|
|
|
|
assertTrue( CHECK_LOWER_BOUND_INCLUSIVE, restriction.isLowerBoundInclusive() );
|
|
|
|
|
assertEquals( CHECK_UPPER_BOUND, "1.0", restriction.getUpperBound().toString() );
|
|
|
|
@ -93,7 +93,7 @@ public void testRange()
|
|
|
|
|
range = VersionRange.createFromVersionSpec( "[1.2,1.3]" );
|
|
|
|
|
restrictions = range.getRestrictions();
|
|
|
|
|
assertEquals( CHECK_NUM_RESTRICTIONS, 1, restrictions.size() );
|
|
|
|
|
restriction = (Restriction) restrictions.get( 0 );
|
|
|
|
|
restriction = restrictions.get( 0 );
|
|
|
|
|
assertEquals( CHECK_LOWER_BOUND, "1.2", restriction.getLowerBound().toString() );
|
|
|
|
|
assertTrue( CHECK_LOWER_BOUND_INCLUSIVE, restriction.isLowerBoundInclusive() );
|
|
|
|
|
assertEquals( CHECK_UPPER_BOUND, "1.3", restriction.getUpperBound().toString() );
|
|
|
|
@ -105,7 +105,7 @@ public void testRange()
|
|
|
|
|
range = VersionRange.createFromVersionSpec( "[1.0,2.0)" );
|
|
|
|
|
restrictions = range.getRestrictions();
|
|
|
|
|
assertEquals( CHECK_NUM_RESTRICTIONS, 1, restrictions.size() );
|
|
|
|
|
restriction = (Restriction) restrictions.get( 0 );
|
|
|
|
|
restriction = restrictions.get( 0 );
|
|
|
|
|
assertEquals( CHECK_LOWER_BOUND, "1.0", restriction.getLowerBound().toString() );
|
|
|
|
|
assertTrue( CHECK_LOWER_BOUND_INCLUSIVE, restriction.isLowerBoundInclusive() );
|
|
|
|
|
assertEquals( CHECK_UPPER_BOUND, "2.0", restriction.getUpperBound().toString() );
|
|
|
|
@ -117,7 +117,7 @@ public void testRange()
|
|
|
|
|
range = VersionRange.createFromVersionSpec( "[1.5,)" );
|
|
|
|
|
restrictions = range.getRestrictions();
|
|
|
|
|
assertEquals( CHECK_NUM_RESTRICTIONS, 1, restrictions.size() );
|
|
|
|
|
restriction = (Restriction) restrictions.get( 0 );
|
|
|
|
|
restriction = restrictions.get( 0 );
|
|
|
|
|
assertEquals( CHECK_LOWER_BOUND, "1.5", restriction.getLowerBound().toString() );
|
|
|
|
|
assertTrue( CHECK_LOWER_BOUND_INCLUSIVE, restriction.isLowerBoundInclusive() );
|
|
|
|
|
assertNull( CHECK_UPPER_BOUND, restriction.getUpperBound() );
|
|
|
|
@ -129,13 +129,13 @@ public void testRange()
|
|
|
|
|
range = VersionRange.createFromVersionSpec( "(,1.0],[1.2,)" );
|
|
|
|
|
restrictions = range.getRestrictions();
|
|
|
|
|
assertEquals( CHECK_NUM_RESTRICTIONS, 2, restrictions.size() );
|
|
|
|
|
restriction = (Restriction) restrictions.get( 0 );
|
|
|
|
|
restriction = restrictions.get( 0 );
|
|
|
|
|
assertNull( CHECK_LOWER_BOUND, restriction.getLowerBound() );
|
|
|
|
|
assertFalse( CHECK_LOWER_BOUND_INCLUSIVE, restriction.isLowerBoundInclusive() );
|
|
|
|
|
assertEquals( CHECK_UPPER_BOUND, "1.0", restriction.getUpperBound().toString() );
|
|
|
|
|
assertTrue( CHECK_UPPER_BOUND_INCLUSIVE, restriction.isUpperBoundInclusive() );
|
|
|
|
|
assertNull( CHECK_VERSION_RECOMMENDATION, range.getRecommendedVersion() );
|
|
|
|
|
restriction = (Restriction) restrictions.get( 1 );
|
|
|
|
|
restriction = restrictions.get( 1 );
|
|
|
|
|
assertEquals( CHECK_LOWER_BOUND, "1.2", restriction.getLowerBound().toString() );
|
|
|
|
|
assertTrue( CHECK_LOWER_BOUND_INCLUSIVE, restriction.isLowerBoundInclusive() );
|
|
|
|
|
assertNull( CHECK_UPPER_BOUND, restriction.getUpperBound() );
|
|
|
|
@ -183,7 +183,7 @@ public void testIntersections()
|
|
|
|
|
assertEquals( CHECK_VERSION_RECOMMENDATION, "1.0", mergedRange.getRecommendedVersion().toString() );
|
|
|
|
|
List<Restriction> restrictions = mergedRange.getRestrictions();
|
|
|
|
|
assertEquals( CHECK_NUM_RESTRICTIONS, 1, restrictions.size() );
|
|
|
|
|
Restriction restriction = (Restriction) restrictions.get( 0 );
|
|
|
|
|
Restriction restriction = restrictions.get( 0 );
|
|
|
|
|
assertNull( CHECK_LOWER_BOUND, restriction.getLowerBound() );
|
|
|
|
|
assertFalse( CHECK_LOWER_BOUND_INCLUSIVE, restriction.isLowerBoundInclusive() );
|
|
|
|
|
assertNull( CHECK_UPPER_BOUND, restriction.getUpperBound() );
|
|
|
|
@ -193,7 +193,7 @@ public void testIntersections()
|
|
|
|
|
assertEquals( CHECK_VERSION_RECOMMENDATION, "1.1", mergedRange.getRecommendedVersion().toString() );
|
|
|
|
|
restrictions = mergedRange.getRestrictions();
|
|
|
|
|
assertEquals( CHECK_NUM_RESTRICTIONS, 1, restrictions.size() );
|
|
|
|
|
restriction = (Restriction) restrictions.get( 0 );
|
|
|
|
|
restriction = restrictions.get( 0 );
|
|
|
|
|
assertNull( CHECK_LOWER_BOUND, restriction.getLowerBound() );
|
|
|
|
|
assertFalse( CHECK_LOWER_BOUND_INCLUSIVE, restriction.isLowerBoundInclusive() );
|
|
|
|
|
assertNull( CHECK_UPPER_BOUND, restriction.getUpperBound() );
|
|
|
|
@ -206,7 +206,7 @@ public void testIntersections()
|
|
|
|
|
assertEquals( CHECK_VERSION_RECOMMENDATION, "1.1", mergedRange.getRecommendedVersion().toString() );
|
|
|
|
|
restrictions = mergedRange.getRestrictions();
|
|
|
|
|
assertEquals( CHECK_NUM_RESTRICTIONS, 1, restrictions.size() );
|
|
|
|
|
restriction = (Restriction) restrictions.get( 0 );
|
|
|
|
|
restriction = restrictions.get( 0 );
|
|
|
|
|
assertEquals( CHECK_LOWER_BOUND, "1.0", restriction.getLowerBound().toString() );
|
|
|
|
|
assertTrue( CHECK_LOWER_BOUND_INCLUSIVE, restriction.isLowerBoundInclusive() );
|
|
|
|
|
assertNull( CHECK_UPPER_BOUND, restriction.getUpperBound() );
|
|
|
|
@ -218,7 +218,7 @@ public void testIntersections()
|
|
|
|
|
assertEquals( CHECK_VERSION_RECOMMENDATION, "1.1", mergedRange.getRecommendedVersion().toString() );
|
|
|
|
|
restrictions = mergedRange.getRestrictions();
|
|
|
|
|
assertEquals( CHECK_NUM_RESTRICTIONS, 1, restrictions.size() );
|
|
|
|
|
restriction = (Restriction) restrictions.get( 0 );
|
|
|
|
|
restriction = restrictions.get( 0 );
|
|
|
|
|
assertEquals( CHECK_LOWER_BOUND, "1.1", restriction.getLowerBound().toString() );
|
|
|
|
|
assertTrue( CHECK_LOWER_BOUND_INCLUSIVE, restriction.isLowerBoundInclusive() );
|
|
|
|
|
assertNull( CHECK_UPPER_BOUND, restriction.getUpperBound() );
|
|
|
|
@ -230,7 +230,7 @@ public void testIntersections()
|
|
|
|
|
assertEquals( CHECK_VERSION_RECOMMENDATION, "1.1", mergedRange.getRecommendedVersion().toString() );
|
|
|
|
|
restrictions = mergedRange.getRestrictions();
|
|
|
|
|
assertEquals( CHECK_NUM_RESTRICTIONS, 1, restrictions.size() );
|
|
|
|
|
restriction = (Restriction) restrictions.get( 0 );
|
|
|
|
|
restriction = restrictions.get( 0 );
|
|
|
|
|
assertEquals( CHECK_LOWER_BOUND, "1.1", restriction.getLowerBound().toString() );
|
|
|
|
|
assertTrue( CHECK_LOWER_BOUND_INCLUSIVE, restriction.isLowerBoundInclusive() );
|
|
|
|
|
assertEquals( CHECK_UPPER_BOUND, "1.1", restriction.getLowerBound().toString() );
|
|
|
|
@ -242,7 +242,7 @@ public void testIntersections()
|
|
|
|
|
assertNull( CHECK_VERSION_RECOMMENDATION, mergedRange.getRecommendedVersion() );
|
|
|
|
|
restrictions = mergedRange.getRestrictions();
|
|
|
|
|
assertEquals( CHECK_NUM_RESTRICTIONS, 1, restrictions.size() );
|
|
|
|
|
restriction = (Restriction) restrictions.get( 0 );
|
|
|
|
|
restriction = restrictions.get( 0 );
|
|
|
|
|
assertEquals( CHECK_LOWER_BOUND, "1.1", restriction.getLowerBound().toString() );
|
|
|
|
|
assertFalse( CHECK_LOWER_BOUND_INCLUSIVE, restriction.isLowerBoundInclusive() );
|
|
|
|
|
assertNull( CHECK_UPPER_BOUND, restriction.getUpperBound() );
|
|
|
|
@ -254,7 +254,7 @@ public void testIntersections()
|
|
|
|
|
assertNull( CHECK_VERSION_RECOMMENDATION, mergedRange.getRecommendedVersion() );
|
|
|
|
|
restrictions = mergedRange.getRestrictions();
|
|
|
|
|
assertEquals( CHECK_NUM_RESTRICTIONS, 1, restrictions.size() );
|
|
|
|
|
restriction = (Restriction) restrictions.get( 0 );
|
|
|
|
|
restriction = restrictions.get( 0 );
|
|
|
|
|
assertEquals( CHECK_LOWER_BOUND, "1.2", restriction.getLowerBound().toString() );
|
|
|
|
|
assertTrue( CHECK_LOWER_BOUND_INCLUSIVE, restriction.isLowerBoundInclusive() );
|
|
|
|
|
assertNull( CHECK_UPPER_BOUND, restriction.getUpperBound() );
|
|
|
|
@ -266,7 +266,7 @@ public void testIntersections()
|
|
|
|
|
assertEquals( CHECK_VERSION_RECOMMENDATION, "1.1", mergedRange.getRecommendedVersion().toString() );
|
|
|
|
|
restrictions = mergedRange.getRestrictions();
|
|
|
|
|
assertEquals( CHECK_NUM_RESTRICTIONS, 1, restrictions.size() );
|
|
|
|
|
restriction = (Restriction) restrictions.get( 0 );
|
|
|
|
|
restriction = restrictions.get( 0 );
|
|
|
|
|
assertNull( CHECK_LOWER_BOUND, restriction.getLowerBound() );
|
|
|
|
|
assertFalse( CHECK_LOWER_BOUND_INCLUSIVE, restriction.isLowerBoundInclusive() );
|
|
|
|
|
assertEquals( CHECK_UPPER_BOUND, "1.2", restriction.getUpperBound().toString() );
|
|
|
|
@ -278,7 +278,7 @@ public void testIntersections()
|
|
|
|
|
assertEquals( CHECK_VERSION_RECOMMENDATION, "1.1", mergedRange.getRecommendedVersion().toString() );
|
|
|
|
|
restrictions = mergedRange.getRestrictions();
|
|
|
|
|
assertEquals( CHECK_NUM_RESTRICTIONS, 1, restrictions.size() );
|
|
|
|
|
restriction = (Restriction) restrictions.get( 0 );
|
|
|
|
|
restriction = restrictions.get( 0 );
|
|
|
|
|
assertNull( CHECK_LOWER_BOUND, restriction.getLowerBound() );
|
|
|
|
|
assertFalse( CHECK_LOWER_BOUND_INCLUSIVE, restriction.isLowerBoundInclusive() );
|
|
|
|
|
assertEquals( CHECK_UPPER_BOUND, "1.1", restriction.getUpperBound().toString() );
|
|
|
|
@ -290,7 +290,7 @@ public void testIntersections()
|
|
|
|
|
assertNull( CHECK_VERSION_RECOMMENDATION, mergedRange.getRecommendedVersion() );
|
|
|
|
|
restrictions = mergedRange.getRestrictions();
|
|
|
|
|
assertEquals( CHECK_NUM_RESTRICTIONS, 1, restrictions.size() );
|
|
|
|
|
restriction = (Restriction) restrictions.get( 0 );
|
|
|
|
|
restriction = restrictions.get( 0 );
|
|
|
|
|
assertNull( CHECK_LOWER_BOUND, restriction.getLowerBound() );
|
|
|
|
|
assertFalse( CHECK_LOWER_BOUND_INCLUSIVE, restriction.isLowerBoundInclusive() );
|
|
|
|
|
assertEquals( CHECK_UPPER_BOUND, "1.1", restriction.getUpperBound().toString() );
|
|
|
|
@ -302,7 +302,7 @@ public void testIntersections()
|
|
|
|
|
assertNull( CHECK_VERSION_RECOMMENDATION, mergedRange.getRecommendedVersion() );
|
|
|
|
|
restrictions = mergedRange.getRestrictions();
|
|
|
|
|
assertEquals( CHECK_NUM_RESTRICTIONS, 1, restrictions.size() );
|
|
|
|
|
restriction = (Restriction) restrictions.get( 0 );
|
|
|
|
|
restriction = restrictions.get( 0 );
|
|
|
|
|
assertNull( CHECK_LOWER_BOUND, restriction.getLowerBound() );
|
|
|
|
|
assertFalse( CHECK_LOWER_BOUND_INCLUSIVE, restriction.isLowerBoundInclusive() );
|
|
|
|
|
assertEquals( CHECK_UPPER_BOUND, "1.0", restriction.getUpperBound().toString() );
|
|
|
|
@ -314,12 +314,12 @@ public void testIntersections()
|
|
|
|
|
assertEquals( CHECK_VERSION_RECOMMENDATION, "1.2", mergedRange.getRecommendedVersion().toString() );
|
|
|
|
|
restrictions = mergedRange.getRestrictions();
|
|
|
|
|
assertEquals( CHECK_NUM_RESTRICTIONS, 2, restrictions.size() );
|
|
|
|
|
restriction = (Restriction) restrictions.get( 0 );
|
|
|
|
|
restriction = restrictions.get( 0 );
|
|
|
|
|
assertNull( CHECK_LOWER_BOUND, restriction.getLowerBound() );
|
|
|
|
|
assertFalse( CHECK_LOWER_BOUND_INCLUSIVE, restriction.isLowerBoundInclusive() );
|
|
|
|
|
assertEquals( CHECK_UPPER_BOUND, "1.0", restriction.getUpperBound().toString() );
|
|
|
|
|
assertTrue( CHECK_UPPER_BOUND_INCLUSIVE, restriction.isUpperBoundInclusive() );
|
|
|
|
|
restriction = (Restriction) restrictions.get( 1 );
|
|
|
|
|
restriction = restrictions.get( 1 );
|
|
|
|
|
assertEquals( CHECK_LOWER_BOUND, "1.1", restriction.getLowerBound().toString() );
|
|
|
|
|
assertTrue( CHECK_LOWER_BOUND_INCLUSIVE, restriction.isLowerBoundInclusive() );
|
|
|
|
|
assertNull( CHECK_UPPER_BOUND, restriction.getUpperBound() );
|
|
|
|
@ -331,12 +331,12 @@ public void testIntersections()
|
|
|
|
|
assertNull( CHECK_VERSION_RECOMMENDATION, mergedRange.getRecommendedVersion() );
|
|
|
|
|
restrictions = mergedRange.getRestrictions();
|
|
|
|
|
assertEquals( CHECK_NUM_RESTRICTIONS, 2, restrictions.size() );
|
|
|
|
|
restriction = (Restriction) restrictions.get( 0 );
|
|
|
|
|
restriction = restrictions.get( 0 );
|
|
|
|
|
assertNull( CHECK_LOWER_BOUND, restriction.getLowerBound() );
|
|
|
|
|
assertFalse( CHECK_LOWER_BOUND_INCLUSIVE, restriction.isLowerBoundInclusive() );
|
|
|
|
|
assertEquals( CHECK_UPPER_BOUND, "1.0", restriction.getUpperBound().toString() );
|
|
|
|
|
assertTrue( CHECK_UPPER_BOUND_INCLUSIVE, restriction.isUpperBoundInclusive() );
|
|
|
|
|
restriction = (Restriction) restrictions.get( 1 );
|
|
|
|
|
restriction = restrictions.get( 1 );
|
|
|
|
|
assertEquals( CHECK_LOWER_BOUND, "1.1", restriction.getLowerBound().toString() );
|
|
|
|
|
assertTrue( CHECK_LOWER_BOUND_INCLUSIVE, restriction.isLowerBoundInclusive() );
|
|
|
|
|
assertNull( CHECK_UPPER_BOUND, restriction.getUpperBound() );
|
|
|
|
@ -348,12 +348,12 @@ public void testIntersections()
|
|
|
|
|
assertNull( CHECK_VERSION_RECOMMENDATION, mergedRange.getRecommendedVersion() );
|
|
|
|
|
restrictions = mergedRange.getRestrictions();
|
|
|
|
|
assertEquals( CHECK_NUM_RESTRICTIONS, 2, restrictions.size() );
|
|
|
|
|
restriction = (Restriction) restrictions.get( 0 );
|
|
|
|
|
restriction = restrictions.get( 0 );
|
|
|
|
|
assertNull( CHECK_LOWER_BOUND, restriction.getLowerBound() );
|
|
|
|
|
assertFalse( CHECK_LOWER_BOUND_INCLUSIVE, restriction.isLowerBoundInclusive() );
|
|
|
|
|
assertEquals( CHECK_UPPER_BOUND, "1.1", restriction.getUpperBound().toString() );
|
|
|
|
|
assertFalse( CHECK_UPPER_BOUND_INCLUSIVE, restriction.isUpperBoundInclusive() );
|
|
|
|
|
restriction = (Restriction) restrictions.get( 1 );
|
|
|
|
|
restriction = restrictions.get( 1 );
|
|
|
|
|
assertEquals( CHECK_LOWER_BOUND, "1.1", restriction.getLowerBound().toString() );
|
|
|
|
|
assertFalse( CHECK_LOWER_BOUND_INCLUSIVE, restriction.isLowerBoundInclusive() );
|
|
|
|
|
assertNull( CHECK_UPPER_BOUND, restriction.getUpperBound() );
|
|
|
|
@ -365,7 +365,7 @@ public void testIntersections()
|
|
|
|
|
assertNull( CHECK_VERSION_RECOMMENDATION, mergedRange.getRecommendedVersion() );
|
|
|
|
|
restrictions = mergedRange.getRestrictions();
|
|
|
|
|
assertEquals( CHECK_NUM_RESTRICTIONS, 1, restrictions.size() );
|
|
|
|
|
restriction = (Restriction) restrictions.get( 0 );
|
|
|
|
|
restriction = restrictions.get( 0 );
|
|
|
|
|
assertEquals( CHECK_LOWER_BOUND, "1.1", restriction.getLowerBound().toString() );
|
|
|
|
|
assertFalse( CHECK_LOWER_BOUND_INCLUSIVE, restriction.isLowerBoundInclusive() );
|
|
|
|
|
assertEquals( CHECK_UPPER_BOUND, "1.3", restriction.getUpperBound().toString() );
|
|
|
|
@ -377,7 +377,7 @@ public void testIntersections()
|
|
|
|
|
assertNull( CHECK_VERSION_RECOMMENDATION, mergedRange.getRecommendedVersion() );
|
|
|
|
|
restrictions = mergedRange.getRestrictions();
|
|
|
|
|
assertEquals( CHECK_NUM_RESTRICTIONS, 1, restrictions.size() );
|
|
|
|
|
restriction = (Restriction) restrictions.get( 0 );
|
|
|
|
|
restriction = restrictions.get( 0 );
|
|
|
|
|
assertEquals( CHECK_LOWER_BOUND, "1.2", restriction.getLowerBound().toString() );
|
|
|
|
|
assertTrue( CHECK_LOWER_BOUND_INCLUSIVE, restriction.isLowerBoundInclusive() );
|
|
|
|
|
assertEquals( CHECK_UPPER_BOUND, "1.3", restriction.getUpperBound().toString() );
|
|
|
|
@ -389,7 +389,7 @@ public void testIntersections()
|
|
|
|
|
assertNull( CHECK_VERSION_RECOMMENDATION, mergedRange.getRecommendedVersion() );
|
|
|
|
|
restrictions = mergedRange.getRestrictions();
|
|
|
|
|
assertEquals( CHECK_NUM_RESTRICTIONS, 1, restrictions.size() );
|
|
|
|
|
restriction = (Restriction) restrictions.get( 0 );
|
|
|
|
|
restriction = restrictions.get( 0 );
|
|
|
|
|
assertEquals( CHECK_LOWER_BOUND, "1.2", restriction.getLowerBound().toString() );
|
|
|
|
|
assertTrue( CHECK_LOWER_BOUND_INCLUSIVE, restriction.isLowerBoundInclusive() );
|
|
|
|
|
assertEquals( CHECK_UPPER_BOUND, "1.3", restriction.getUpperBound().toString() );
|
|
|
|
@ -401,7 +401,7 @@ public void testIntersections()
|
|
|
|
|
assertNull( CHECK_VERSION_RECOMMENDATION, mergedRange.getRecommendedVersion() );
|
|
|
|
|
restrictions = mergedRange.getRestrictions();
|
|
|
|
|
assertEquals( CHECK_NUM_RESTRICTIONS, 1, restrictions.size() );
|
|
|
|
|
restriction = (Restriction) restrictions.get( 0 );
|
|
|
|
|
restriction = restrictions.get( 0 );
|
|
|
|
|
assertEquals( CHECK_LOWER_BOUND, "1.2", restriction.getLowerBound().toString() );
|
|
|
|
|
assertTrue( CHECK_LOWER_BOUND_INCLUSIVE, restriction.isLowerBoundInclusive() );
|
|
|
|
|
assertEquals( CHECK_UPPER_BOUND, "1.3", restriction.getUpperBound().toString() );
|
|
|
|
@ -413,7 +413,7 @@ public void testIntersections()
|
|
|
|
|
assertNull( CHECK_VERSION_RECOMMENDATION, mergedRange.getRecommendedVersion() );
|
|
|
|
|
restrictions = mergedRange.getRestrictions();
|
|
|
|
|
assertEquals( CHECK_NUM_RESTRICTIONS, 1, restrictions.size() );
|
|
|
|
|
restriction = (Restriction) restrictions.get( 0 );
|
|
|
|
|
restriction = restrictions.get( 0 );
|
|
|
|
|
assertEquals( CHECK_LOWER_BOUND, "1.2", restriction.getLowerBound().toString() );
|
|
|
|
|
assertFalse( CHECK_LOWER_BOUND_INCLUSIVE, restriction.isLowerBoundInclusive() );
|
|
|
|
|
assertEquals( CHECK_UPPER_BOUND, "1.3", restriction.getUpperBound().toString() );
|
|
|
|
@ -425,7 +425,7 @@ public void testIntersections()
|
|
|
|
|
assertNull( CHECK_VERSION_RECOMMENDATION, mergedRange.getRecommendedVersion() );
|
|
|
|
|
restrictions = mergedRange.getRestrictions();
|
|
|
|
|
assertEquals( CHECK_NUM_RESTRICTIONS, 1, restrictions.size() );
|
|
|
|
|
restriction = (Restriction) restrictions.get( 0 );
|
|
|
|
|
restriction = restrictions.get( 0 );
|
|
|
|
|
assertEquals( CHECK_LOWER_BOUND, "1.2", restriction.getLowerBound().toString() );
|
|
|
|
|
assertFalse( CHECK_LOWER_BOUND_INCLUSIVE, restriction.isLowerBoundInclusive() );
|
|
|
|
|
assertEquals( CHECK_UPPER_BOUND, "1.3", restriction.getUpperBound().toString() );
|
|
|
|
@ -437,7 +437,7 @@ public void testIntersections()
|
|
|
|
|
assertNull( CHECK_VERSION_RECOMMENDATION, mergedRange.getRecommendedVersion() );
|
|
|
|
|
restrictions = mergedRange.getRestrictions();
|
|
|
|
|
assertEquals( CHECK_NUM_RESTRICTIONS, 1, restrictions.size() );
|
|
|
|
|
restriction = (Restriction) restrictions.get( 0 );
|
|
|
|
|
restriction = restrictions.get( 0 );
|
|
|
|
|
assertEquals( CHECK_LOWER_BOUND, "1.2", restriction.getLowerBound().toString() );
|
|
|
|
|
assertTrue( CHECK_LOWER_BOUND_INCLUSIVE, restriction.isLowerBoundInclusive() );
|
|
|
|
|
assertEquals( CHECK_UPPER_BOUND, "1.3", restriction.getUpperBound().toString() );
|
|
|
|
@ -449,7 +449,7 @@ public void testIntersections()
|
|
|
|
|
assertNull( CHECK_VERSION_RECOMMENDATION, mergedRange.getRecommendedVersion() );
|
|
|
|
|
restrictions = mergedRange.getRestrictions();
|
|
|
|
|
assertEquals( CHECK_NUM_RESTRICTIONS, 1, restrictions.size() );
|
|
|
|
|
restriction = (Restriction) restrictions.get( 0 );
|
|
|
|
|
restriction = restrictions.get( 0 );
|
|
|
|
|
assertEquals( CHECK_LOWER_BOUND, "1.1", restriction.getLowerBound().toString() );
|
|
|
|
|
assertTrue( CHECK_LOWER_BOUND_INCLUSIVE, restriction.isLowerBoundInclusive() );
|
|
|
|
|
assertEquals( CHECK_UPPER_BOUND, "1.1", restriction.getUpperBound().toString() );
|
|
|
|
@ -468,7 +468,7 @@ public void testIntersections()
|
|
|
|
|
assertNull( CHECK_VERSION_RECOMMENDATION, mergedRange.getRecommendedVersion() );
|
|
|
|
|
restrictions = mergedRange.getRestrictions();
|
|
|
|
|
assertEquals( CHECK_NUM_RESTRICTIONS, 1, restrictions.size() );
|
|
|
|
|
restriction = (Restriction) restrictions.get( 0 );
|
|
|
|
|
restriction = restrictions.get( 0 );
|
|
|
|
|
assertEquals( CHECK_LOWER_BOUND, "1.1", restriction.getLowerBound().toString() );
|
|
|
|
|
assertTrue( CHECK_LOWER_BOUND_INCLUSIVE, restriction.isLowerBoundInclusive() );
|
|
|
|
|
assertEquals( CHECK_UPPER_BOUND, "1.1", restriction.getUpperBound().toString() );
|
|
|
|
@ -480,7 +480,7 @@ public void testIntersections()
|
|
|
|
|
assertNull( CHECK_VERSION_RECOMMENDATION, mergedRange.getRecommendedVersion() );
|
|
|
|
|
restrictions = mergedRange.getRestrictions();
|
|
|
|
|
assertEquals( CHECK_NUM_RESTRICTIONS, 1, restrictions.size() );
|
|
|
|
|
restriction = (Restriction) restrictions.get( 0 );
|
|
|
|
|
restriction = restrictions.get( 0 );
|
|
|
|
|
assertEquals( CHECK_LOWER_BOUND, "1.4", restriction.getLowerBound().toString() );
|
|
|
|
|
assertTrue( CHECK_LOWER_BOUND_INCLUSIVE, restriction.isLowerBoundInclusive() );
|
|
|
|
|
assertEquals( CHECK_UPPER_BOUND, "1.4", restriction.getUpperBound().toString() );
|
|
|
|
@ -492,12 +492,12 @@ public void testIntersections()
|
|
|
|
|
assertNull( CHECK_VERSION_RECOMMENDATION, mergedRange.getRecommendedVersion() );
|
|
|
|
|
restrictions = mergedRange.getRestrictions();
|
|
|
|
|
assertEquals( CHECK_NUM_RESTRICTIONS, 2, restrictions.size() );
|
|
|
|
|
restriction = (Restriction) restrictions.get( 0 );
|
|
|
|
|
restriction = restrictions.get( 0 );
|
|
|
|
|
assertEquals( CHECK_LOWER_BOUND, "1.1", restriction.getLowerBound().toString() );
|
|
|
|
|
assertTrue( CHECK_LOWER_BOUND_INCLUSIVE, restriction.isLowerBoundInclusive() );
|
|
|
|
|
assertEquals( CHECK_UPPER_BOUND, "1.2", restriction.getUpperBound().toString() );
|
|
|
|
|
assertTrue( CHECK_UPPER_BOUND_INCLUSIVE, restriction.isUpperBoundInclusive() );
|
|
|
|
|
restriction = (Restriction) restrictions.get( 1 );
|
|
|
|
|
restriction = restrictions.get( 1 );
|
|
|
|
|
assertEquals( CHECK_LOWER_BOUND, "1.3", restriction.getLowerBound().toString() );
|
|
|
|
|
assertTrue( CHECK_LOWER_BOUND_INCLUSIVE, restriction.isLowerBoundInclusive() );
|
|
|
|
|
assertEquals( CHECK_UPPER_BOUND, "1.4", restriction.getUpperBound().toString() );
|
|
|
|
@ -509,12 +509,12 @@ public void testIntersections()
|
|
|
|
|
assertNull( CHECK_VERSION_RECOMMENDATION, mergedRange.getRecommendedVersion() );
|
|
|
|
|
restrictions = mergedRange.getRestrictions();
|
|
|
|
|
assertEquals( CHECK_NUM_RESTRICTIONS, 2, restrictions.size() );
|
|
|
|
|
restriction = (Restriction) restrictions.get( 0 );
|
|
|
|
|
restriction = restrictions.get( 0 );
|
|
|
|
|
assertEquals( CHECK_LOWER_BOUND, "1.1", restriction.getLowerBound().toString() );
|
|
|
|
|
assertTrue( CHECK_LOWER_BOUND_INCLUSIVE, restriction.isLowerBoundInclusive() );
|
|
|
|
|
assertEquals( CHECK_UPPER_BOUND, "1.2", restriction.getUpperBound().toString() );
|
|
|
|
|
assertFalse( CHECK_UPPER_BOUND_INCLUSIVE, restriction.isUpperBoundInclusive() );
|
|
|
|
|
restriction = (Restriction) restrictions.get( 1 );
|
|
|
|
|
restriction = restrictions.get( 1 );
|
|
|
|
|
assertEquals( CHECK_LOWER_BOUND, "1.3", restriction.getLowerBound().toString() );
|
|
|
|
|
assertFalse( CHECK_LOWER_BOUND_INCLUSIVE, restriction.isLowerBoundInclusive() );
|
|
|
|
|
assertEquals( CHECK_UPPER_BOUND, "1.4", restriction.getUpperBound().toString() );
|
|
|
|
@ -526,12 +526,12 @@ public void testIntersections()
|
|
|
|
|
assertNull( CHECK_VERSION_RECOMMENDATION, mergedRange.getRecommendedVersion() );
|
|
|
|
|
restrictions = mergedRange.getRestrictions();
|
|
|
|
|
assertEquals( CHECK_NUM_RESTRICTIONS, 2, restrictions.size() );
|
|
|
|
|
restriction = (Restriction) restrictions.get( 0 );
|
|
|
|
|
restriction = restrictions.get( 0 );
|
|
|
|
|
assertEquals( CHECK_LOWER_BOUND, "1.1", restriction.getLowerBound().toString() );
|
|
|
|
|
assertFalse( CHECK_LOWER_BOUND_INCLUSIVE, restriction.isLowerBoundInclusive() );
|
|
|
|
|
assertEquals( CHECK_UPPER_BOUND, "1.2", restriction.getUpperBound().toString() );
|
|
|
|
|
assertTrue( CHECK_UPPER_BOUND_INCLUSIVE, restriction.isUpperBoundInclusive() );
|
|
|
|
|
restriction = (Restriction) restrictions.get( 1 );
|
|
|
|
|
restriction = restrictions.get( 1 );
|
|
|
|
|
assertEquals( CHECK_LOWER_BOUND, "1.3", restriction.getLowerBound().toString() );
|
|
|
|
|
assertTrue( CHECK_LOWER_BOUND_INCLUSIVE, restriction.isLowerBoundInclusive() );
|
|
|
|
|
assertEquals( CHECK_UPPER_BOUND, "1.4", restriction.getUpperBound().toString() );
|
|
|
|
@ -543,12 +543,12 @@ public void testIntersections()
|
|
|
|
|
assertNull( CHECK_VERSION_RECOMMENDATION, mergedRange.getRecommendedVersion() );
|
|
|
|
|
restrictions = mergedRange.getRestrictions();
|
|
|
|
|
assertEquals( CHECK_NUM_RESTRICTIONS, 2, restrictions.size() );
|
|
|
|
|
restriction = (Restriction) restrictions.get( 0 );
|
|
|
|
|
restriction = restrictions.get( 0 );
|
|
|
|
|
assertEquals( CHECK_LOWER_BOUND, "1.1", restriction.getLowerBound().toString() );
|
|
|
|
|
assertFalse( CHECK_LOWER_BOUND_INCLUSIVE, restriction.isLowerBoundInclusive() );
|
|
|
|
|
assertEquals( CHECK_UPPER_BOUND, "1.2", restriction.getUpperBound().toString() );
|
|
|
|
|
assertFalse( CHECK_UPPER_BOUND_INCLUSIVE, restriction.isUpperBoundInclusive() );
|
|
|
|
|
restriction = (Restriction) restrictions.get( 1 );
|
|
|
|
|
restriction = restrictions.get( 1 );
|
|
|
|
|
assertEquals( CHECK_LOWER_BOUND, "1.3", restriction.getLowerBound().toString() );
|
|
|
|
|
assertFalse( CHECK_LOWER_BOUND_INCLUSIVE, restriction.isLowerBoundInclusive() );
|
|
|
|
|
assertEquals( CHECK_UPPER_BOUND, "1.4", restriction.getUpperBound().toString() );
|
|
|
|
@ -581,12 +581,12 @@ public void testIntersections()
|
|
|
|
|
assertNull( CHECK_VERSION_RECOMMENDATION, mergedRange.getRecommendedVersion() );
|
|
|
|
|
restrictions = mergedRange.getRestrictions();
|
|
|
|
|
assertEquals( CHECK_NUM_RESTRICTIONS, 2, restrictions.size() );
|
|
|
|
|
restriction = (Restriction) restrictions.get( 0 );
|
|
|
|
|
restriction = restrictions.get( 0 );
|
|
|
|
|
assertEquals( CHECK_LOWER_BOUND, "1.1", restriction.getLowerBound().toString() );
|
|
|
|
|
assertTrue( CHECK_LOWER_BOUND_INCLUSIVE, restriction.isLowerBoundInclusive() );
|
|
|
|
|
assertEquals( CHECK_UPPER_BOUND, "1.2", restriction.getUpperBound().toString() );
|
|
|
|
|
assertTrue( CHECK_UPPER_BOUND_INCLUSIVE, restriction.isUpperBoundInclusive() );
|
|
|
|
|
restriction = (Restriction) restrictions.get( 1 );
|
|
|
|
|
restriction = restrictions.get( 1 );
|
|
|
|
|
assertEquals( CHECK_LOWER_BOUND, "1.3", restriction.getLowerBound().toString() );
|
|
|
|
|
assertTrue( CHECK_LOWER_BOUND_INCLUSIVE, restriction.isLowerBoundInclusive() );
|
|
|
|
|
assertEquals( CHECK_UPPER_BOUND, "1.4", restriction.getUpperBound().toString() );
|
|
|
|
@ -598,17 +598,17 @@ public void testIntersections()
|
|
|
|
|
assertNull( CHECK_VERSION_RECOMMENDATION, mergedRange.getRecommendedVersion() );
|
|
|
|
|
restrictions = mergedRange.getRestrictions();
|
|
|
|
|
assertEquals( CHECK_NUM_RESTRICTIONS, 3, restrictions.size() );
|
|
|
|
|
restriction = (Restriction) restrictions.get( 0 );
|
|
|
|
|
restriction = restrictions.get( 0 );
|
|
|
|
|
assertEquals( CHECK_LOWER_BOUND, "1.1", restriction.getLowerBound().toString() );
|
|
|
|
|
assertTrue( CHECK_LOWER_BOUND_INCLUSIVE, restriction.isLowerBoundInclusive() );
|
|
|
|
|
assertEquals( CHECK_UPPER_BOUND, "1.2", restriction.getUpperBound().toString() );
|
|
|
|
|
assertTrue( CHECK_UPPER_BOUND_INCLUSIVE, restriction.isUpperBoundInclusive() );
|
|
|
|
|
restriction = (Restriction) restrictions.get( 1 );
|
|
|
|
|
restriction = restrictions.get( 1 );
|
|
|
|
|
assertEquals( CHECK_LOWER_BOUND, "1.3", restriction.getLowerBound().toString() );
|
|
|
|
|
assertTrue( CHECK_LOWER_BOUND_INCLUSIVE, restriction.isLowerBoundInclusive() );
|
|
|
|
|
assertEquals( CHECK_UPPER_BOUND, "1.4", restriction.getUpperBound().toString() );
|
|
|
|
|
assertTrue( CHECK_UPPER_BOUND_INCLUSIVE, restriction.isUpperBoundInclusive() );
|
|
|
|
|
restriction = (Restriction) restrictions.get( 2 );
|
|
|
|
|
restriction = restrictions.get( 2 );
|
|
|
|
|
assertEquals( CHECK_LOWER_BOUND, "1.5", restriction.getLowerBound().toString() );
|
|
|
|
|
assertTrue( CHECK_LOWER_BOUND_INCLUSIVE, restriction.isLowerBoundInclusive() );
|
|
|
|
|
assertEquals( CHECK_UPPER_BOUND, "1.5", restriction.getUpperBound().toString() );
|
|
|
|
@ -620,17 +620,17 @@ public void testIntersections()
|
|
|
|
|
assertNull( CHECK_VERSION_RECOMMENDATION, mergedRange.getRecommendedVersion() );
|
|
|
|
|
restrictions = mergedRange.getRestrictions();
|
|
|
|
|
assertEquals( CHECK_NUM_RESTRICTIONS, 3, restrictions.size() );
|
|
|
|
|
restriction = (Restriction) restrictions.get( 0 );
|
|
|
|
|
restriction = restrictions.get( 0 );
|
|
|
|
|
assertEquals( CHECK_LOWER_BOUND, "1.1", restriction.getLowerBound().toString() );
|
|
|
|
|
assertTrue( CHECK_LOWER_BOUND_INCLUSIVE, restriction.isLowerBoundInclusive() );
|
|
|
|
|
assertEquals( CHECK_UPPER_BOUND, "1.2", restriction.getUpperBound().toString() );
|
|
|
|
|
assertTrue( CHECK_UPPER_BOUND_INCLUSIVE, restriction.isUpperBoundInclusive() );
|
|
|
|
|
restriction = (Restriction) restrictions.get( 1 );
|
|
|
|
|
restriction = restrictions.get( 1 );
|
|
|
|
|
assertEquals( CHECK_LOWER_BOUND, "1.3", restriction.getLowerBound().toString() );
|
|
|
|
|
assertTrue( CHECK_LOWER_BOUND_INCLUSIVE, restriction.isLowerBoundInclusive() );
|
|
|
|
|
assertEquals( CHECK_UPPER_BOUND, "1.4", restriction.getUpperBound().toString() );
|
|
|
|
|
assertTrue( CHECK_UPPER_BOUND_INCLUSIVE, restriction.isUpperBoundInclusive() );
|
|
|
|
|
restriction = (Restriction) restrictions.get( 2 );
|
|
|
|
|
restriction = restrictions.get( 2 );
|
|
|
|
|
assertEquals( CHECK_LOWER_BOUND, "1.5", restriction.getLowerBound().toString() );
|
|
|
|
|
assertTrue( CHECK_LOWER_BOUND_INCLUSIVE, restriction.isLowerBoundInclusive() );
|
|
|
|
|
assertEquals( CHECK_UPPER_BOUND, "1.6", restriction.getUpperBound().toString() );
|
|
|
|
|