aboutsummaryrefslogtreecommitdiff
path: root/doc
diff options
context:
space:
mode:
authorKaren Arutyunov <karen@codesynthesis.com>2017-06-16 23:43:24 +0300
committerKaren Arutyunov <karen@codesynthesis.com>2017-06-19 12:57:24 +0300
commit062e03325cf9bb7fecfb9ea254ceb5c0cf427a7a (patch)
treec9e29b96a4ae919dcd99541d38e191c7fe20c7b1 /doc
parent4c2243f8c790207c0ee4119fcb081b69f06f476e (diff)
Add support for exit testscript builtin
Diffstat (limited to 'doc')
-rw-r--r--doc/testscript.cli21
1 files changed, 21 insertions, 0 deletions
diff --git a/doc/testscript.cli b/doc/testscript.cli
index c039ec0..7b3d472 100644
--- a/doc/testscript.cli
+++ b/doc/testscript.cli
@@ -2334,6 +2334,27 @@ echo <string>...
Write strings to \c{stdout} separating them with a single space and ending
with a newline.
+
+\h#builtins-exit|\c{exit}|
+
+\
+exit [<diagnostics>]
+\
+
+Exit the current group or test scope skipping any remaining commands.
+
+Note that \c{exit} is a \i{pseudo-builtin}. In particular, it must be the only
+command in the pipe expression and its standard streams cannot be redirected.
+
+Without any arguments \c{exit} exits the current scope successfully. In this
+case, if exiting a group scope, teardown commands and cleanups are executed
+normally.
+
+If an argument is specified, then \c{exit} exits the current scope and all
+the outer scopes unsuccessfully, as if the \c{exit} command failed. In this
+case the argument must be the diagnostics string describing the error.
+
+
\h#builtins-false|\c{false}|
\