summaryrefslogtreecommitdiff
path: root/src/lib
diff options
context:
space:
mode:
authorLuke Shumaker <LukeShu@sbcglobal.net>2013-06-01 15:37:38 -0600
committerLuke Shumaker <LukeShu@sbcglobal.net>2013-06-05 20:01:04 -0600
commit80e9fa38b703b3825eba1a32299884ff943ae556 (patch)
tree6b1df365df73ca6bef14ff699d8ebd02b3b4d1d7 /src/lib
parentba54f82cf53d0155c6756af60a012f8032744945 (diff)
Add tests for the libreblacklist help system, make them pass.
Diffstat (limited to 'src/lib')
-rwxr-xr-xsrc/lib/libreblacklist7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/lib/libreblacklist b/src/lib/libreblacklist
index 6876a2b..1d73d2f 100755
--- a/src/lib/libreblacklist
+++ b/src/lib/libreblacklist
@@ -25,7 +25,7 @@ blacklist-normalize() {
}
# Usage: blacklist-cat
-# Prints the blacklist
+# Prints the blacklist.
# Uses the chache, but downloads it if it doesn't exist. Also normalizes the
# blacklist for easier parsing.
blacklist-cat() {
@@ -127,6 +127,11 @@ if [[ "${0##*/}" == libreblacklist ]]; then
done
fi
}
+
+ if [[ $# == 0 ]]; then
+ usage >/dev/stderr
+ exit 1
+ fi
_blacklist_cmd=$1
shift
if [[ $_blacklist_cmd == -h ]]; then