xref: /freebsd/bin/sh/tests/execution/fork2.0 (revision 5ca8e32633c4ffbbcd6762e5888b6a4ba0708c6c)
1
2result=$(${SH} -c '(/bin/sleep 1)& sleep 0.1; ps -p $! -o comm=; kill $!')
3test "$result" = sleep || exit 1
4
5result=$(${SH} -c '{ trap "echo trapped" EXIT; (/usr/bin/true); } & wait')
6test "$result" = trapped || exit 1
7
8exit 0
9