SYNOPSIS

The \s-1XPA\s0 source code directory contains two test programs, stest.c, and ctest.c that can serve as examples for writing \s-1XPA\s0 servers and clients, respectively. They also can be used to test various features of \s-1XPA\s0.

DESCRIPTION

To build the \s-1XPA\s0 test programs, execute:

   make All

in the \s-1XPA\s0 source directory to generate the stest and ctest programs. (\s-1NB:\s0 this should work on all platforms, although we have had problems with unresolved externals on one Sun/Solaris machine, for reasons still unknown.)

The stest program can be executed with no arguments to start an \s-1XPA\s0 server that contains the access points: xpa, xpa1, c_xpa (containing sub-commands cmd1 and cmd2), and i_xpa. You then can use xpaset and xpaget to interact with these access points:

cat xpa.c | xpaset xpa # send to xpa cat xpa.c | xpaset "xpa*" # send to xpa and xpa1 xpaget xpa # receive from xpa xpaget xpa* # receive from xpa and xpa1

etc. You also can use ctest to do the same thing, or to iterate:

ctest \-s \-l 100 xpa # send to xpa 100 times ctest \-s \-l 100 "xpa*" # send to xpa and xpa1 100 times ctest \-g \-l 100 xpa # receive from xpa 100 times ctest \-g \-l 100 "xpa*" # receive from xpa and xpa1 100 times

More options are available: see the stest.c and ctest.c code itself, which were used extensively to debug \s-1XPA\s0.

The file test.tcl in the \s-1XPA\s0 source directory gives examples for using the XPATclInterface.

RELATED TO xpacode…

See xpa(7) for a list of \s-1XPA\s0 help pages