/etc/ethers file is required for running tst-ethers and
tst-ethers-line tests.
If it does not exist, tests fail.
Signed-off-by: Nikita Sobolev <Nikita.Sobolev(a)synopsys.com>
---
test/uclibcng-testrunner.sh | 13 +++++++++++++
1 file changed, 13 insertions(+)
diff --git a/test/uclibcng-testrunner.sh b/test/uclibcng-testrunner.sh
index 4fd1661..4a02458 100644
--- a/test/uclibcng-testrunner.sh
+++ b/test/uclibcng-testrunner.sh
@@ -17,6 +17,9 @@
# of dealing in the work, even if advised of the possibility of such
# damage or existence of a defect, except proven that it results out
# of said person's immediate fault when using the work as intended.
+#
+# prepare function is used for creating ethers file. It is
+# necessary for running tst-ethers and tst-ethers-line tests.
#-
# Testsuite runner
@@ -25,6 +28,16 @@ die() {
exit 1
}
+
+prepare() {
+ if [ ! -s /etc/ethers ]
+ then
+ echo "00:11:22:33:44:55 teeth" > /etc/ethers
+ fi
+}
+
+prepare
+
test -s uclibcng-testrunner.in || die uclibcng-testrunner.in not found
nfail=0
--
2.16.2