summaryrefslogtreecommitdiffstats
path: root/tests/posix/depth_error.sh
diff options
context:
space:
mode:
Diffstat (limited to 'tests/posix/depth_error.sh')
-rw-r--r--tests/posix/depth_error.sh10
1 files changed, 3 insertions, 7 deletions
diff --git a/tests/posix/depth_error.sh b/tests/posix/depth_error.sh
index f770210..15cc82d 100644
--- a/tests/posix/depth_error.sh
+++ b/tests/posix/depth_error.sh
@@ -1,11 +1,7 @@
clean_scratch
"$XTOUCH" -p scratch/foo/bar
-chmod a-r scratch/foo
-
-bfs_diff scratch -depth
-ret=$?
-chmod +r scratch/foo
-clean_scratch
+chmod a-r scratch/foo
+trap "chmod +r scratch/foo" EXIT
-[ $ret -eq $EX_BFS ]
+check_exit $EX_BFS bfs_diff scratch -depth