Commit | Line | Data |
fde8e43f |
1 | #!/usr/bin/perl |
2 | # This is automatically generated by author/import-moose-test.pl. |
3 | # DO NOT EDIT THIS FILE. ANY CHANGES WILL BE LOST!!! |
4 | use t::lib::MooseCompat; |
5 | |
6 | use strict; |
7 | use warnings; |
8 | |
9 | use Test::More; |
10 | |
11 | use Test::Requires { |
12 | 'Test::Output' => '0.01', # skip all if not installed |
13 | }; |
14 | |
15 | { |
16 | package ModdedNew; |
17 | use Mouse; |
18 | |
19 | before 'new' => sub { }; |
20 | } |
21 | |
22 | { |
23 | package Foo; |
24 | use Mouse; |
25 | |
26 | extends 'ModdedNew'; |
27 | |
28 | ::stderr_like( |
29 | sub { Foo->meta->make_immutable }, |
30 | qr/\QNot inlining 'new' for Foo since it has method modifiers which would be lost if it were inlined/, |
31 | 'got a warning that Foo may not have an inlined constructor' |
32 | ); |
33 | } |
34 | |
35 | done_testing; |