NAME
Test::Class::Moose::Config - Configuration information for Test::Class::Moose
VERSION
version 0.72
SYNOPSIS
my $tc_config = Test::Class::Moose::Config->new({
show_timing => 1,
statistics => 1,
randomize => 0,
});
my $test_suite = Test::Class::Moose->new($tc_config);
DESCRIPTION
For internal use only (maybe I'll expose it later). Not guaranteed to be stable.
This class defines many of the attributes for Test::Class::Moose. They're kept here to minimize namespace pollution in Test::Class::Moose.
ATTRIBUTES
show_timing
Boolean. Will display verbose information on the amount of time it takes each test class/test method to run.
statistics
Boolean. Will display number of classes, test methods and tests run.
use_environment
Boolean. Sets show_timing and statistics to true if your test harness is running verbosely, false otherwise.
test_classes
Takes a class name or an array reference of class names. If it is present, the test_classes
method will only return these classes. This is very useful if you wish to run an individual class as a test:
Test::Class::Moose->new(
test_classes => $ENV{TEST_CLASS}, # ignored if undef
)->runtests;
include_tags
Array ref of strings matching method tags (a single string is also ok). If present, only test methods whose tags match include_tags
or whose tags don't match exclude_tags
will be included. However, they must still start with test_
.
For example:
my $test_suite = Test::Class::Moose->new({
include_tags => [qw/api database/],
});
The above constructor will only run tests tagged with api
or database
.
exclude_tags
The same as include_tags
, but will exclude the tests rather than include them. For example, if your network is down:
my $test_suite = Test::Class::Moose->new({
exclude_tags => [ 'network' ],
});
# or
my $test_suite = Test::Class::Moose->new({
exclude_tags => 'network',
});
randomize
Boolean. Will run test methods of a class in a random order.
randomize_classes
Boolean. Will run test classes in a random order.
METHODS
args
my $tests = Some::Test::Class->new($test_suite->test_configuration->args);
Returns a hash of the args used to build the configuration. Used in testing. You probably won't need it.
SUPPORT
You can find documentation for this module with the perldoc command.
perldoc Test::Class::Moose
You can also look for information at:
RT: CPAN's request tracker (report bugs here)
AnnoCPAN: Annotated CPAN documentation
CPAN Ratings
Search CPAN
ACKNOWLEDGEMENTS
BUGS
Please report any bugs or feature requests to bug-test-class-moose at rt.cpan.org
, or through the web interface at http://rt.cpan.org/NoAuth/ReportBug.html?Queue=Test-Class-Moose. I will be notified, and then you'll automatically be notified of progress on your bug as I make changes.
bugs may be submitted through https://github.com/test-class-moose/test-class-moose/issues.
I am also usually active on IRC as 'drolsky' on irc://irc.perl.org
.
AUTHORS
Curtis "Ovid" Poe <ovid@cpan.org>
Dave Rolsky <autarch@urth.org>
COPYRIGHT AND LICENCE
This software is copyright (c) 2012 - 2016 by Curtis "Ovid" Poe.
This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.