d434be7e178e17cf7aa1139a40e3cfc801be6823
[p5sagit/Function-Parameters.git] / t / foreign / MooseX-Method-Signatures / caller.t
1 use strict;
2 use warnings FATAL => 'all';
3 use Test::More tests => 1;
4
5 {
6     package TestClass;
7
8     use Function::Parameters qw(:strict);
9
10     use Carp ();
11
12     method callstack_inner($class:) {
13         return Carp::longmess("Callstack is");
14     }
15
16     method callstack($class:) {
17         return $class->callstack_inner;
18     }
19 }
20
21 my $callstack = TestClass->callstack();
22
23 unlike $callstack, qr/Test::Class::.*?__ANON__/, "No anon methods in call chain";