Add gating tests that got lost in the grab from Fedora

Resolves: rhbz#1999980
This commit is contained in:
Christine Caulfield 2021-10-11 08:35:47 +01:00
parent 7f4f1a2bd1
commit 088bed91e6
2 changed files with 54 additions and 0 deletions

35
tests/run-tests.sh Executable file
View File

@ -0,0 +1,35 @@
#!/bin/sh
EXCLUDES="knet_bench_test api_knet_handle_new_limit_test fun_pmtud_crypto_test run-tests.sh"
TESTS_RUN=0
TESTS_FAILED=0
modprobe sctp
cd /usr/lib64/kronosnet/tests
for i in *
do
echo $EXCLUDES|grep $i >/dev/null 2>/dev/null
if [ $? = 1 ]
then
echo
echo "---- running $i"
./$i
if [ $? != 0 ]
then
TESTS_FAILED=$((TESTS_FAILED + 1))
echo "FAILED: $i"
fi
TESTS_RUN=$((TESTS_RUN + 1))
fi
done
echo
echo "Tests run: $TESTS_RUN"
echo "Tests failed: $TESTS_FAILED"
if [ $TESTS_FAILED -gt 0 ]
then
exit 1
else
exit 0
fi

19
tests/tests.yml Normal file
View File

@ -0,0 +1,19 @@
- hosts: localhost
roles:
- role: standard-test-source # Fetch source tarball and unpack it into the test environment
tags:
- always
- role: standard-test-basic
tags:
- atomic
- classic
required_packages:
- bash
- kronosnet-tests
- kernel-modules-extra
tests:
- check: # Run tests
dir: .
run: ./run-tests.sh