Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Fetching contributors…

Cannot retrieve contributors at this time

43 lines (31 sloc) 0.72 kb
#!/usr/bin/env perl
use strict; use warnings;
use Test::More tests => 7;
use Test::Moose;
{
package Rollo;
use MooseX::POE::Role;
sub foo { ::pass('foo!')}
event yarr => sub { ::pass("yarr!"); shift->yield('matey'); };
event matey => sub { ::pass("matey!") };
}
{
package App;
use MooseX::POE;
with qw(Rollo);
sub START {
my ($self) = $_[OBJECT];
::pass('START');
$self->foo();
$self->yield('next');
}
event next => sub {
my ($self) = $_[OBJECT];
::pass('next');
$self->yield("yarr");
};
sub STOP { ::pass('STOP') }
}
my $obj = App->new;
does_ok($obj, 'Rollo');
POE::Kernel->run;
Jump to Line
Something went wrong with that request. Please try again.