From 86f323b2a73c9c250fbe25b828435aa936704ab3 Mon Sep 17 00:00:00 2001 From: Paul Duffin Date: Wed, 14 Dec 2016 12:42:07 +0000 Subject: Revert matchers back to 4.10 to compile against Hamcrest 1.1 JUnit 4.12 is supposed to be built against Hamcrest 1.3 or above but external/hamcrest is still at 1.1. This reverts affected files back to their 4.10 version so that they will compile against Hamcrest 1.1 for now. Bug: 33613916 Test: make checkbuild Change-Id: Ie3c15047aa5a942ed0987c31c345725bef4db3d4 --- src/main/java/org/junit/Assume.java | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) (limited to 'src/main/java/org/junit/Assume.java') diff --git a/src/main/java/org/junit/Assume.java b/src/main/java/org/junit/Assume.java index b7687f7..c96ff99 100644 --- a/src/main/java/org/junit/Assume.java +++ b/src/main/java/org/junit/Assume.java @@ -1,12 +1,12 @@ package org.junit; import static java.util.Arrays.asList; -import static org.hamcrest.CoreMatchers.everyItem; import static org.hamcrest.CoreMatchers.is; import static org.hamcrest.CoreMatchers.notNullValue; import static org.hamcrest.CoreMatchers.nullValue; import org.hamcrest.Matcher; +import org.junit.internal.matchers.Each; /** * A set of methods useful for stating assumptions about the conditions in which a test is meaningful. @@ -66,12 +66,13 @@ public class Assume { assumeTrue(message, !b); } - /** - * If called with one or more null elements in objects, the test will halt and be ignored. - */ - public static void assumeNotNull(Object... objects) { - assumeThat(asList(objects), everyItem(notNullValue())); - } + /** + * If called with one or more null elements in objects, the test will halt and be ignored. + * @param objects + */ + public static void assumeNotNull(Object... objects) { + assumeThat(asList(objects), Each.each(notNullValue())); + } /** * Call to assume that actual satisfies the condition specified by matcher. -- cgit v1.2.3