Add an auxiliary subroutine to generate some events for testing
This test is also timeout on a quiet system because there is nobody triggering read probefunc while test execution. Reviewed by: gnn, markj, ngie Differential Revision: https://reviews.freebsd.org/D11731
This commit is contained in:
parent
cea9310d4e
commit
ad89d783a6
@ -39,6 +39,15 @@
|
||||
##
|
||||
|
||||
|
||||
reader()
|
||||
{
|
||||
while true
|
||||
do
|
||||
sleep 0.1
|
||||
cat /etc/motd > /dev/null
|
||||
done
|
||||
}
|
||||
|
||||
if [ $# != 1 ]; then
|
||||
echo expected one argument: '<'dtrace-path'>'
|
||||
exit 2
|
||||
@ -46,6 +55,9 @@ fi
|
||||
|
||||
dtrace=$1
|
||||
|
||||
reader &
|
||||
child=$!
|
||||
|
||||
$dtrace -qZf wassup'{printf("Iamkool");}' \
|
||||
-qf read'{printf("I am done"); exit(0);}'
|
||||
|
||||
@ -55,4 +67,6 @@ if [ "$status" -ne 0 ]; then
|
||||
echo $tst: dtrace failed
|
||||
fi
|
||||
|
||||
kill $child
|
||||
|
||||
exit $status
|
||||
|
Loading…
x
Reference in New Issue
Block a user