Test::TempDir::Handle - A handle for managing a temporary directory root
version 0.11
use Test::TempDir::Handle; my $h = Test::TempDir::Handle->new( dir => dir("t/tmp") ); $h->empty; # ... $h->cleanup; # will delete on success by default
This class manages a temporary directory.
dir
The Path::Class::Dir that is being managed.
lock
No longer used.
cleanup_policy
One of success, always or never.
success
always
never
success means that cleanup deletes only if test_builder says the tests have passed.
cleanup
test_builder
The Test::Builder singleton.
empty
Cleans out the directory but doesn't delete it.
delete
Cleans out the directory and removes it.
Calls delete if the cleanup_policy dictates to do so.
This is normally called automatically at destruction.
Bugs may be submitted through the RT bug tracker (or bug-Test-TempDir@rt.cpan.org).
There is also a mailing list available for users of this distribution, at http://lists.perl.org/list/perl-qa.html.
There is also an irc channel available for users of this distribution, at #perl on irc.perl.org.
#perl
irc.perl.org
יובל קוג'מן (Yuval Kogman) <nothingmuch@woobling.org>
This software is copyright (c) 2006 by יובל קוג'מן (Yuval Kogman).
This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.
To install Test::TempDir, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Test::TempDir
CPAN shell
perl -MCPAN -e shell install Test::TempDir
For more information on module installation, please visit the detailed CPAN module installation guide.