2017-05-02 9 views
0

私は最近、フロントエンドテストプロジェクトを引き継ぎました。私がNBでそれを実行するとき、目標は実行されません。 Eclipseで問題なく実行します。 ファイルを手動で選択することができます。**/WorkflowStories.javaをクリックし、テストを実行します。その後、それが実行されます..しかし、私はプロジェクトをクリックし、ビルドまたはテストを実行する...等...それはちょうど目標を実行するつもりはない...pom.xmlの目標はEclipseでは実行されますが、Netbeansでは実行されません

誰も私のための検索を開始する理由はありますか?目標は実行されません...または目標が実行される必要がある場所が不足していますか?ここで

はのpom.xmlです:

<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
     xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> 
    <modelVersion>4.0.0</modelVersion> 

    <groupId>at.dig</groupId> 
    <artifactId>eprocure.test</artifactId> 
    <version>1.0.0</version> 
    <packaging>jar</packaging> 

    <name>eprocure.test</name> 
    <url>http://maven.apache.org</url> 

    <properties> 
     <additionalparam>-Xdoclint:none</additionalparam> 
     <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding> 
     <includepath>**/WorkflowStories.java</includepath> 
    </properties> 

    <dependencies> 
     <dependency> 
      <groupId>junit</groupId> 
      <artifactId>junit</artifactId> 
      <version>4.11</version> 
      <scope>test</scope> 
     </dependency> 
     <dependency> 
      <groupId>junit</groupId> 
      <artifactId>junit-dep</artifactId> 
      <version>4.8.2</version> 
     </dependency> 
     <dependency> 
      <groupId>org.jbehave</groupId> 
      <artifactId>jbehave-core</artifactId> 
      <version>4.0.4</version> 
      <exclusions> 
       <exclusion> 
        <groupId>junit</groupId> 
        <artifactId>junit</artifactId> 
       </exclusion> 
       <exclusion> 
        <groupId>commons-collections</groupId> 
        <artifactId>commons-collections</artifactId> 
       </exclusion> 
      </exclusions> 
     </dependency> 
     <dependency> 
      <groupId>org.jbehave.web</groupId> 
      <artifactId>jbehave-web-selenium</artifactId> 
      <version>3.5.5</version> 
     </dependency> 
     <dependency> 
      <groupId>org.jbehave</groupId> 
      <artifactId>jbehave-gherkin</artifactId> 
      <version>4.0.4</version> 
     </dependency> 
     <dependency> 
      <groupId>de.codecentric</groupId> 
      <artifactId>jbehave-junit-runner</artifactId> 
      <version>1.2.0</version> 
     </dependency> 
     <dependency> 
      <groupId>org.seleniumhq.selenium</groupId> 
      <artifactId>selenium-java</artifactId> 
      <version>2.53.1</version> 
     </dependency> 
     <dependency> 
      <groupId>org.seleniumhq.selenium</groupId> 
      <artifactId>selenium-server</artifactId> 
      <version>2.53.1</version> 
     </dependency> 
     <dependency> 
      <groupId>org.seleniumhq.selenium</groupId> 
      <artifactId>htmlunit-driver</artifactId> 
      <version>2.21</version> 
     </dependency> 
     <dependency> 
      <groupId>log4j</groupId> 
      <artifactId>log4j</artifactId> 
      <version>1.2.17</version> 
     </dependency> 
     <dependency> 
      <groupId>org.jvnet.jaxb2_commons</groupId> 
      <artifactId>jaxb2-basics-runtime</artifactId> 
      <version>0.9.3</version> 
     </dependency> 
     <dependency> 
      <groupId>mysql</groupId> 
      <artifactId>mysql-connector-java</artifactId> 
      <version>5.1.34</version> 
     </dependency> 
     <dependency> 
      <groupId>commons-net</groupId> 
      <artifactId>commons-net</artifactId> 
      <version>3.3</version> 
     </dependency> 
     <!--dependency> <groupId>org.jbehave</groupId> <artifactId>jbehave-guice</artifactId> 
     <version>3.9.5</version> </dependency> <dependency> <groupId>org.jbehave</groupId> 
     <artifactId>jbehave-guice-archetype</artifactId> <version>3.9.5</version> 
     </dependency> <dependency> <groupId>com.carlosbecker</groupId> <artifactId>guice-junit-test-runner</artifactId> 
     <version>1.1</version> <scope>test</scope> </dependency --> 
     <dependency> 
      <groupId>org.picocontainer</groupId> 
      <artifactId>picocontainer</artifactId> 
      <version>2.15</version> 
     </dependency> 
     <dependency> 
      <groupId>org.jbehave</groupId> 
      <artifactId>jbehave-pico</artifactId> 
      <version>3.9.5</version> 
     </dependency> 
     <dependency> 
      <groupId>org.slf4j</groupId> 
      <artifactId>slf4j-simple</artifactId> 
      <version>1.6.1</version> 
     </dependency> 
     <dependency> 
      <groupId>javax.mail</groupId> 
      <artifactId>mail</artifactId> 
      <version>1.4</version> 
     </dependency> 
     <dependency> 
      <groupId>org.json</groupId> 
      <artifactId>json</artifactId> 
      <version>20160212</version> 
     </dependency> 
     <dependency> 
      <groupId>commons-collections</groupId> 
      <artifactId>commons-collections</artifactId> 
      <version>3.2.2</version> 
     </dependency> 
    </dependencies> 
    <build> 
     <testResources> 
      <testResource> 
       <directory>src/test/resources</directory> 
      </testResource> 
     </testResources> 
     <plugins> 
      <plugin> 
       <groupId>org.jbehave</groupId> 
       <artifactId>jbehave-maven-plugin</artifactId> 
       <version>4.0.4</version> 
       <executions> 
        <execution> 
         <id>run-stories-as-embeddables</id> 
         <phase>integration-test</phase> 
         <configuration> 
          <scope>test</scope> 
          <storyTimeoutInSecs>2000</storyTimeoutInSecs> 
          <includes> 
           <include>${includepath}</include> 
          </includes> 
         </configuration> 
         <goals> 
          <goal>run-stories-as-embeddables</goal> 
         </goals> 
        </execution> 
       </executions> 
       <dependencies> 
        <dependency> 
         <groupId>log4j</groupId> 
         <artifactId>log4j</artifactId> 
         <version>1.2.16</version> 
        </dependency> 
       </dependencies> 
      </plugin> 
     </plugins> 
    </build> 
