java - Maven not running Test -


i created new maven project in eclipse runs simple test using both htmlunitdriver , firefoxdriver pull web page , check title on page. when run maven command mvn test get:

[info] scanning projects... [info]                                                                          [info] ------------------------------------------------------------------------ [info] building my-app 1.0-snapshot [info] ------------------------------------------------------------------------ [info]  [info] --- maven-resources-plugin:2.6:resources (default-resources) @ my-app --- [warning] using platform encoding (macroman actually) copy filtered resources, i.e. build platform dependent! [info] skip non existing resourcedirectory /users/andrew/development/code/my-app/src/main/resources [info]  [info] --- maven-compiler-plugin:2.5.1:compile (default-compile) @ my-app --- [info] nothing compile - classes date [info]  [info] --- maven-resources-plugin:2.6:testresources (default-testresources) @ my-app --- [warning] using platform encoding (macroman actually) copy filtered resources, i.e. build platform dependent! [info] skip non existing resourcedirectory /users/andrew/development/code/my-app/src/test/resources [info]  [info] --- maven-compiler-plugin:2.5.1:testcompile (default-testcompile) @ my-app --- [warning] file encoding has not been set, using platform encoding macroman, i.e. build platform dependent! [info] compiling 1 source file /users/andrew/development/code/my-app/target/test-classes [info]  [info] --- maven-surefire-plugin:2.12.4:test (default-test) @ my-app --- [info] ------------------------------------------------------------------------ [info] build success [info] ------------------------------------------------------------------------ [info] total time: 3.049s [info] finished at: fri jan 31 11:53:38 est 2014 [info] final memory: 12m/81m [info] ------------------------------------------------------------------------ 

when run same maven command in eclipse, shows following:

slf4j: failed load class "org.slf4j.impl.staticloggerbinder". slf4j: defaulting no-operation (nop) logger implementation slf4j: see http://www.slf4j.org/codes.html#staticloggerbinder further details. [info] scanning projects... [info]                                                                          [info] ------------------------------------------------------------------------ [info] building my-app 1.0-snapshot [info] ------------------------------------------------------------------------ [info]  [info] --- maven-resources-plugin:2.5:resources (default-resources) @ my-app --- [debug] execute contextualize [warning] using platform encoding (macroman actually) copy filtered resources, i.e. build platform dependent! [info] skip non existing resourcedirectory /users/andrew/development/code/my-app/src/main/resources [info]  [info] --- maven-compiler-plugin:2.3.2:compile (default-compile) @ my-app --- [info] nothing compile - classes date [info]  [info] --- maven-resources-plugin:2.5:testresources (default-testresources) @ my-app --- [debug] execute contextualize [warning] using platform encoding (macroman actually) copy filtered resources, i.e. build platform dependent! [info] skip non existing resourcedirectory /users/andrew/development/code/my-app/src/test/resources [info]  [info] --- maven-compiler-plugin:2.3.2:testcompile (default-testcompile) @ my-app --- [info] nothing compile - classes date [info]  [info] --- maven-surefire-plugin:2.10:test (default-test) @ my-app --- [info] surefire report directory: /users/andrew/development/code/my-app/target/surefire-reports  -------------------------------------------------------  t e s t s -------------------------------------------------------  results :  tests run: 0, failures: 0, errors: 0, skipped: 0  [info] ------------------------------------------------------------------------ [info] build success [info] ------------------------------------------------------------------------ [info] total time: 3.878s [info] finished at: fri jan 31 11:58:23 est 2014 [info] final memory: 5m/81m [info] ------------------------------------------------------------------------ 

this pom.xml want check if may issue:

<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/maven-v4_0_0.xsd">   <modelversion>4.0.0</modelversion>   <groupid>com.mycompany.app</groupid>   <artifactid>my-app</artifactid>   <packaging>jar</packaging>   <version>1.0-snapshot</version>   <name>my-app</name>   <url>http://maven.apache.org</url>   <dependencies>     <dependency>       <groupid>junit</groupid>       <artifactid>junit</artifactid>       <version>4.11</version>       <scope>test</scope>     </dependency>     <dependency>       <groupid>org.seleniumhq.selenium</groupid>       <artifactid>selenium-java</artifactid>       <version>2.39.0</version>     </dependency>     <dependency>         <groupid>org.slf4j</groupid>         <artifactid>slf4j-api</artifactid>         <version>1.7.5</version>     </dependency>     <dependency>         <groupid>org.apache.maven.surefire</groupid>         <artifactid>surefire</artifactid>         <version>2.16</version>         <type>pom</type>      </dependency>    </dependencies> </project> 

did mean add org.apache.maven.surefire pom dependency under <dependencies>?

most usages of surefire plugin configured under <pluginmanagement> section:

<build>   <pluginmanagement>     <plugins>       <plugin>         <groupid>org.apache.maven.plugins</groupid>         <artifactid>maven-surefire-plugin</artifactid>         <version>2.16</version>       </plugin>     </plugins>   </pluginmanagement> </build> 

Comments

Popular posts from this blog

php - regexp cyrillic filename not matches -

c# - OpenXML hanging while writing elements -

sql - Select Query has unexpected multiple records (MS Access) -