Gauge Specs execution failed. java.io.IOException: Cannot run program "gauge": error=2, No such file or directory
attilaturkkan opened this issue · 1 comments
Hi everyone,
I have a very simple Java + Maven + Gauge project. I just want to run simple test cases via local Jenkins. When I run my Jenkins job that I see this message:
Started by user admin
Running as SYSTEM
Building in workspace /Users/zed/.jenkins/workspace/gauge-devops
[WS-CLEANUP] Deleting project workspace...
[WS-CLEANUP] Deferred wipeout is used...
[WS-CLEANUP] Done
The recommended git tool is: NONE
using credential 2f2b8ecf-f7b6-4802-a20d-04b0b1301e6d
Cloning the remote Git repository
Cloning repository https://github.com/attilaturkkan/devops
git init /Users/zed/.jenkins/workspace/gauge-devops # timeout=10
Fetching upstream changes from https://github.com/attilaturkkan/devops
git --version # timeout=10
git --version # 'git version 2.24.3 (Apple Git-128)'
using GIT_ASKPASS to set credentials
git fetch --tags --force --progress -- https://github.com/attilaturkkan/devops +refs/heads/:refs/remotes/origin/ # timeout=10
git config remote.origin.url https://github.com/attilaturkkan/devops # timeout=10
git config --add remote.origin.fetch +refs/heads/:refs/remotes/origin/ # timeout=10
Avoid second fetch
git rev-parse refs/remotes/origin/master^{commit} # timeout=10
git rev-parse refs/remotes/origin/origin/master^{commit} # timeout=10
Checking out Revision a72555692ae2fff3eacc0abbde69f882108b460a (refs/remotes/origin/master)
git config core.sparsecheckout # timeout=10
git checkout -f a72555692ae2fff3eacc0abbde69f882108b460a # timeout=10
Commit message: "senaryolar türkçe karakter problemi çözüldü."
git rev-list --no-walk a72555692ae2fff3eacc0abbde69f882108b460a # timeout=10
[gauge-devops] $ /Users/zed/.jenkins/tools/hudson.tasks.Maven_MavenInstallation/maven_3.6.3/bin/mvn clean install
[INFO] Scanning for projects...
[INFO]
[INFO] ---------------------< org.example:DevOpsProject >----------------------
[INFO] Building DevOpsProject 1.0-SNAPSHOT
[INFO] --------------------------------[ jar ]---------------------------------
[INFO]
[INFO] --- maven-clean-plugin:2.5:clean (default-clean) @ DevOpsProject ---
[INFO]
[INFO] --- maven-resources-plugin:2.6:resources (default-resources) @ DevOpsProject ---
[WARNING] Using platform encoding (UTF-8 actually) to copy filtered resources, i.e. build is platform dependent!
[INFO] Copying 1 resource
[INFO]
[INFO] --- maven-compiler-plugin:3.8.1:compile (default-compile) @ DevOpsProject ---
[INFO] No sources to compile
[INFO]
[INFO] --- maven-resources-plugin:2.6:testResources (default-testResources) @ DevOpsProject ---
[WARNING] Using platform encoding (UTF-8 actually) to copy filtered resources, i.e. build is platform dependent!
[INFO] skip non existing resourceDirectory /Users/zed/.jenkins/workspace/gauge-devops/src/test/resources
[INFO]
[INFO] --- maven-compiler-plugin:3.8.1:testCompile (default-testCompile) @ DevOpsProject ---
[INFO] Changes detected - recompiling the module!
[WARNING] File encoding has not been set, using platform encoding UTF-8, i.e. build is platform dependent!
[INFO] Compiling 1 source file to /Users/zed/.jenkins/workspace/gauge-devops/target/test-classes
[INFO]
[INFO] --- maven-surefire-plugin:2.12.4:test (default-test) @ DevOpsProject ---
[INFO]
[INFO] --- maven-jar-plugin:2.4:jar (default-jar) @ DevOpsProject ---
[INFO] Building jar: /Users/zed/.jenkins/workspace/gauge-devops/target/DevOpsProject-1.0-SNAPSHOT.jar
[INFO]
[INFO] --- maven-install-plugin:2.4:install (default-install) @ DevOpsProject ---
[INFO] Installing /Users/zed/.jenkins/workspace/gauge-devops/target/DevOpsProject-1.0-SNAPSHOT.jar to /Users/zed/.m2/repository/org/example/DevOpsProject/1.0-SNAPSHOT/DevOpsProject-1.0-SNAPSHOT.jar
[INFO] Installing /Users/zed/.jenkins/workspace/gauge-devops/pom.xml to /Users/zed/.m2/repository/org/example/DevOpsProject/1.0-SNAPSHOT/DevOpsProject-1.0-SNAPSHOT.pom
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 2.983 s
[INFO] Finished at: 2020-10-03T20:34:57+03:00
[INFO] ------------------------------------------------------------------------
[gauge-devops] $ /Users/zed/.jenkins/tools/hudson.tasks.Maven_MavenInstallation/maven_3.6.3/bin/mvn gauge:execute -DspecsDir=specs -DinParallel=true -Dtags=arama
[INFO] Scanning for projects...
[INFO]
[INFO] ---------------------< org.example:DevOpsProject >----------------------
[INFO] Building DevOpsProject 1.0-SNAPSHOT
[INFO] --------------------------------[ jar ]---------------------------------
[INFO]
[INFO] --- gauge-maven-plugin:1.4.3:execute (default-cli) @ DevOpsProject ---
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 0.584 s
[INFO] Finished at: 2020-10-03T20:34:59+03:00
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal com.thoughtworks.gauge.maven:gauge-maven-plugin:1.4.3:execute (default-cli) on project DevOpsProject: Gauge Specs execution failed. java.io.IOException: Cannot run program "gauge": error=2, No such file or directory -> [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.
[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
Build step 'Invoke top-level Maven targets' marked build as failure
Finished: FAILURE
When I run same command (mvn gauge:execute -DspecsDir=specs -DinParallel=true -Dtags="arama"
) on my local project directory via terminal everything is ok.
gauge -v
Gauge version: 1.1.1
Plugins
html-report (4.0.12)
java (0.7.10)
js (2.3.12)
screenshot (0.0.1)
mvn -v
Apache Maven 3.6.3 (cecedd343002696d0abb50b32b541b8a6ba2883f)
Operating System: macOS Catalina 10.15.6