.H 2 "rup Test Plan"

This chapter covers the
.B rup
command.  The main use of this command is to list information about the
hosts on the network, such as how long they have been up, how many users
are active on the system, and what the load average is.  It provides
much the same functionality as the Berkeley
.B ruptime
command.  The main distinction is that Berkeley
.B ruptime
uses a database of values collected from hosts sending broadcast
packets, one a minute (or so), and therefore the database may be
out of date.  The
.B rup
command, on the other hand, polls all the hosts on the network each time
it is run, so the values should be more accurate.

.H 3  "rup options"
.sp 1
.nf
RESPONSIBLE ENGINEER:    John A Dilley
ASSUMPTIONS:             module to be tested is functional
.fi

.sp 2
.H 4 "no options"
.sp 2
.nf
IMPLEMENT TIME:  0.25 md
PERFORM TIME:    1.0 md
TYPE OF TEST:    functional
EXPECTED OUTPUT: no output if the test passes
.fi
Test
.B rup
with no options.
It should print information about all the hosts on the network that are
running the rstatd.  This test should
look for the local host in the output; if it's present the test passes.
Note that the local host MUST be running the rstatd daemon for this test
to pass.

.sp 2
.H 4 "bad option"
.sp 1
.nf
IMPLEMENT TIME:  0.25 md
PERFORM TIME:    1.0 md
TYPE OF TEST:    functional
EXPECTED OUTPUT: no output if the test passes
.fi
Test
.B rup
with any option besides "-l", "-h" or "-t".  It should print the usage
error message on stderr and exit with a non-zero status.
Run 
.B rup
with the -d option and no arguments.
.sp 2
.H 4 "good options"
.sp 1
.nf
IMPLEMENT TIME:  0.75 md
PERFORM TIME:    1.5 md
TYPE OF TEST:    functional
EXPECTED OUTPUT: no output if the test passes
.fi
Test
.B rup
with all combinations of the valid options listed above.
Test with zero hosts, the local host, and then the local host and a
remote host.  In all cases, information about the local host should be
present in the output.  The above options are used to sort the
output according to different values; it would be rather easy to verify
that the values are indeed sorted, but it is not clear that this is
worthwhile, since this would basically be testing the
.B qsort()
library call.
Test
.B rup
with the -d option followed by a host name and the -d option followed
by a number.
.sp 2
.H 2 "Rstatd test plan"
.sp
The functionality of the rstat daemon is covered by the rup tests.
The following tests were added to increase the BFA coverage for the
rstat daemon:
.sp
.AL
.LI
Use pmap_conf with the "-p" option to call rpc.rstatd, program 100001,
versions 1, 2 and 3,  procedure 0 (NULL_PROC), procedure 2 and procedure 3
(not defined, it will execute the default case on the case statement).
.LE

