hush/testsuite/all_sourcecode.tests
Rob Landley 3b84dfc2a8 Avoid spurious error message. (Technically applet order should be "SKIPPED"
when you move the testsuite directory outside of busybox and run it, but as
long as the test doesn't fail we're ok.)
2006-04-04 15:39:23 +00:00

19 lines
642 B
Bash
Executable File

#!/bin/sh
# Tests for the sourcecode base itself.
# Copyright 2006 by Mike Frysinger <vapier@gentoo.org>
# Licensed under GPL v2, see file LICENSE for details.
[ -n "$srcdir" ] || srcdir=$(pwd)
. testing.sh
# verify the applet order is correct in applets.h, otherwise
# applets won't be called properly.
sed -n -e '/^USE_[A-Z]*(APPLET(/{s:.*(::;s:,.*::;s:"::g;p}' \
$srcdir/../include/applets.h > applet.order.current 2> /dev/null
LC_ALL=C sort applet.order.current > applet.order.correct
testing "Applet order" "diff -u applet.order.current applet.order.correct" "" "" ""
rm -f applet.order.current applet.order.correct
exit $FAILCOUNT