From 58ae0ac1972030942614963b1dafebe66b24cd8b Mon Sep 17 00:00:00 2001 From: Nikita Gryzlov Date: Mon, 19 Oct 2020 15:48:58 +0300 Subject: [PATCH] =?UTF-8?q?=D0=A1=D0=BE=D1=85=D1=80=D0=B0=D0=BD=D0=B5?= =?UTF-8?q?=D0=BD=D0=B8=D0=B5=20=D1=80=D0=B5=D0=B7=D1=83=D0=BB=D1=8C=D1=82?= =?UTF-8?q?=D0=B0=D1=82=D0=BE=D0=B2=20=D0=B0=D0=BB=D0=BB=D1=8E=D1=80=D0=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/ru/pulsar/jenkins/library/IStepExecutor.groovy | 4 ++++ src/ru/pulsar/jenkins/library/StepExecutor.groovy | 9 +++++++-- src/ru/pulsar/jenkins/library/steps/InitInfobase.groovy | 3 +++ 3 files changed, 14 insertions(+), 2 deletions(-) diff --git a/src/ru/pulsar/jenkins/library/IStepExecutor.groovy b/src/ru/pulsar/jenkins/library/IStepExecutor.groovy index a7b76c2..3691b78 100644 --- a/src/ru/pulsar/jenkins/library/IStepExecutor.groovy +++ b/src/ru/pulsar/jenkins/library/IStepExecutor.groovy @@ -34,6 +34,8 @@ interface IStepExecutor { def stash(String name, String includes) + def stash(String name, String includes, boolean allowEmpty) + def unstash(String name) def zip(String dir, String zipFile) @@ -49,4 +51,6 @@ interface IStepExecutor { def httpRequest(String url, String outputFile) def httpRequest(String url, String outputFile, String responseHandle, boolean wrapAsMultipart) + + def error(String errorMessage) } \ No newline at end of file diff --git a/src/ru/pulsar/jenkins/library/StepExecutor.groovy b/src/ru/pulsar/jenkins/library/StepExecutor.groovy index f784971..17a7aca 100644 --- a/src/ru/pulsar/jenkins/library/StepExecutor.groovy +++ b/src/ru/pulsar/jenkins/library/StepExecutor.groovy @@ -80,8 +80,8 @@ class StepExecutor implements IStepExecutor { } @Override - def stash(String name, String includes) { - steps.stash name: name, includes: includes + def stash(String name, String includes, boolean allowEmpty = false) { + steps.stash name: name, includes: includes, allowEmpty: allowEmpty } @Override @@ -108,4 +108,9 @@ class StepExecutor implements IStepExecutor { def httpRequest(String url, String outputFile, String responseHandle = 'NONE', boolean wrapAsMultipart = false) { steps.httpRequest responseHandle: responseHandle, outputFile: outputFile, url: url, wrapAsMultipart: wrapAsMultipart } + + @Override + def error(String errorMessage) { + steps.error errorMessage + } } diff --git a/src/ru/pulsar/jenkins/library/steps/InitInfobase.groovy b/src/ru/pulsar/jenkins/library/steps/InitInfobase.groovy index 87727c5..0dabc30 100644 --- a/src/ru/pulsar/jenkins/library/steps/InitInfobase.groovy +++ b/src/ru/pulsar/jenkins/library/steps/InitInfobase.groovy @@ -44,5 +44,8 @@ class InitInfobase implements Serializable { Logger.println("Первичная инициализация командой ${it}") steps.cmd("oscript_modules/bin/vrunner ${it} --ibconnection \"/F./build/ib\"") } + + steps.stash('init-allure', 'build/out/allure/*', true) + steps.stash('init-cucumber', 'build/out/cucumber/*', true) } }