sub eval-dies-ok

Documentation for sub eval-dies-ok assembled from the following types:

class Test

From Test

(Test) sub eval-dies-ok

Defined as:

multi sub eval-dies-ok(Str $code$reason = '')

Marks a test as passed if the given $string throws an exception when evaled as code.

The function accepts an optional description of the test.

eval-dies-ok q[my $joffrey = "nasty";
               die "bye bye Ned" if $joffrey ~~ /nasty/],
    "Ned Stark dies";