Skip to content

uperl/Test2-Require-ProgramInPath

Repository files navigation

Test2::Require::ProgramInPath static linux

Skip test unless a program exists in the PATH

SYNOPSIS

use Test2::Require::ProgramInPath 'gcc';
use Test2::V0;
use Test::Script qw( program_runs );

program_runs ['gcc', 'foo.c'];

done_testing;

DESCRIPTION

This is skip unless a particular program can be found in the PATH. Under the covers File::Which is used. This is a subclass of Test2::Require.

METHODS

skip

Should not be invoked directly, but returns `undef` if the test should not be skipped and a string containing the reason why the test was skipped. Currently `This test only runs if $program is in the PATH` is returned.

SEE ALSO

AUTHOR

Graham Ollis [email protected]

COPYRIGHT AND LICENSE

This software is copyright (c) 2025 by Graham Ollis.

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

About

Skip test unless a program exists in the PATH

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages