]> diplodocus.org Git - nmh/blobdiff - test/anno/test-anno
Editing of man/prev.man.
[nmh] / test / anno / test-anno
index a9ad95ae440937d58a0f0c477430653a407b9d8f..89204ccb259cb29ee6652e7495b7491cefa9c495 100755 (executable)
@@ -16,6 +16,25 @@ fi
 
 setup_test
 
+check_exit '-eq 1' anno -
+check_exit '-eq 1' anno -comp
+check_exit '-eq 1' anno -comp foo -comp bar
+check_exit '-eq 1' anno -text
+check_exit '-eq 1' anno -text foo -text bar
+check_exit '-eq 1' anno -number 0
+check_exit '-eq 1' anno -number -number
+check_exit '-eq 1' anno + @
+check_exit '-eq 1' anno -draft 42
+check_exit '-eq 1' anno -draft -list </dev/null
+check_exit '-eq 1' anno -draft -list -comp foo
+check_exit '-eq 1' anno -draft -comp f.o:
+check_exit '-eq 1' anno -draft -comp ''
+x=tendixzehn
+l=$x$x$x$x$x
+c=$l$l
+d=$c$c$c$c$c
+check_exit '-eq 1' anno -draft -comp $d$c$c$c$c$l$x$x$x${x}123456789
+
 expected=$MH_TEST_DIR/$$.expected
 expected_err=$MH_TEST_DIR/$$.expected_err
 actual=$MH_TEST_DIR/$$.actual
@@ -39,7 +58,8 @@ Usage: anno [+folder] [msgs] [switches]
   -([no]p)reserve
 EOF
 
-run_prog anno -help >"$actual" 2>&1
+#### Skip nmh intro text.
+run_prog anno -help | sed '/^$/,$d' >"$actual" 2>&1
 check "$expected" "$actual"
 
 # check -version