| 1 | package Code::Style::Kit::Parts::Test; | ||
| 2 | use strict; | ||
| 3 | use warnings; | ||
| 4 | our $VERSION = '1.0.3'; # VERSION | ||
| 5 | # ABSTRACT: commonly used test modules (Test::More style) | ||
| 6 | |||
| 7 | |||
| 8 | use Import::Into; | ||
| 9 | |||
| 10 | sub feature_test_export { | ||
| 11 | my ($self, $caller) = @_; | ||
| 12 | |||
| 13 | require Test::More; | ||
| 14 | Test::More->import::into($caller); | ||
| 15 | require Test::Deep; | ||
| 16 | Test::Deep->import::into($caller); | ||
| 17 | require Test::Fatal; | ||
| 18 | Test::Fatal->import::into($caller); | ||
| 19 | require Test::Warnings; | ||
| 20 | Test::Warnings->import::into($caller); | ||
| 21 | require lib; | ||
| 22 | lib->import::into($caller, 't/lib'); | ||
| 23 | require Log::Any::Adapter; | ||
| 24 | # log to TAP, showing the category, skipping the "how to use | ||
| 25 | # this" message, and showing all log messages | ||
| 26 | $ENV{TAP_LOG_ORIGIN}=1; | ||
| 27 | $ENV{TAP_LOG_SHOW_USAGE}=0; | ||
| 28 | Log::Any::Adapter->set( | ||
| 29 | TAP => ( filter => 'none' ), | ||
| 30 | ); | ||
| 31 | } | ||
| 32 | |||
| 33 | 1; | ||
| 34 | |||
| 35 | __END__ |