fix venv prepare
Prod-related: PROD-26374 (PROD:26374)
Change-Id: I84f19bfce84a90f3fd064a6f382c2f75f41b786f
diff --git a/test-cookiecutter-reclass.groovy b/test-cookiecutter-reclass.groovy
index a670f87..3f8fa83 100644
--- a/test-cookiecutter-reclass.groovy
+++ b/test-cookiecutter-reclass.groovy
@@ -298,20 +298,16 @@
}
stage("Check workflow_definition") {
// Check only for patchset
- if (gerritDataCC.get('gerritRefSpec', null)) {
- if (fileExists(new File(templateEnvPatched, 'tox.ini').toString())) {
- dir(templateEnvPatched) {
- output = sh(returnStdout: true, script: "tox -ve test")
- common.infoMsg("[Cookiecutter test] Result: ${output}")
- }
-
- } else {
- common.warningMsg('Old Cookiecutter env detected!')
- python.setupVirtualenv(vEnv, 'python2', [], "${templateEnvPatched}/requirements.txt")
- common.infoMsg(python.runVirtualenvCommand(vEnv, "python ${templateEnvPatched}/workflow_definition_test.py"))
+ if (fileExists(new File(templateEnvPatched, 'tox.ini').toString())) {
+ dir(templateEnvPatched) {
+ output = sh(returnStdout: true, script: "tox -ve test")
+ common.infoMsg("[Cookiecutter test] Result: ${output}")
}
+
} else {
- common.infoMsg('No need to process: workflow_definition test')
+ common.warningMsg('Old Cookiecutter env detected!')
+ python.setupVirtualenv(vEnv, 'python2', [], "${templateEnvPatched}/requirements.txt")
+ common.infoMsg(python.runVirtualenvCommand(vEnv, "python ${templateEnvPatched}/workflow_definition_test.py"))
}
}