github
Advanced Search
  • Home
  • Pricing and Signup
  • Explore GitHub
  • Blog
  • Login

pdcawley / test-class-sugar

  • Admin
  • Watch Unwatch
  • Fork
  • Your Fork
  • Pull Request
  • Download Source
    • 9
    • 3
  • Source
  • Commits
  • Network (3)
  • Issues (0)
  • Downloads (1)
  • Wiki (1)
  • Graphs
  • Branch: master

click here to add a description

click here to add a homepage

  • Branches (1)
    • master ✓
  • Tags (1)
    • v0.0100
Sending Request…
Enable Donations

Pledgie Donations

Once activated, we'll place the following badge in your repository's detail box:
Pledgie_example
This service is courtesy of Pledgie.

Add Devel::Declare sugar to Test::Class — Read more

  cancel

  cancel
  • Private
  • Read-Only
  • HTTP Read-Only

This URL has Read+Write access

Added thanks to NET-A-PORTER for sponsoring Joel's work 
pdcawley (author)
Mon Nov 09 15:04:51 -0800 2009
commit  2118e28fa4bc760402626e2b59cf22d1c205e03f
tree    b355fd5896a21933178f65109a79d640889251c9
parent  83d89b3ddb4b430d7e44e6898d01b8e204ec1038
test-class-sugar /
name age
history
message
file .gitignore Wed Mar 11 04:29:30 -0700 2009 Initial import of very crappy library [pdcawley]
file LICENSE Fri Mar 13 23:32:10 -0700 2009 Started adding module paraphenalia [pdcawley]
file Makefile.PL Fri Nov 06 04:39:37 -0800 2009 remove uses of defined-or operator, permits T::... [Joel Bernstein]
file README.textile Sat Nov 07 02:43:42 -0800 2009 Tweaked README.textile to reflect the fact that... [pdcawley]
file TODO.pod Wed Apr 01 23:58:31 -0700 2009 Added a TODO.pod for missing features, outstand... [pdcawley]
directory lib/ Mon Nov 09 15:04:51 -0800 2009 Added thanks to NET-A-PORTER for sponsoring Joe... [pdcawley]
directory t/ Tue Jul 21 05:42:01 -0700 2009 I feel slightly dirty. Got rid of Modern::Perl ... [pdcawley]
README.textile

Test::Class::Sugar

Synopsis

Test::Class::Sugar is a declarative wrapper around Adrian Howard’s
Test::Class xUnit style Perl
testing library.

The idea is that, instead of writing:


package Test::Something;
use base qw/Test::Class/;

use Test::Most;

sub subject {
  'Something'
}

sub test_something : Test(3) {
  my $test = shift;
  is $test->current_method, 'test_something';
  is $test->subject, 'Something';
  isa_ok $test, 'Test::Something';
}

You will be able to write:


use Test::Class::Sugar;

testclass exercises Something {
  test something >> 3 {
    is $test->current_method, 'test_something';
    is $test->subject, 'Something';
    isa_ok $test, 'Test::Something';
  }
}
Blog | Support | Training | Contact | API | Status | Twitter | Help | Security
© 2010 GitHub Inc. All rights reserved. | Terms of Service | Privacy Policy
Powered by the Dedicated Servers and
Cloud Computing of Rackspace Hosting®
Dedicated Server