You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
gradle clean build
> Task :test
tests.job.JenkinsfileTestSpec > Jenkinsfile should run gradle tests with expected command line validate:null gradle: null FAILED
groovy.util.ResourceException at JenkinsfileTestSpec.groovy:26
Caused by: groovy.util.ResourceException at JenkinsfileTestSpec.groovy:26
Then I thought perhaps there is another jenkins file. This was the case, i.e. ./exampleJobs/parallel/Jenkinsfile and when this was renamed the issue persisted.
Should all Jenkins. entries that reside in the test files be renamed as well?
The text was updated successfully, but these errors were encountered:
If you rename the Jenkinsfile at the top level say to something like "Foo.groovy" you will need to look for the lines in the tests like "runScript('Jenkinsfile')" and change to "runScript('Foo.groovy')". Also, for tests that assert the pipeline call stacks to a file using 'testNonRegression', the content of all these call stack files will need updating for lines like 'Jenkinsfile.pipeline(groovy.lang.Closure)' which would become 'Foo.pipeline(groovy.lang.Closure)' (these are the files under 'tests/callstacks'. You don't need to update these call stack files manually though, you can go into the gradle.properties file and set 'pipeline.stack.write=true' then run all the tests and review the changes. Does this answer it?
When Jenkinsfile was renamed, e.g. x.jenkins and the path in the test as well, the gradle build fails:
when cloned:
when Jenkinsfile renamed
Then I thought perhaps there is another jenkins file. This was the case, i.e. ./exampleJobs/parallel/Jenkinsfile and when this was renamed the issue persisted.
Should all Jenkins. entries that reside in the test files be renamed as well?
The text was updated successfully, but these errors were encountered: