We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Currently the closure in the withEnv mock is called multiple times (same number as env params)
c.delegate = binding c.call()
should be moved outside the loop that adds the env vars, like so
helper.registerAllowedMethod('withEnv', [List, Closure], { List list, Closure c -> list.each { //def env = helper.get def item = it.split('=') assert item.size() == 2, "withEnv list does not look right: ${list.toString()}" addEnvVar(item[0], item[1]) } c.delegate = binding c.call() })
The text was updated successfully, but these errors were encountered:
@bogdanmuresan You are right. Would you like to submit a PR?
Sorry, something went wrong.
Issue jenkinsci#199 - fix withEnv closure call
57d5082
PR opened here: #205
Merge pull request #205 from bogdanmuresan/fix_witEnv_closure_call
ccbc02e
Issue #199 - fix withEnv closure call
No branches or pull requests
Currently the closure in the withEnv mock is called multiple times (same number as env params)
should be moved outside the loop that adds the env vars, like so
The text was updated successfully, but these errors were encountered: