-
Notifications
You must be signed in to change notification settings - Fork 3
CLI
Antler's command line interface (CLI) is used to perform all operations on test projects. See Configuration for info on project configuration.
Note
Each of the antler
commands must be run in the project's directory.
The antler init
command creates a sample project that's ready for use. See
Quick Start for more info on the project that the
init
command creates. antler init
must be run in an empty directory, and
the name of the directory is used as the CUE package name.
The antler vet
command parses the CUE configuration, and may be used to
validate the syntax before running tests. If the project is OK, nothing is
emitted and antler
exits with status 0. If there is an error, it's emitted,
and antler
exits with a nonzero status code.
The antler list
command lists the tests in a project. By default, all tests
are listed, but filter arguments may be used to restrict
the listed tests. This may be used to determine which tests would be run
when supplying the same arguments to the run
command.
The antler run
command runs tests. Without any arguments, run
does
an incremental test run, meaning it runs:
- Tests that have not been run before (includes new or renamed tests)
- Tests that ran before but ended in an error
Any tests that were not run will have their results hard linked from a prior run (if available). That way, the latest result directory always contains results from all tests that were run.
Filter arguments may be supplied to select specific tests
to run/re-run, or all tests may be run using antler run -a
.
The antler report
command may be used to re-run reports, without having to
take the time to re-run the associated tests, making it faster to make changes
that only affect the Reports configuration. It takes
no arguments, and always re-runs all reports.
If a report generates an output file with exactly the same contents as a prior version, it is hard linked to the prior version to reduce disk usage.
The antler server
command runs a web server that serves the project's results
directory as static content. By default, it listens on port 8080, but this can
be changed in the Server configuration.
Filter arguments may be supplied to the list
, run
and report
commands.
Each filter argument may be either a single regex pattern matching the value of
any ID
field, or a string in the form key=value
, where key
and value
are
separate patterns that must match both a test ID's key and value for it to be
accepted. Multiple filters are combined together with a logical AND.
Example 1: antler list cubic
Example 2: antler list qdisc=codel rtt='(20ms|40ms)'