projects
/
gitmo/Moose.git
/ blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
history
|
raw
|
HEAD
Skip DBIx-PgLink, it prompts for a password
[gitmo/Moose.git]
/
t
/
bugs
/
native_trait_handles_bad_value.t
1
use strict;
2
use warnings;
3
4
use Test::More;
5
use Test::Fatal;
6
7
{
8
9
package Bug;
10
use Moose;
11
12
::like(
13
::exception{ has member => (
14
is => 'ro',
15
isa => 'HashRef',
16
traits => ['Hash'],
17
handles => {
18
method => sub { }
19
},
20
);
21
},
22
qr/\QAll values passed to handles must be strings or ARRAY references, not CODE/,
23
'bad value in handles throws a useful error'
24
);
25
}
26
27
done_testing;