Dist::Zilla::Plugin::Stenciller::MojoliciousTests - Create Mojolicious tests from text files parsed with Stenciller
Version 0.0200, released 2016-03-23.
; in dist.ini ; these are the defaults: [Stenciller::MojoliciousTests] source_directory = examples/source file_pattern = .+\.stencil template_file = examples/source/template.test output_directory = t
Dist::Zilla::Plugin::Stenciller::MojoliciousTests uses Stenciller and Stenciller::Plugin::ToMojoliciousTest to turn stencil files in source_directory (that matches the file_pattern) into test files in output_directory by applying the template_file.
source_directory
file_pattern
output_directory
template_file
This Dist::Zilla plugin does the FileGatherer role.
FileGatherer
Path to where the stencil files are.
Path to where the generated files are saved.
This is put inside a regular expression (with start and end anchors) to find stencil files in the source_directory. The output files will have the same basename, but the suffix is replaced by t.
t
The template file should contain use statements and such. The transformed contents returned from Stenciller::Plugin::ToMojoliciousTest will be placed after the contents of template_file. The template file is applied to each stencil file, so the number of generated test files is equal to the number of stencil files.
Stenciller
Stenciller::Plugin::ToMojoliciousTest
https://github.com/Csson/p5-Dist-Zilla-Plugin-Stenciller-MojoliciousTests
https://metacpan.org/release/Dist-Zilla-Plugin-Stenciller-MojoliciousTests
Erik Carlsson <info@code301.com>
This software is copyright (c) 2016 by Erik Carlsson.
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 Dist::Zilla::Plugin::Stenciller::MojoliciousTests, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Dist::Zilla::Plugin::Stenciller::MojoliciousTests
CPAN shell
perl -MCPAN -e shell install Dist::Zilla::Plugin::Stenciller::MojoliciousTests
For more information on module installation, please visit the detailed CPAN module installation guide.