From be787d9a84879fa60fb8d09a2ad1a3dd04d9d3e6 Mon Sep 17 00:00:00 2001 From: ginger Date: Nov 28 2021 21:25:26 +0000 Subject: Add check for sti tests --- diff --git a/playbooks/rpm/check-for-sti-tests.yaml b/playbooks/rpm/check-for-sti-tests.yaml new file mode 100644 index 0000000..2cef899 --- /dev/null +++ b/playbooks/rpm/check-for-sti-tests.yaml @@ -0,0 +1,18 @@ +--- +- hosts: localhost + tasks: + - name: Check for tests/tests.yml exists + stat: + path: "{{ ansible_user_dir }}/{{ zuul.project.src_dir }}/tests/tests.yml" + register: tests_stat + - zuul_return: + data: + zuul: + child_jobs: + - rpm-sti-test + when: tests_stat.stat.exists + - zuul_return: + data: + zuul: + child_jobs: [] + when: not tests_stat.stat.exists diff --git a/zuul.d/jobs.dhall b/zuul.d/jobs.dhall index 317c40c..43e9369 100644 --- a/zuul.d/jobs.dhall +++ b/zuul.d/jobs.dhall @@ -83,6 +83,15 @@ let check_for_tests = , nodeset = Some executor_nodeset } +let check_for_sti_tests = + Zuul.Job::{ + , name = "${job-prefix}check-for-sti-tests" + , description = Some "Check the project has a tests/tests.yml" + , branches = Some Branches.allText + , run = Some "playbooks/rpm/check-for-sti-tests.yaml" + , nodeset = Some executor_nodeset + } + let check_for_fmf_tests = Zuul.Job::{ , name = "${job-prefix}check-for-fmf-tests" @@ -300,6 +309,7 @@ let generateTMTTestsJobs = let Jobs = [ clean_stalled_koji_tasks , check_for_tests + , check_for_sti_tests , check_for_fmf_tests , check_for_arches , common_koji_rpm_build diff --git a/zuul.d/jobs.yaml b/zuul.d/jobs.yaml index 6142058..660dc0a 100644 --- a/zuul.d/jobs.yaml +++ b/zuul.d/jobs.yaml @@ -27,6 +27,20 @@ nodes: [] - job: + name: check-for-sti-tests + description: Check the project has a tests/tests.yml + run: playbooks/rpm/check-for-sti-tests.yaml + branches: + - rawhide + - f35 + - f34 + - f33 + - epel8 + - main + nodeset: + nodes: [] + +- job: name: check-for-fmf-tests description: Check the project has a .fmf directory run: playbooks/rpm/check-for-fmf-tests.yaml