Scroll to navigation

App::Yath::Options::Finder(3pm) User Contributed Perl Documentation App::Yath::Options::Finder(3pm)

NAME

App::Yath::Options::Finder - Finder options for Yath.

DESCRIPTION

This is where the command line options for discovering test files are defined.

PROVIDED OPTIONS

YATH OPTIONS (PRE-COMMAND)

Finder Options

Specify what Finder subclass to use when searching for files/processing the file list. Use the "+" prefix to specify a fully qualified namespace, otherwise Test2::Harness::Finder::XXX namespace is assumed.

COMMAND OPTIONS

Finder Options

Specify one or more files as having been changed.

Can be specified multiple times

Only search for tests for changed files (Requires a coverage data source, also requires a list of changes either from the --changed option, or a plugin that implements changed_files() or changed_diff())
Path to a diff file that should be used to find changed files for use with --changed-only. This must be in the same format as `git diff -W --minimal -U1000000`
Specify one or more files to ignore when looking at changes

Can be specified multiple times

Exclude coverage tests which only load changed files, but never call code from them. (default: off)
Exclude changes outside of subroutines (perl files only) (default: off)
Exclude coverage tests which only open() changed files, but never call code from them. (default: off)
Ignore files matching this pattern when looking for changes. Your pattern will be inserted unmodified into a `$file =~ m/$pattern/` check.

Can be specified multiple times

Specify one or more files to check for changes. Changes to other files will be ignored

Can be specified multiple times

Specify a pattern for change checking. When only running tests for changed files this will limit which files are checked for changes. Only files that match this pattern will be checked. Your pattern will be inserted unmodified into a `$file =~ m/$pattern/` check.

Can be specified multiple times

Include changed lines that are whitespace only (default: off)
What plugin should be used to detect changed files.
Specify the default file/dir search when 'AUTHOR_TESTING' is set. Defaults to './xt'. The default AT search is only used if no files were specified at the command line

Can be specified multiple times

Specify the default file/dir search. defaults to './t', './t2', and 'test.pl'. The default search is only used if no files were specified at the command line

Can be specified multiple times

http://example.com/durations.json
Point at a json file or url which has a hash of relative test filenames as keys, and 'SHORT', 'MEDIUM', or 'LONG' as values. This will override durations listed in the file headers. An exception will be thrown if the durations file or url does not work.
Only fetch duration data if running at least this number of tests. Default (-j value + 1)
Exclude a file from testing

Can be specified multiple times

http://example.com/exclusions.txt
Point at a file or url which has a new line separated list of test file names to exclude from testing. Starting a line with a '#' will comment it out (for compatibility with Test2::Aggregate list files).

Can be specified multiple times

Exclude a pattern from testing, matched using m/$PATTERN/

Can be specified multiple times

Specify valid test filename extensions, default: t and t2

Can be specified multiple times

http://example.com/durations.json
Point at a json file or url which has a hash of relative test filenames as keys, and 'SHORT', 'MEDIUM', or 'LONG' as values. This will override durations listed in the file headers. An exception will be thrown if the durations file or url does not work.
Do not run tests that have their duration flag set to 'LONG'
Only run tests that have their duration flag set to 'LONG'
Re-Run tests from a previous run from a log file (or last log file). Plugins can intercept this, such as YathUIDB which will grab a run UUID and derive tests to re-run from that.
--rerun-all
--rerun-all=path/to/log.jsonl
--rerun-all=plugin_specific_string
Re-Run all tests from a previous run from a log file (or last log file). Plugins can intercept this, such as YathUIDB which will grab a run UUID and derive tests to re-run from that.
--rerun-failed
--rerun-failed=path/to/log.jsonl
--rerun-failed=plugin_specific_string
Re-Run failed tests from a previous run from a log file (or last log file). Plugins can intercept this, such as YathUIDB which will grab a run UUID and derive tests to re-run from that.
--rerun-missed
--rerun-missed=path/to/log.jsonl
--rerun-missed=plugin_specific_string
Run missed tests from a previously aborted/stopped run from a log file (or last log file). Plugins can intercept this, such as YathUIDB which will grab a run UUID and derive tests to re-run from that.
--rerun-modes failed,missed,...
--rerun-modes all
--rerun-modes failed
--rerun-modes missed
--rerun-modes passed
--rerun-modes retried
--rerun-mode failed,missed,...
--rerun-mode all
--rerun-mode failed
--rerun-mode missed
--rerun-mode passed
--rerun-mode retried
Pick which test categories to run

Can be specified multiple times

--rerun-passed
--rerun-passed=path/to/log.jsonl
--rerun-passed=plugin_specific_string
Re-Run passed tests from a previous run from a log file (or last log file). Plugins can intercept this, such as YathUIDB which will grab a run UUID and derive tests to re-run from that.
--rerun-plugin Foo
--rerun-plugin +App::Yath::Plugin::Foo
What plugin(s) should be used for rerun (will fallback to other plugins if the listed ones decline the value, this is just used ot set an order of priority)

Can be specified multiple times

--rerun-retried
--rerun-retried=path/to/log.jsonl
--rerun-retried=plugin_specific_string
Re-Run retried tests from a previous run from a log file (or last log file). Plugins can intercept this, such as YathUIDB which will grab a run UUID and derive tests to re-run from that.
List of tests and test directories to use instead of the default search paths. Typically these can simply be listed as command line arguments without the --search prefix.

Can be specified multiple times

Print a list of changed files if any are found

SOURCE

The source code repository for Test2-Harness can be found at http://github.com/Test-More/Test2-Harness/.

MAINTAINERS

AUTHORS

COPYRIGHT

Copyright 2020 Chad Granum <exodist7@gmail.com>.

This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.

See http://dev.perl.org/licenses/

2023-03-12 perl v5.36.0