From d1bab5d4a5ea4100803c871461c62744767c514b Mon Sep 17 00:00:00 2001 From: Jesse Luehrs Date: Mon, 19 Jul 2010 19:21:54 -0500 Subject: a few more tests --- t/extending/class.t | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) create mode 100755 t/extending/class.t (limited to 't/extending/class.t') diff --git a/t/extending/class.t b/t/extending/class.t new file mode 100755 index 0000000..194cf4c --- /dev/null +++ b/t/extending/class.t @@ -0,0 +1,24 @@ +#!/usr/bin/env perl +use strict; +use warnings; +use Test::More; +use lib 't/lib'; + +{ + package Foo; + use Moose; + use Command; + + sub foo { + } + + command bar => sub { + }; +} + +ok(Foo->meta->has_method('bar')); +is_deeply([Foo->meta->get_all_commands], [Foo->meta->get_method('bar')]); +ok(Foo->meta->has_command('bar')); +ok(!Foo->meta->has_command('foo')); + +done_testing; -- cgit v1.2.3-54-g00ecf