运行使用DataflowAssert的Dataflow unittest时,我得到异常
java.lang.RuntimeException: DataflowAssert requires that JUnit and Hamcrest be linked in.
我需要将哪些依赖项添加到我的pom文件中才能修复此异常?
答案 0 :(得分:2)
将以下依赖项添加到您的pom文件以链接到所需的库
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>4.11</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.hamcrest</groupId>
<artifactId>hamcrest-all</artifactId>
<version>1.3</version>
<scope>test</scope>
</dependency>