Small edits in test scripts

This commit is contained in:
Vladis Dronov 2022-04-23 22:14:18 +02:00
parent 941b9f121f
commit aedde8ed3d
3 changed files with 17 additions and 9 deletions

View File

@ -1,5 +1,6 @@
%global _hardened_build 1
# this is a correct if, bcond_with actually means without and vice versa
%if 0%{?rhel} && 0%{?rhel} >= 9
%bcond_with pkcs11
%bcond_with rtlsdr
@ -44,7 +45,9 @@ Patch1: 2-rt-comment-out-have-aesni.patch
Patch2: 3-rt-fix-jent-define.patch
%description
Hardware random number generation tools.
This is a random number generator daemon and its tools. It monitors
a set of entropy sources present on a system (like /dev/hwrng, RDRAND,
TPM, jitter) and supplies entropy from them to a kernel entropy pool.
%prep
%autosetup -p0

View File

@ -31,7 +31,7 @@
. /usr/share/beakerlib/beakerlib.sh || exit 1
PACKAGE="rng-tools"
PACKAGES="rng-tools automake autoconf libsysfs-devel libxml2 libxml2-devel openssl-devel libcurl-devel"
PACKAGES="rng-tools gcc make binutils gettext automake autoconf jitterentropy-devel jansson-devel libcap-devel libxml2 libxml2-devel openssl-devel libcurl-devel libgcrypt-devel rtl-sdr-devel libp11-devel"
UPSTREAMPKG="rng-tools-*"
BUILDLOG=`mktemp`
TESTLOG=`mktemp`
@ -43,8 +43,8 @@ TESTDIR="$TOPDIR/BUILD/$UPSTREAMPKG/"
rlJournalStart
rlPhaseStartSetup
for PKG in $PACKAGES; do
rlAssertRpm $PKG
for PKG in $PACKAGES; do
rlAssertRpm $PKG
done
rlPhaseEnd
@ -57,19 +57,20 @@ rlJournalStart
echo "+ Buildlog:"
tail -n 100 $BUILDLOG
rlRun "pushd ."
rlRun "cd $TESTDIR"
rlRun "make check &> $TESTLOG"
rlRun "cd $TESTDIR"
rlRun "make check &> $TESTLOG"
if [ $? -eq 0 ]
then
rlPass "Selftest Passed"
else
rlFail "Selftest Failed"
fi
rlFileSubmit $TESTLOG
rlPhaseEnd
rlPhaseStartCleanup
rlRun "popd"
rlRun "rm -rf $PACKAGE*.src.rpm" 0 "Removing source rpm"
rlRun "popd"
rlRun "rm -rf $PACKAGE*.src.rpm" 0 "Removing source rpm"
rlPhaseEnd
rlJournalPrintText
rlJournalEnd

View File

@ -8,9 +8,13 @@
tests:
- selftest
required_packages:
- libsysfs-devel
- jitterentropy-devel
- jansson-devel
- libcap-devel
- libxml2
- libxml2-devel
- openssl-devel
- libcurl-devel
- libgcrypt-devel
- rtl-sdr-devel
- libp11-devel