Junit4使用汇总(二)assertThat

1、assertThat方法 JUnit4 结合 Hamcrest 提供了一个全新的断言语法——assertThat。程序员能够只使用 assertThat 一个断言语句,结合 Hamcrest 提供的匹配符,就能够表达所有的测试思想。程序员 其基本语法为:数组 assertThat([message,] value, matcher-statement); 其中:app 第一个参数message
相关文章
相关标签/搜索