7 use Test::More tests => 6;
11 my $i = SomeModelClass->new;
13 throws_ok { $i->say_hello(); } qr/Validation failed/;
14 throws_ok { $i->say_hello({}); } qr/Validation failed/;
15 throws_ok { $i->say_hello({name => 'Fred'}); } qr/Validation failed/;
17 lives_ok { $r = $i->say_hello({type => 'say_hello', name => 'Fred'}); };
19 is_deeply($r, { type => 'say_hello_response', body => "Hello Fred" });