Skip to content

Commit

Permalink
Less silly shell code.
Browse files Browse the repository at this point in the history
  • Loading branch information
yugr committed Dec 22, 2024
1 parent cd6170d commit d1cbd63
Showing 1 changed file with 4 additions and 20 deletions.
24 changes: 4 additions & 20 deletions tests/test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -65,32 +65,16 @@ fi
has_feature() {
case $d in
asan)
if test -n "$ASAN_PRELOAD"; then
return 0
else
return 1
fi
test -n "$ASAN_PRELOAD"
;;
bsd)
if uname | grep -q BSD; then
return 0
else
return 1
fi
uname | grep -q BSD
;;
netbsd)
if uname | grep -q NetBSD; then
return 0
else
return 1
fi
uname | grep -q NetBSD
;;
syslog)
if test -r /var/log/syslog || which journalctl > /dev/null; then
return 0
else
return 1
fi
test -r /var/log/syslog || which journalctl > /dev/null
;;
*)
echo >&2 "$t: unknown feature: $d"
Expand Down

0 comments on commit d1cbd63

Please sign in to comment.