From fe39691ca446d6d1c5dd049c9eaf2b9565d328ec Mon Sep 17 00:00:00 2001 From: Kaleemullah Siddiqui Date: Wed, 9 Jun 2021 18:57:46 +0530 Subject: [PATCH] Add gating definition for RHEL 9 Related: rhbz#1947473 Signed-off-by: Kaleemullah Siddiqui --- gating.yaml | 6 ++++++ tests/driver/runtest.sh | 26 ++++++++++++++++++++++++++ tests/tests.yml | 39 +++++++++++++++++++++++++++++++++++++++ 3 files changed, 71 insertions(+) create mode 100644 gating.yaml create mode 100644 tests/driver/runtest.sh create mode 100644 tests/tests.yml diff --git a/gating.yaml b/gating.yaml new file mode 100644 index 0000000..648918d --- /dev/null +++ b/gating.yaml @@ -0,0 +1,6 @@ +--- !Policy +product_versions: + - rhel-9 +decision_context: osci_compose_gate +rules: + - !PassingTestCaseRule {test_case_name: osci.brew-build.tier0.functional} diff --git a/tests/driver/runtest.sh b/tests/driver/runtest.sh new file mode 100644 index 0000000..f407201 --- /dev/null +++ b/tests/driver/runtest.sh @@ -0,0 +1,26 @@ +#!/bin/sh -ex + +# Weird location, but okay. +cd ../source + +# Generate Makefiles, directory layout, ... +autoreconf -fiv +./configure --with-glib --with-libevent --disable-dependency-tracking +make -sj + +# Avoid running `make check` here +cd tests +ls *.c | while read f; do + f="$(echo $f | awk -F. '{print $1}')" + make $f +done +cd .. + +# Overwrite the build. +cd src/.libs +cp /usr/lib64/libverto-glib.so.1.0.0 . +cp /usr/lib64/libverto-libevent.so.1.0.0 . +cd ../.. + +# Go time. +exec make check diff --git a/tests/tests.yml b/tests/tests.yml new file mode 100644 index 0000000..b1b3a0a --- /dev/null +++ b/tests/tests.yml @@ -0,0 +1,39 @@ +--- +- hosts: localhost + tags: classic + tasks: + - name: Brew a warm one + shell: dnf config-manager --add-repo 'http://download.eng.bos.redhat.com/brewroot/repos/rhel-9.0.0-build/latest/x86_64/' + args: + warn: false + +- hosts: localhost + tags: classic + tasks: + - name: Copy spec file to remote machine + copy: + src: "{{ playbook_dir }}/../libverto.spec" + dest: /tmp/libverto.spec + - name: Install build deps + shell: dnf -y --nogpgcheck build-dep /tmp/libverto.spec + args: + warn: false + +- hosts: localhost + roles: + - role: standard-test-source + tags: + - always + - role: standard-test-basic + tags: + - atomic + - classic + required_packages: + - libverto + - libverto-devel + - libverto-glib-devel + - libverto-libevent-devel + - make + - rpm-build + tests: + - driver