类 MatcherAssertionErrors
- java.lang.Object
- org.springframework.test.util.MatcherAssertionErrors
@Deprecated public abstract class MatcherAssertionErrors extends Object
已过时。as of Spring 4.2, in favor of the originalMatcherAssert
class with JUnit 4.9 / Hamcrest 1.3A replacement ofMatcherAssert
that removes the need to depend on "hamcrest-all" when using Hamcrest 1.1 and also maintains backward compatibility with Hamcrest 1.1 (also embedded in JUnit 4.4 through 4.8).- 从以下版本开始:
- 3.2
- 作者:
- Rossen Stoyanchev, Sam Brannen
构造器概要
构造器 构造器 说明 MatcherAssertionErrors()
已过时。
方法概要
所有方法 静态方法 具体方法 已过时的方法 修饰符和类型 方法 说明 static <T> void
assertThat(String reason, T actual, Matcher<T> matcher)
已过时。Assert that the given matcher matches the actual value.static <T> void
assertThat(T actual, Matcher<T> matcher)
已过时。Assert that the given matcher matches the actual value.
构造器详细资料
MatcherAssertionErrors
public MatcherAssertionErrors()
已过时。
方法详细资料
assertThat
public static <T> void assertThat(T actual, Matcher<T> matcher)
已过时。Assert that the given matcher matches the actual value.- 类型参数:
T
- the static type accepted by the matcher- 参数:
actual
- the value to match againstmatcher
- the matcher
assertThat
public static <T> void assertThat(String reason, T actual, Matcher<T> matcher)
已过时。Assert that the given matcher matches the actual value.- 类型参数:
T
- the static type accepted by the matcher- 参数:
reason
- additional information about the erroractual
- the value to match againstmatcher
- the matcher