diff options
Diffstat (limited to 'meta-openbmc-mods/meta-common/recipes-core/util-linux/util-linux/run-ptest')
-rw-r--r-- | meta-openbmc-mods/meta-common/recipes-core/util-linux/util-linux/run-ptest | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/meta-openbmc-mods/meta-common/recipes-core/util-linux/util-linux/run-ptest b/meta-openbmc-mods/meta-common/recipes-core/util-linux/util-linux/run-ptest new file mode 100644 index 000000000..3a910be12 --- /dev/null +++ b/meta-openbmc-mods/meta-common/recipes-core/util-linux/util-linux/run-ptest @@ -0,0 +1,24 @@ +#!/bin/sh + + +# When udevd (from eudev) is running most eject/mount tests will fail because +# of automount. We need to stop udevd before executing util-linux's tests. +# The systemd-udevd daemon doesn't change the outcome of util-linux's tests. +UDEV_PID="`pidof "@base_sbindir@/udevd"`" +if [ "x$UDEV_PID" != "x" ]; then + /etc/init.d/udev stop +fi + +current_path=$(readlink -f $0) +export bindir=$(dirname $current_path) +export PATH=$bindir/bin:$PATH + +./tests/run.sh --use-system-commands --parsable --show-diff | sed -u '{ + s/^\(.*\):\(.*\) \.\.\. OK$/PASS: \1:\2/ + s/^\(.*\):\(.*\) \.\.\. FAILED \(.*\)$/FAIL: \1:\2 \3/ + s/^\(.*\):\(.*\) \.\.\. SKIPPED \(.*\)$/SKIP: \1:\2 \3/ + }' + +if [ "x$UDEV_PID" != "x" ]; then + /etc/init.d/udev start +fi |