MoienGK
MoienGK

Reputation: 4654

Failed to execute goal org.apache.maven.plugins:maven-failsafe-plugin:2.12:verify (verify)

i am trying to build my webapps workspace with the help of springfuse(JavaEE 6 + Spring Framework (targeting Jetty, Tomcat, JBoss, etc.)) and maven, so far i managed to create project using maven and import it into eclipse, but when i try to do maven-install i get few errors and finally a BUILD FAILURE notice. i have JDK 7u9 and eclipse juno and this is the error i get :

    Running ir.raysis.isirep.repository.UsersRepositoryIT
WARN  o.h.s.i.ConfigContext.getLuceneMatchVersion HSEARCH000075: Configuration setting hibernate.search.lucene_version was not specified, using LUCENE_CURRENT.
WARN  i.r.i.d.IdentifiableHashBuilder.hash DEVELOPER: hashCode is not safe.If you encounter this message you should take the time to carefuly review the equals/hashCode methods for: ir.raysis.isirep.domain.Users You may consider using a business key.
Hibernate: 
    select
        nextval ('hibernate_sequence')
WARN  o.h.e.j.s.SqlExceptionHelper.logExceptions SQL Error: 90036, SQLState: 90036
ERROR o.h.e.j.s.SqlExceptionHelper.logExceptions Sequence "HIBERNATE_SEQUENCE" not found; SQL statement:
select nextval ('hibernate_sequence') [90036-171]
Tests run: 1, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 8.679 sec <<< FAILURE!
Running ir.raysis.isirep.util.IntegrationSampleIT
Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0 sec

Results :

Tests in error: 
  saveAndGet(ir.raysis.isirep.repository.UsersRepositoryIT): org.hibernate.exception.GenericJDBCException: could not extract ResultSet

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

[INFO] 
[INFO] --- jetty-maven-plugin:8.1.10.v20130312:stop (stop-jetty) @ isirep ---
[INFO] 
[INFO] --- maven-failsafe-plugin:2.12:verify (verify) @ isirep ---
[INFO] Failsafe report directory: /home/moien/isirep/target/failsafe-reports
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 58.147s
[INFO] Finished at: Mon Oct 07 17:25:11 IRST 2013
[INFO] Final Memory: 40M/369M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-failsafe-plugin:2.12:verify (verify) on project isirep: There are test failures.
[ERROR] 
[ERROR] Please refer to /home/moien/isirep/target/failsafe-reports for the individual test results.
[ERROR] -> [Help 1]
[ERROR] 
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.

any help on how to solve it will be appreciated. thank you

Upvotes: 0

Views: 7719

Answers (2)

Alexander Jeyaraj
Alexander Jeyaraj

Reputation: 833

The maven-failsafe-plugin executes when you run "mvn install/test/verify". If your objective is just to get the WAR file, which can be deployed to application server you can do one of the following.

  1. Run "mvn package", so the tests do not run.
  2. Run "mvn install -DskipTests=true". This will skip running the tests.

However, if this is a basic test that verifies your web application, you need to identify why the test is failing and fix it. You can try "mvnDebug", if you need to put a breakpoint to debug.

Upvotes: 3

Ralph
Ralph

Reputation: 120871

The build fail, because your test ( UsersRepositoryIT.saveAndGet ) fail.

Reason:

ERROR o.h.e.j.s.SqlExceptionHelper.logExceptions
   Sequence "HIBERNATE_SEQUENCE" not found; SQL statement:
   select nextval ('hibernate_sequence') [90036-171]

Upvotes: 1

Related Questions