Add gating tests

Based on RHEL 8 gating tests.

Resolves: rhbz#2029986
This commit is contained in:
Martin Kolman 2021-12-09 18:21:30 +01:00
parent 4773d9f23c
commit 44c8f3c514
5 changed files with 104 additions and 0 deletions

6
gating.yaml Normal file
View File

@ -0,0 +1,6 @@
--- !Policy
product_versions:
- rhel-9
decision_context: osci_compose_gate
rules:
- !PassingTestCaseRule {test_case_name: osci.brew-build.tier0.functional}

52
tests/branding/Makefile Normal file
View File

@ -0,0 +1,52 @@
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
#
# Makefile of /anaconda-user-help.git/branding
# Description: Anaconda user help branding test
# Author: Peter Kotvan <pkotvan@redhat.com>
#
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
#
# Copyright (c) 2019 Red Hat, Inc.
#
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
export TEST=/anaconda-user-help.git/branding
export TESTVERSION=1.0
BUILT_FILES=
FILES=$(METADATA) runtest.sh Makefile PURPOSE
.PHONY: all install download clean
run: $(FILES) build
./runtest.sh
build: $(BUILT_FILES)
test -x runtest.sh || chmod a+x runtest.sh
clean:
rm -f *~ $(BUILT_FILES)
include /usr/share/rhts/lib/rhts-make.include
$(METADATA): Makefile
@echo "Owner: Peter Kotvan <pkotvan@redhat.com>" > $(METADATA)
@echo "Name: $(TEST)" >> $(METADATA)
@echo "TestVersion: $(TESTVERSION)" >> $(METADATA)
@echo "Path: $(TEST_DIR)" >> $(METADATA)
@echo "Description: Anaconda user help branding test" >> $(METADATA)
@echo "Type: Install" >> $(METADATA)
@echo "TestTime: 20m" >> $(METADATA)
@echo "Priority: Normal" >> $(METADATA)
@echo "License: GPLv3" >> $(METADATA)
@echo "Confidential: no" >> $(METADATA)
@echo "Destructive: no" >> $(METADATA)
# @echo "Releases: -RHEL4 -RHELClient5 -RHELServer5" >> $(METADATA)
# RhtsRequires:
@echo "RhtsRequires: beakerlib" >> $(METADATA)
# Requires:
# @echo "Requires: some-pkg" >> $(METADATA)
rhts-lint $(METADATA)

3
tests/branding/PURPOSE Normal file
View File

@ -0,0 +1,3 @@
PURPOSE of /anaconda-user-help.git/branding
Description: Anaconda user help branding test
Author: Peter Kotvan <pkotvan@redhat.com>

35
tests/branding/runtest.sh Executable file
View File

@ -0,0 +1,35 @@
#!/bin/bash
# vim: dict+=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
#
# runtest.sh of /anaconda-user-help.git/branding
# Description: Anaconda user help branding test
# Author: Peter Kotvan <pkotvan@redhat.com>
#
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
#
# Copyright (c) 2019 Red Hat, Inc.
#
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# Include Beaker environment
. /usr/bin/rhts-environment.sh || exit 1
. /usr/share/beakerlib/beakerlib.sh || exit 1
rlJournalStart
# rlPhaseStartSetup
# rlPhaseEnd
rlPhaseStartTest
rlLog "Verify whether anaconda user help contains the string fedora."
rlRun -s "rpm -ql anaconda-user-help | xargs grep -irq fedora" 123
if [[ $? -ne 123 ]]
then
rlFileSubmit ${rlRun_LOG} "fedora_string.log"
fi
rlPhaseEnd
# rlPhaseStartCleanup
# rlPhaseEnd
rlJournalPrintText
rlJournalEnd

8
tests/tests.yml Normal file
View File

@ -0,0 +1,8 @@
---
- hosts: all
roles:
- role: standard-test-beakerlib
tags:
- classic
tests:
- branding