</project> 

私はこのエラーを取得する任意の構成で実行してセレンのテストをクリックすると:

Forking command line: cmd.exe /X /C ""C:\Program Files\Java\jdk1.8.0_77\jre\bin\java" -jar C:\dev\eprocure\tests\eprocure.test\target\surefire\surefirebooter2755771664797425151.jar C:\dev\eprocure\tests\eprocure.test\target\surefire\surefire585909871144772322tmp C:\dev\eprocure\tests\eprocure.test\target\surefire\surefire3369166164771177265tmp" 

Results : 

Tests run: 0, Failures: 0, Errors: 0, Skipped: 0 

[INFO] ------------------------------------------------------------------------ 
[INFO] BUILD FAILURE 
[INFO] ------------------------------------------------------------------------ 
[INFO] Total time: 5.476s 
[INFO] Finished at: Tue May 02 11:12:30 CEST 2017 
[INFO] Final Memory: 10M/158M 
[INFO] ------------------------------------------------------------------------ 
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.10:test (default-cli) on project eprocure.test: No tests were executed! (Set -DfailIfNoTests=false to ignore this error.) -> [Help 1] 
org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.10:test (default-cli) on project eprocure.test: No tests were executed! (Set -DfailIfNoTests=false to ignore this error.) 
    at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:213) 
    at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:153) 
    at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:145) 
    at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:84) 
    at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:59) 
    at org.apache.maven.lifecycle.internal.LifecycleStarter.singleThreadedBuild(LifecycleStarter.java:183) 
    at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:161) 
    at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:320) 
    at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:156) 
    at org.apache.maven.cli.MavenCli.execute(MavenCli.java:537) 
    at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:196) 
    at org.apache.maven.cli.MavenCli.main(MavenCli.java:141) 
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) 
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) 
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) 
    at java.lang.reflect.Method.invoke(Method.java:498) 
    at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:290) 
    at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:230) 
    at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:409) 
    at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:352) 
Caused by: org.apache.maven.plugin.MojoFailureException: No tests were executed! (Set -DfailIfNoTests=false to ignore this error.) 
    at org.apache.maven.plugin.surefire.SurefireHelper.reportExecution(SurefireHelper.java:60) 
    at org.apache.maven.plugin.surefire.SurefirePlugin.writeSummary(SurefirePlugin.java:641) 
    at org.apache.maven.plugin.surefire.SurefirePlugin.handleSummary(SurefirePlugin.java:615) 
    at org.apache.maven.plugin.surefire.AbstractSurefireMojo.executeAfterPreconditionsChecked(AbstractSurefireMojo.java:137) 
    at org.apache.maven.plugin.surefire.AbstractSurefireMojo.execute(AbstractSurefireMojo.java:98) 
    at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:101) 
    at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:209) 
    ... 19 more 
[ERROR] 
[ERROR] 
[ERROR] For more information about the errors and possible solutions, please read the following articles: 
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException 

答えて

0

問題は、EclipseとNBは、との目標を実行することです異なるフラグセット。純粋なコマンドラインからの実行目標はあなたを助けるかもしれません。

関連する問題