]> git.pond.sub.org Git - empserver/blob - tests/info-test
ship: Unbreak MOB_ACCESS real-time mobility update for ships
[empserver] / tests / info-test
1 #!/bin/sh -e
2 # Documentation completeness test for Empire
3
4 if [ $# -ne 1 ]
5 then echo "Usage: $0 SRCDIR" >&2; exit 1
6 fi
7
8 srcdir="$1"
9
10 . "$srcdir"/tests/test-common.sh
11
12 create_sandbox
13 # Suppress test-only commands:
14 cat >>$econfig <<EOF
15 running_test_suite 0
16 EOF
17
18 # begin_test warns POSIX isn't expected to work, because thread
19 # scheduling isn't reliably deterministic.  Not an issue for this
20 # test, so suppress the warning.
21 [ "$empthread" = POSIX ] && warn_empthread=
22
23 begin_test <<EOF
24 add 1 1 1 p
25 des 0:2,0 -
26 newcap 1 0,0
27 add 2 visitor visitor v
28 nat
29 nat 1
30 nat 2
31 EOF
32
33 feed_input POGO peter <<EOF
34 list >sandbox/deity.list
35 EOF
36 feed_input 1 1 <<EOF
37 list >sandbox/sanctuary.list
38 break
39 list >sandbox/active.list
40 EOF
41 feed_input visitor visitor <<EOF
42 list >sandbox/visitor.list
43 EOF
44
45 end_test
46
47 if perl $testdir/cmp-toc-vs-lists.pl info/toc sandbox/*.list
48 then echo "Command documentation OK"
49 else echo "Command documentation FAIL"; false
50 fi