NAME
Test::Mini::Unit - Clean Unit Testing with Moose
VERSION
version 0.0501
SYNOPSIS
Real Documentation is coming. In the meantime, enjoy the montage!
Traditional Style
package TraditionalTest;
use Test::Mini::Unit;
use Test::Mini::Unit::Assertions;
sub setup { 'This runs before each test...' }
sub teardown { 'This runs after each test...' }
sub test_assert { assert 1, 'I should pass' }
sub test_refute { refute 0, 'I should fail' }
sub test_skip { skip "I've got better things to do" }
1;
Classical Style
use Test::Mini::Unit;
class ClassicalTest extends Test::Mini::Unit::TestCase
{
use Test::Mini::Unit::Assertions;
method setup() { 'This runs before each test...' }
method teardown() { 'This runs after each test...' }
method test_assert() { assert 1, 'I should pass' }
method test_refute() { refute 0, 'I should fail' }
method test_skip() { skip "I've got better things to do" }
}
Sweetened Style
use Test::Mini::Unit;
testcase SugaryTest
{
setup { 'This runs before each test...' }
teardown { 'This runs after each test...' }
test passes() { assert 1, 'I should pass' }
test refute() { refute 0, 'I should fail' }
test skip() { skip "I've got better things to do" }
}
AUTHOR
Pieter Vande Bruggen, <pvande@cpan.org<gt>
COPYRIGHT AND LICENSE
Copyright (C) 2010 by Pieter Vande Bruggen
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.9 or, at your option, any later version of Perl 5 you may have available.