stestr last Command¶
Show the last run loaded into a repository.
-
class
stestr.commands.last.
Last
(app, app_args, cmd_name=None)[source]¶ -
get_description
()[source]¶ Return the command description.
The default is to use the first line of the class’ docstring as the description. Set the
_description
class attribute to a one-line description of a command to use a different value. This is useful for enabling translations, for example, with_description
set to a string wrapped with a gettext translation marker.
-
-
stestr.commands.last.
last
(repo_type='file', repo_url=None, subunit_out=False, pretty_out=True, color=False, stdout=<_io.TextIOWrapper name='<stdout>' mode='w' encoding='utf-8'>, suppress_attachments=False)[source]¶ Show the last run loaded into a a repository
This function will print the results from the last run in the repository to STDOUT. It can optionally print the subunit stream for the last run to STDOUT if the
subunit
option is set to true.Note this function depends on the cwd for the repository if repo_type is set to file and repo_url is not specified it will use the repository located at CWD/.stestr
Parameters: - repo_type (str) – This is the type of repository to use. Valid choices are ‘file’ and ‘sql’.
- repo_url (str) – The url of the repository to use.
- subunit_out (bool) – Show output as a subunit stream.
- pretty_out – Use the subunit-trace output filter.
- color – Enable colorized output with the subunit-trace output filter.
- subunit (bool) – Show output as a subunit stream.
- stdout (file) – The output file to write all output to. By default this is sys.stdout
- suppress_attachments (bool) – When set true attachments subunit_trace will not print attachments on successful test execution.
Return return_code: The exit code for the command. 0 for success and > 0 for failures.
Return type: int