From 45b7adbc33de665ce8b238d897c8da7c63e8db8a Mon Sep 17 00:00:00 2001 From: Mike Doherty Date: Sat, 6 Apr 2013 21:05:25 -0300 Subject: [PATCH] Add a more accurately-named alias: Acme::Noose --- lib/Acme/Noose.pm | 20 ++++++++++++++++++++ t/06-acme.t | 19 +++++++++++++++++++ 2 files changed, 39 insertions(+) create mode 100644 lib/Acme/Noose.pm create mode 100644 t/06-acme.t diff --git a/lib/Acme/Noose.pm b/lib/Acme/Noose.pm new file mode 100644 index 0000000..bff1797 --- /dev/null +++ b/lib/Acme/Noose.pm @@ -0,0 +1,20 @@ +package Acme::Noose; +use strict; +use warnings; +# ABSTRACT: just enough object orientation to hang yourself +# VERSION + +use Noose (); +BEGIN { + *Acme::Noose:: = \%Noose::; +} + +=head1 DESCRIPTION + +This is simply a (more accurately named) alias of L. + +=for Pod::Coverage new + +=cut + +1; diff --git a/t/06-acme.t b/t/06-acme.t new file mode 100644 index 0000000..abf44b0 --- /dev/null +++ b/t/06-acme.t @@ -0,0 +1,19 @@ +use strict; +use warnings; + +package Thing; +use Acme::Noose; +sub exclaim { + my $self = shift; + die 'BLARGH' unless $self->a == 1; + return "yepyepyep\n"; +} + +package main; +use Test::More tests => 4; + +my $thing = new_ok Thing => [a => 1]; +can_ok $thing, qw/ new exclaim a /; +is $thing->a => 1; +is $thing->exclaim => "yepyepyep\n"; +