lundi 23 mars 2015

mvn clean install to execute Cucumber test and execute a jar file

I am working on running Cucumber tests through Maven "mvn clean install" command. One of my Cuke tests including executes a jar file through command line with the following command - "java -jar -Dprop1:value... ./jarLocation. This test is working correctly and passing locally in my IDE, but when I perform a "maven clean install", it fails to start the process and throws a Null Pointer exception on the line where I start the Process.. Would anybody have an idea as to how to get this Cuke test to execute jar file, working with Maven? Any suggestions would be very much helpful. Null Pointer exception occurs at the point in the code, where it is trying to start the jar process. It is not creating this Process object for me. NullPointerException occurs at : Process process = new ProcessBuilder(command).start();


Aucun commentaire:

Enregistrer un commentaire