0

DataflowAssert を使用する Dataflow unittest を実行すると、例外が発生します

java.lang.RuntimeException: DataflowAssert requires that JUnit and Hamcrest be linked in.

この例外を修正するには、pom ファイルにどのような依存関係を追加する必要がありますか?

4

1 に答える 1

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>  
于 2015-01-25T18:17:45.837 に答える