diff --git a/usr.bin/lockf/tests/lockf_test.sh b/usr.bin/lockf/tests/lockf_test.sh --- a/usr.bin/lockf/tests/lockf_test.sh +++ b/usr.bin/lockf/tests/lockf_test.sh @@ -177,6 +177,23 @@ atf_check test "$status2" -eq 0 } +atf_test_case fdlockspin +fdlockspin_head() +{ + atf_set "descr" "Don't spin when locking a file descriptor" +} +fdlockspin_body() +{ + # Start background locker and give it time to get settled + lockf foo sleep 2 & sleep 1 + # Start foreground locker in fdlock mode + atf_check ktrace -tc lockf -t 3 0