-
-
30 Mar 2022 09:25:47 UTC
- Distribution: Test-Smoke
- Module version: 0.002
- Source (raw)
- Browse (raw)
- Changes
- Homepage
- How to Contribute
- Repository
- Issues (24)
- Testers (221 / 5 / 0)
- Kwalitee
Bus factor: 2- 65.73% Coverage
- License: perl_5
- Perl: v5.10.0
- Activity
24 month- Tools
- Download (358.2KB)
- MetaCPAN Explorer
- Permissions
- Subscribe to distribution
- Permalinks
- This version
- Latest version
- Dependencies
- CGI::Util
- Capture::Tiny
- File::Spec
- HTTP::Tiny
- JSON::XS
- POSIX
- System::Info
- and possibly others
- Reverse dependencies
- CPAN Testers List
- Dependency graph
- NAME
- SYNOPSIS
- DESCRIPTION
- COPYRIGHT
NAME
Test::Smoke::App::Base - Baseclass for Test::Smoke::App::* applications.
SYNOPSIS
package Test::Smoke::App::Mailer; use base 'Test::Smoke::App::Base'; sub run {...}
DESCRIPTION
use Test::Smoke::App::Mailer; my $mailer = Test::Smoke::App::Mailer->new( main_options => [ Test::Smoke::App::AppOption->new( name => 'mailer', option => '=s', allow => [qw/MIME::lite sendmail/], helptext => "Mailsystem to use for sendig reports.", ), ], genral_options => [ Test::Smoke::AppOption->new( name => 'ddir', option => '=s', helptxt => "Smoke Destination Directory.", ), ], special_options => { 'MIME::Lite' => [ mserver(), msport(), msuser(), mspass(), ], 'sendmail' => [], }, ); $mailer->run();
Test::Smoke::App->new(%arguments)
Arguments
Named:
- main_options => $list_of_test_smoke_appoptions
- general_options => $list_of_test_smoke_appoptions
-
These options are always valid.
- special_options => $hashref
-
This is a hashref with the values of the
allow
-array, that hold a list of Test::Smoke::AppOptions.
Exceptions
None.
Test::Smoke::App::Base->configfile_option()
Returns a Test::Smoke::App::AppOption for 'configfile'.
Test::Smoke::App::Base->verbose_option()
Returns a Test::Smoke::App::AppOption for 'verbose'.
$app->show_config_option
$app->process_options()
This process constists of three (3) steps:
- 1. pre_process_options
-
This step organizes the options in a AppOptionCollection.
- 2. get_options
-
This step processes the arguments passed on the command line.
- 3. post_process_options
-
This step integrates the arguments, their coded-defaults, config-file values and command-line overrides.
Arguments
None.
Returns
The object-instance.
Exceptions
None.
$app->option($option)
Return the value of an option.
Arguments
Positional.
Returns
The value of that option if applicable.
Exceptions
$app->options()
Arguments
None.
Returns
A hash (list) of all options that apply to this instance of the app.
Exceptions
None.
COPYRIGHT
(c) 2002-2013, Abe Timmerman <abeltje@cpan.org> All rights reserved.
With contributions from Jarkko Hietaniemi, Merijn Brand, Campo Weijerman, Alan Burlison, Allen Smith, Alain Barbet, Dominic Dunlop, Rich Rauenzahn, David Cantrell.
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
See:
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
Module Install Instructions
To install Test::Smoke, copy and paste the appropriate command in to your terminal.
cpanm Test::Smoke
perl -MCPAN -e shell install Test::Smoke
For more information on module installation, please visit the detailed CPAN module installation guide.