xref: /netbsd-src/external/bsd/atf/dist/doc/atf-test-program.1 (revision 3816d47b2c42fcd6e549e3407f842a5b1a1d23ad)
1.\"
2.\" Automated Testing Framework (atf)
3.\"
4.\" Copyright (c) 2007, 2008 The NetBSD Foundation, Inc.
5.\" All rights reserved.
6.\"
7.\" Redistribution and use in source and binary forms, with or without
8.\" modification, are permitted provided that the following conditions
9.\" are met:
10.\" 1. Redistributions of source code must retain the above copyright
11.\"    notice, this list of conditions and the following disclaimer.
12.\" 2. Redistributions in binary form must reproduce the above copyright
13.\"    notice, this list of conditions and the following disclaimer in the
14.\"    documentation and/or other materials provided with the distribution.
15.\"
16.\" THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND
17.\" CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES,
18.\" INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
19.\" MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
20.\" IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY
21.\" DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
22.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE
23.\" GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
24.\" INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER
25.\" IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
26.\" OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN
27.\" IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
28.\"
29.Dd August 18, 2007
30.Dt ATF-TEST-PROGRAM 1
31.Os
32.Sh NAME
33.Nm atf-test-program
34.Nd common interface to ATF test programs
35.Sh SYNOPSIS
36.Nm
37.Op Fl r Ar fd
38.Op Fl s Ar srcdir
39.Op Fl v Ar var1=value1 Op .. Fl v Ar varN=valueN
40.Op Ar test_case1 Op Ar .. test_caseN
41.Nm
42.Fl l
43.Ar test_case1
44.Op Ar test_case1 Op Ar .. test_caseN
45.Nm
46.Fl h
47.Sh DESCRIPTION
48Test programs written using the ATF libraries all share a common user
49interface, which is what this manual page describes.
50.Pp
51In the first synopsis form, the test program will execute the listed
52test cases, or all of them if none are provided as arguments.
53The test cases' names can be given as glob patterns.
54.Pp
55In the second synopsis form, the test program will list all available
56test cases alongside a brief description of what they do.
57If any arguments are specified, the list will be restricted to the
58matching test cases.
59The test cases' names can be given as glob patterns.
60.Pp
61In the third synopsis form, the test program will print information
62about all supported options and their purpose.
63.Pp
64The following options are available:
65.Bl -tag -width XvXvarXvalueXX
66.It Fl h
67Shows a short summary of all available options and their purpose.
68.It Fl l
69Lists available test cases alongside a brief description for each of them.
70.It Fl r Ar fd
71Specifies the file descriptor to which the test case will redirect its
72results.
73These results follow a machine-parseable standardized format, and are not
74meant for direct user consumption.
75See
76.Xr atf-formats 5
77for more details.
78.It Fl s Ar srcdir
79The path to the directory where the test program is located.
80This is needed in all cases, except when the test program is being executed
81from the current directory.
82The test program will use this path to locate any helper data files or
83utilities.
84.It Fl v Ar var=value
85Sets the configuration variable
86.Ar var
87to the value
88.Ar value .
89.El
90.Sh SEE ALSO
91.Xr atf-run 1 ,
92.Xr atf 7
93