Skip to content

Commit

Permalink
Test .subst complains when it can't use $/
Browse files Browse the repository at this point in the history
  • Loading branch information
zoffixznet committed Oct 21, 2017
1 parent 9585230 commit 80a49c4
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion S32-str/substr.t
Expand Up @@ -3,7 +3,7 @@ use lib <t/spec/packages>;
use Test;
use Test::Util;

plan 60;
plan 61;

# L<S32::Str/Str/=item substr>

Expand Down Expand Up @@ -132,4 +132,8 @@ fails-like { "".substr: 5 }, X::OutOfRange,
# RT #122789
lives-ok { BEGIN "a".subst: /a/, "b" }, '.subst in BEGIN does not die';

# RT #126721
throws-like { $/ := "Uhoh"; put "Foo".subst: /Foo/, {$/} }, X::Assignment::RO,
'.subst complains when it cannot write to $/';

# vim: ft=perl6

0 comments on commit 80a49c4

Please sign in to comment.