f1cb09a2d3
The content of this branch was automatically imported from Fedora ELN with the following as its source: https://src.fedoraproject.org/rpms/ipset#c937e6ad0a272b39d0535b69057ba5d9eac9441d
51 lines
1.2 KiB
Bash
Executable File
51 lines
1.2 KiB
Bash
Executable File
#!/bin/bash
|
|
# SPDX-License-Identifier: LGPL-2.1+
|
|
# ~~~
|
|
# runtest.sh of ipset
|
|
# Description: ipset tests.
|
|
#
|
|
# Author: Susant Sahani <susant@redhat.com>
|
|
# Copyright (c) 2018 Red Hat, Inc.
|
|
# ~~~
|
|
|
|
# Include Beaker environment
|
|
. /usr/share/beakerlib/beakerlib.sh || exit 1
|
|
|
|
PACKAGE="ipset"
|
|
|
|
SERVICE_UNITDIR="/var/run/systemd/system"
|
|
|
|
rlJournalStart
|
|
rlPhaseStartSetup
|
|
rlAssertRpm $PACKAGE
|
|
rlRun "systemctl stop firewalld" 0,5
|
|
rlRun "setenforce 0" 0,1
|
|
|
|
rlRun "[ -e /sys/class/net/veth-test ] && ip link del veth-test" 0,1
|
|
|
|
rlRun "cp iperf3d.service $SERVICE_UNITDIR"
|
|
rlRun "cp ipset-tests.py /usr/bin/"
|
|
|
|
rlRun "systemctl daemon-reload"
|
|
rlPhaseEnd
|
|
|
|
rlPhaseStartTest
|
|
rlLog "Starting ipset tests ..."
|
|
rlRun "/usr/bin/python3 /usr/bin/ipset-tests.py"
|
|
rlPhaseEnd
|
|
|
|
rlPhaseStartCleanup
|
|
rlRun "rm /usr/bin/ipset-tests.py"
|
|
rlRun "[ -e /sys/class/net/veth-test ] && ip link del veth-test" 0,1
|
|
|
|
rlRun "rm $SERVICE_UNITDIR/iperf3d.service"
|
|
rlRun "systemctl daemon-reload"
|
|
|
|
rlRun "setenforce 1" 0,1
|
|
rlLog "ipset tests done"
|
|
rlPhaseEnd
|
|
rlJournalPrintText
|
|
rlJournalEnd
|
|
|
|
rlGetTestState
|