use alienfile; plugin 'Test::Mock' => ( probe => 'share', download => 1, extract => 1, build => 1, gather => 1, );
plugin 'Test::Mock' => ( probe => $probe, );
Override the probe behavior by one of the following:
plugin 'Test::Mock' => ( download => \%fs_spec, ); plugin 'Test::Mock' => ( download => 1, );
Mock out a download. The %fs_spec is a hash where the hash values are directories and the string values are files. This a spec like this:
plugin 'Test::Mock' => ( download => { 'foo-1.00' => { 'README.txt' => "something to read", 'foo.c' => "#include <stdio.h>\n", "int main() {\n", " printf(\"hello world\\n\");\n", "}\n", } }, );
Would generate two files in the directory 'foo-1.00', a "README.txt" and a C file named "foo.c". The default, if you provide a true non-hash value is to generate a single tarball with the name "foo-1.00.tar.gz".
plugin 'Test::Mock' => ( extract => \%fs_spec, ); plugin 'Test::Mock' => ( extract => 1, );
Similar to "download" above, but for the "extract" phase.
plugin 'Test::Mock' => ( build => [ \%fs_spec_build, \%fs_spec_install ], ); plugin 'Test::Mock' => ( build => 1, );
plugin 'Test::Mock' => ( gather => \%runtime_prop, ); plugin 'Test::Mock' => ( gather => 1, );
This adds a gather hook (for both "share" and "system") that adds the given runtime properties, or if a true non-hash value is provided, some reasonable runtime properties for testing.
Contributors:
Diab Jerius (DJERIUS)
Roy Storey
Ilya Pavlov
David Mertens (run4flat)
Mark Nunberg (mordy, mnunberg)
Christian Walde (Mithaldu)
Brian Wightman (MidLifeXis)
Zaki Mughal (zmughal)
mohawk (mohawk2, ETJ)
Vikas N Kumar (vikasnkumar)
Flavio Poletti (polettix)
Salvador Fandiño (salva)
Gianni Ceccarelli (dakkar)
Pavel Shaydo (zwon, trinitum)
Kang-min Liu (劉康民, gugod)
Nicholas Shipp (nshp)
Juan Julián Merelo Guervós (JJ)
Joel Berger (JBERGER)
Petr Pisar (ppisar)
Lance Wicks (LANCEW)
Ahmad Fatoum (a3f, ATHREEF)
José Joaquín Atria (JJATRIA)
Duke Leto (LETO)
Shoichi Kaji (SKAJI)
Shawn Laffan (SLAFFAN)
This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.