summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLars Wirzenius <liw@liw.fi>2011-08-29 20:37:45 +0100
committerLars Wirzenius <liw@liw.fi>2011-08-29 20:37:45 +0100
commitcd449e243c8e1945c0b148332cb5e2f2773bd697 (patch)
tree71b44a388010108230937e1faa2da3813110d408
parentd818e696335a0505d323393597180038a295714b (diff)
downloadcmdtest-cd449e243c8e1945c0b148332cb5e2f2773bd697.tar.gz
Add foo.script to README.
-rw-r--r--README6
1 files changed, 5 insertions, 1 deletions
diff --git a/README b/README
index 7ab533e..200c322 100644
--- a/README
+++ b/README
@@ -14,6 +14,8 @@ Each test case consists of:
* a set of command line arguments, not including the command name (`foo.args`)
- each argument is on its own line
+* alternatively, a script to run the command, in case that's easier
+ (`foo.script`)
* the file fed to standard input (`foo.stdin`)
* the expected output to the standard output (`foo.stdout`)
* the expected output to the standard error (`foo.stderr`)
@@ -37,7 +39,8 @@ or several such directories, and it does the following:
- execute `setup`
- execute `foo.setup`
- execute the command, giving it command line arguments from
- `foo.args`, and redirecting standard input to come from `foo.stdin`
+ `foo.args`, or by running `foo.script`,
+ and redirecting standard input to come from `foo.stdin`
- capture standard output and error and exit codes
- execute `foo.teardown`
- execute `teardown`
@@ -60,6 +63,7 @@ to achieve.
The shell scripts may use the following environment variables:
* `DATADIR`: a temporary directory where files may be created by the test
+* `COMMAND`: the command to be run; it is an absolute pathname
In addition, the `foo.args` files can use Pythonic string expansion: