The Perl Toolchain Summit needs more sponsors. If your company depends on Perl, please support this very important event.

NAME

DTS_UT::Test::Harness::Straps::NoExec - subclass of Test::Harness::Straps to eval test file code instead of forking a process to execute it.

DESCRIPTION

DTS_UT::Test::Harness::Straps::NoExec will execute a test file code (Perl code, of course) by using an eval instead of forking a process to execute the script and read the results from it.

This is usefull to execute test in a web application running in a Apache/mod_perl or IIS/PerlEz environment, were forking a new process from the server process itself is never a good idea for performance reasons. There are some issues forking with IIS 5 with Perl, so this modules solves this problem as well.

DTS_UT::Test::Harness::Straps::NoExec is a hack from Test::Harness::Straps module. Those modules are not maintained anyore, so if you're taking serious about using it, my recomendation is that you check out TAP::Parser module documentation.

EXPORT

Everything that Test::Harness::Straps does.

METHODS

new

It expects as a parameter a DTS_UT::Model::UnitTest object.

Returns a DTS_UT::Test::Harness::Straps::NoExec object.

get_test

Returns the DTS_UT::Model::UnitTest object passed as an argument for new method.

analyze_file

Overrides analyze_file method from Test::Harness::Straps class.

Expects as parameter the package name that will be tested. The test script than needs to change it's default output to a text file instead of STDOUT.

See the methods failure_output and output of Test::More::Builder class.

SEE ALSO

AUTHOR

Alceu Rodrigues de Freitas Junior, <arfreitas@cpan.org>

COPYRIGHT AND LICENSE

Copyright (C) 2008 by Alceu Rodrigues de Freitas Junior

This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself, either Perl version 5.8.8 or, at your option, any later version of Perl 5 you may have available.