diff --git a/Regression/bz1788956-file-usr-include-maxminddb-config-h-from-install/main.fmf b/Regression/bz1788956-file-usr-include-maxminddb-config-h-from-install/main.fmf new file mode 100644 index 0000000..68e33ac --- /dev/null +++ b/Regression/bz1788956-file-usr-include-maxminddb-config-h-from-install/main.fmf @@ -0,0 +1,27 @@ +summary: Test for BZ#1788956 (file /usr/include/maxminddb_config.h from install) +description: | + Bug summary: file /usr/include/maxminddb_config.h from install of libmaxminddb-devel-1.2.0-6.el8.i686 conflicts with file from package libmaxminddb-devel-1.2.0-6.el8.x86_64 + Bugzilla link: https://bugzilla.redhat.com/show_bug.cgi?id=1788956 +component: +- libmaxminddb +test: ./runtest.sh +framework: beakerlib +recommend: +- libmaxminddb +duration: 5m +enabled: true +tag: +- NoRHEL4 +- NoRHEL5 +- NoRHEL6 +- TIPpass +- TIPpass_infra +- Tier1 +- rhel8-buildroot +tier: '1' +relevancy: | + distro = rhel-4, rhel-5, rhel-6: False + arch != x86_64: False +extra-nitrate: TC#0605880 +extra-summary: /CoreOS/libmaxminddb/Regression/bz1788956-file-usr-include-maxminddb-config-h-from-install +extra-task: /CoreOS/libmaxminddb/Regression/bz1788956-file-usr-include-maxminddb-config-h-from-install diff --git a/Regression/bz1788956-file-usr-include-maxminddb-config-h-from-install/runtest.sh b/Regression/bz1788956-file-usr-include-maxminddb-config-h-from-install/runtest.sh new file mode 100755 index 0000000..1f80d9e --- /dev/null +++ b/Regression/bz1788956-file-usr-include-maxminddb-config-h-from-install/runtest.sh @@ -0,0 +1,63 @@ +#!/bin/bash +# vim: dict+=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# runtest.sh of /CoreOS/libmaxminddb/Regression/bz1788956-file-usr-include-maxminddb-config-h-from-install +# Description: Test for BZ#1788956 (file /usr/include/maxminddb_config.h from install) +# Author: Karolina Zilkova +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# Copyright (c) 2020 Red Hat, Inc. +# +# This program is free software: you can redistribute it and/or +# modify it under the terms of the GNU General Public License as +# published by the Free Software Foundation, either version 2 of +# the License, or (at your option) any later version. +# +# This program is distributed in the hope that it will be +# useful, but WITHOUT ANY WARRANTY; without even the implied +# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR +# PURPOSE. See the GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program. If not, see http://www.gnu.org/licenses/. +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +# Include Beaker environment +. /usr/share/beakerlib/beakerlib.sh || exit 1 + +PACKAGE="libmaxminddb" + +rlJournalStart + rlPhaseStartSetup + rlAssertRpm $PACKAGE + rlRun "TmpDir=\$(mktemp -d)" 0 "Creating tmp directory" + rlRun "pushd $TmpDir" + rlPhaseEnd + + rlPhaseStartTest + if rpm -q libmaxminddb-devel | grep 'i686'; then + rlRun "yum -y reinstall libmaxminddb-devel.i686 &>out.txt" 0 "reinstalling i686 version" + else + rlRun "yum -y install libmaxminddb-devel.i686 &>out.txt" 0 "installing i686 version" + fi + cat out.txt + + if rpm -q libmaxminddb-devel | grep 'x86_64'; then + rlRun "yum -y reinstall libmaxminddb-devel.x86_64 &>out.txt" 0 "reinstalling x86_64 version" + else + rlRun "yum -y install libmaxminddb-devel.x86_64 &>out.txt" 0 "installing x86_64 version" + fi + cat out.txt + + rlRun "grep 'conflicts with file from package' out.txt" 1 "grep for error" + rlPhaseEnd + + rlPhaseStartCleanup + rlRun "popd" + rlRun "rm -r $TmpDir" 0 "Removing tmp directory" + rlPhaseEnd +rlJournalPrintText +rlJournalEnd