| |
@@ -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 <kzilkova@redhat.com>
|
| |
+ #
|
| |
+ # ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
| |
+ #
|
| |
+ # 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
|
| |
Add test and plan