Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBrian Vosburgh2016-06-17 15:59:49 +0000
committerBrian Vosburgh2017-05-18 22:37:12 +0000
commit6ac3335fb9ba983b1c15cafa71209848456d91b1 (patch)
tree01b078f8b5f4ab3abb6dae26ffe20b9a2d619d83 /common/tests
parent4289be40311f911f80b0386e10c34473daa90984 (diff)
downloadwebtools.dali-6ac3335fb9ba983b1c15cafa71209848456d91b1.tar.gz
webtools.dali-6ac3335fb9ba983b1c15cafa71209848456d91b1.tar.xz
webtools.dali-6ac3335fb9ba983b1c15cafa71209848456d91b1.zip
remove generic type from various meta-collection predicates
Diffstat (limited to 'common/tests')
-rw-r--r--common/tests/org.eclipse.jpt.common.utility.tests/src/org/eclipse/jpt/common/utility/tests/internal/predicate/CollectionIsEmptyPredicateTests.java6
-rw-r--r--common/tests/org.eclipse.jpt.common.utility.tests/src/org/eclipse/jpt/common/utility/tests/internal/predicate/CollectionSizeEqualsPredicateTests.java14
2 files changed, 10 insertions, 10 deletions
diff --git a/common/tests/org.eclipse.jpt.common.utility.tests/src/org/eclipse/jpt/common/utility/tests/internal/predicate/CollectionIsEmptyPredicateTests.java b/common/tests/org.eclipse.jpt.common.utility.tests/src/org/eclipse/jpt/common/utility/tests/internal/predicate/CollectionIsEmptyPredicateTests.java
index e4b0db7a66..054226847b 100644
--- a/common/tests/org.eclipse.jpt.common.utility.tests/src/org/eclipse/jpt/common/utility/tests/internal/predicate/CollectionIsEmptyPredicateTests.java
+++ b/common/tests/org.eclipse.jpt.common.utility.tests/src/org/eclipse/jpt/common/utility/tests/internal/predicate/CollectionIsEmptyPredicateTests.java
@@ -26,7 +26,7 @@ public class CollectionIsEmptyPredicateTests
public void testEvaluate() {
Collection<String> list = new ArrayList<>();
- Predicate<Collection<String>> predicate = PredicateTools.collectionIsEmptyPredicate();
+ Predicate<Collection<?>> predicate = PredicateTools.collectionIsEmptyPredicate();
assertTrue(predicate.evaluate(list));
list.add("foo");
assertFalse(predicate.evaluate(list));
@@ -35,12 +35,12 @@ public class CollectionIsEmptyPredicateTests
}
public void testToString() {
- Predicate<Collection<String>> predicate = PredicateTools.collectionIsEmptyPredicate();
+ Predicate<Collection<?>> predicate = PredicateTools.collectionIsEmptyPredicate();
assertEquals("CollectionIsEmptyPredicate", predicate.toString());
}
public void testSerialization() throws Exception {
- Predicate<Collection<String>> predicate = PredicateTools.collectionIsEmptyPredicate();
+ Predicate<Collection<?>> predicate = PredicateTools.collectionIsEmptyPredicate();
assertSame(predicate, TestTools.serialize(predicate));
}
}
diff --git a/common/tests/org.eclipse.jpt.common.utility.tests/src/org/eclipse/jpt/common/utility/tests/internal/predicate/CollectionSizeEqualsPredicateTests.java b/common/tests/org.eclipse.jpt.common.utility.tests/src/org/eclipse/jpt/common/utility/tests/internal/predicate/CollectionSizeEqualsPredicateTests.java
index 334ccd72d5..f01e8d1e97 100644
--- a/common/tests/org.eclipse.jpt.common.utility.tests/src/org/eclipse/jpt/common/utility/tests/internal/predicate/CollectionSizeEqualsPredicateTests.java
+++ b/common/tests/org.eclipse.jpt.common.utility.tests/src/org/eclipse/jpt/common/utility/tests/internal/predicate/CollectionSizeEqualsPredicateTests.java
@@ -27,7 +27,7 @@ public class CollectionSizeEqualsPredicateTests
public void testEvaluate() {
Collection<String> list = new ArrayList<>();
- Predicate<Collection<String>> predicate = PredicateTools.collectionSizeEqualsPredicate(2);
+ Predicate<Collection<?>> predicate = PredicateTools.collectionSizeEqualsPredicate(2);
assertFalse(predicate.evaluate(list));
list.add("foo");
assertFalse(predicate.evaluate(list));
@@ -44,14 +44,14 @@ public class CollectionSizeEqualsPredicateTests
}
public void testGetSize() throws Exception {
- CollectionSizeEqualsPredicate<Collection<String>> predicate = (CollectionSizeEqualsPredicate<Collection<String>>) PredicateTools.<Collection<String>>collectionSizeEqualsPredicate(2);
+ CollectionSizeEqualsPredicate predicate = (CollectionSizeEqualsPredicate) PredicateTools.collectionSizeEqualsPredicate(2);
assertEquals(2, predicate.getSize());
}
public void testEquals() throws Exception {
- Predicate<Collection<String>> predicate1 = PredicateTools.collectionSizeEqualsPredicate(2);
+ Predicate<Collection<?>> predicate1 = PredicateTools.collectionSizeEqualsPredicate(2);
assertFalse(predicate1.equals(null));
- Predicate<Collection<String>> predicate2 = PredicateTools.collectionSizeEqualsPredicate(2);
+ Predicate<Collection<?>> predicate2 = PredicateTools.collectionSizeEqualsPredicate(2);
assertTrue(predicate1.equals(predicate2));
predicate2 = PredicateTools.collectionSizeEqualsPredicate(3);
assertFalse(predicate1.equals(predicate2));
@@ -60,17 +60,17 @@ public class CollectionSizeEqualsPredicateTests
}
public void testHashCode() throws Exception {
- Predicate<Collection<String>> predicate = PredicateTools.collectionSizeEqualsPredicate(2);
+ Predicate<Collection<?>> predicate = PredicateTools.collectionSizeEqualsPredicate(2);
assertEquals(2, predicate.hashCode());
}
public void testToString() {
- Predicate<Collection<String>> predicate = PredicateTools.collectionSizeEqualsPredicate(2);
+ Predicate<Collection<?>> predicate = PredicateTools.collectionSizeEqualsPredicate(2);
assertTrue(predicate.toString().indexOf("(2)") != -1);
}
public void testSerialization() throws Exception {
- Predicate<Collection<String>> predicate = PredicateTools.collectionSizeEqualsPredicate(2);
+ Predicate<Collection<?>> predicate = PredicateTools.collectionSizeEqualsPredicate(2);
assertEquals(predicate, TestTools.serialize(predicate));
}
}

Back to the top