[libvirt] [jenkins-ci PATCH 2/3] jobs: Use local_env for Perl test arguments

Andrea Bolognani posted 3 patches 7 years ago
[libvirt] [jenkins-ci PATCH 2/3] jobs: Use local_env for Perl test arguments
Posted by Andrea Bolognani 7 years ago
We're already using this approach for Go tests, the main
advantage being that we can use existing facilities instead
of defining custom one-use variables.

Signed-off-by: Andrea Bolognani <abologna@redhat.com>
---
 jobs/perl-makemaker.yaml   | 3 +--
 projects/libvirt-perl.yaml | 3 ++-
 2 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/jobs/perl-makemaker.yaml b/jobs/perl-makemaker.yaml
index 065b38e..491b7fa 100644
--- a/jobs/perl-makemaker.yaml
+++ b/jobs/perl-makemaker.yaml
@@ -58,7 +58,6 @@
     name: '{name}-{branch}-test{variant}'
     project-type: matrix
     description: '{title} Test'
-    test_args: ''
     workspace: '{name}-{branch}{variant}'
     child-workspace: '.'
     block-downstream: true
@@ -85,7 +84,7 @@
       - shell: |
           {global_env}
           {local_env}
-          $MAKE -j{smp} test {test_args}
+          $MAKE -j{smp} test $TEST_ARGS
     publishers:
       - email:
           recipients: '{obj:spam}'
diff --git a/projects/libvirt-perl.yaml b/projects/libvirt-perl.yaml
index 0a6f648..165470a 100644
--- a/projects/libvirt-perl.yaml
+++ b/projects/libvirt-perl.yaml
@@ -8,7 +8,8 @@
           parent_jobs: 'libvirt-master-build'
       - perl-makemaker-test-job:
           parent_jobs: 'libvirt-perl-master-build'
-          test_args: 'TEST_MAINTAINER=1'
+          local_env: |
+            export TEST_ARGS="TEST_MAINTAINER=1"
       - perl-makemaker-rpm-job:
           parent_jobs: 'libvirt-perl-master-test'
           machines: '{rpm_machines}'
-- 
2.17.0

--
libvir-list mailing list
libvir-list@redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list
Re: [libvirt] [jenkins-ci PATCH 2/3] jobs: Use local_env for Perl test arguments
Posted by Erik Skultety 6 years, 12 months ago
On Thu, May 10, 2018 at 05:35:44PM +0200, Andrea Bolognani wrote:
> We're already using this approach for Go tests, the main
> advantage being that we can use existing facilities instead
> of defining custom one-use variables.
>
> Signed-off-by: Andrea Bolognani <abologna@redhat.com>

Reviewed-by: Erik Skultety <eskultet@redhat.com>

--
libvir-list mailing list
libvir-list@redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list