Statocles::Test - Common test routines for Statocles
version 0.030
Test an object constructor. class is the class to test. args is a list of name/value pairs with the following keys:
class
args
A set of name/value pairs for required arguments. These will be tested to ensure they are required. They will be added to every attempt to construct an object.
A set of name/value pairs for default arguments. These will be tested to ensure they are set to the correct defaults.
Test the pages of the given app. tests is a set of pairs of path => callback to test the pages returned by the app.
tests
path
callback
The callback will be given two arguments:
output
The output of the rendered page.
dom
If the page is HTML, a Mojo::DOM object ready for testing.
Doug Bell <preaction@cpan.org>
This software is copyright (c) 2014 by Doug Bell.
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 Statocles, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Statocles
CPAN shell
perl -MCPAN -e shell install Statocles
For more information on module installation, please visit the detailed CPAN module installation guide.