@ RunWithタグと@CucumberOptionsタグを使用してCucumber-JVMテストを実行できましたが、Mavenを使用してテストを実行できません。誰かが私を正しい方向に向けることができますか?
インターネットを精査した後、maven sure fireプラグインを使用しようとしています。間違いを犯していると思いますが、それは私にはわかりません。
ディレクトリ構造は次のとおりです。
src\test\
--config\
--resources\ (has the .feature files)
--steps\ (classes for the steps)
=================== MavenPOMファイル=======================
http://maven.apache.org/maven-v4_0_0.xsd ">
<modelVersion>4.0.0</modelVersion>
<groupId>Project</groupId>
<artifactId>Project</artifactId>
<version>1.0-SNAPSHOT</version>
<properties>
<cucumber.options>--format pretty</cucumber.options>
<testsrc>src/test/</testsrc>
</properties>
<dependencies>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>4.12</version>
</dependency>
<dependency>
<groupId>info.cukes</groupId>
<artifactId>cucumber-java</artifactId>
<version>1.2.0</version>
</dependency>
<dependency>
<groupId>info.cukes</groupId>
<artifactId>cucumber-junit</artifactId>
<version>1.2.0</version>
</dependency>
<dependency>
<groupId>info.cukes</groupId>
<artifactId>cucumber-core</artifactId>
<version>1.2.0</version>
</dependency>
<dependency> <!-- External Dependency -->
<groupId>ojdbc6</groupId>
<artifactId>ojdbc6</artifactId>
<scope>system</scope>
<version>1.0</version>
<systemPath>E:\work\test\Project\libs\ojdbc6dms.jar</systemPath>
</dependency>
<dependency> <!-- External Dependency -->
<groupId>sqljdbc</groupId>
<artifactId>ojdbc6</artifactId>
<scope>system</scope>
<version>1.0</version>
<systemPath>E:\work\test\Project\libs\sqljdbc4.jar</systemPath>
</dependency>
</dependencies>
<build>
<testSourceDirectory>${testsrc}</testSourceDirectory>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<version>2.18.1</version>
<configuration>
<parallel>classes</parallel>
<threadCount>1</threadCount>
<includes>
<include>**/RunCukeTests.java</include>
</includes>
</configuration>
</plugin>
</plugins>
</build>
この記事はインターネットから収集されたものであり、転載の際にはソースを示してください。
侵害の場合は、連絡してください[email protected]
コメントを追加