X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?p=p5sagit%2FDevel-Size.git;a=blobdiff_plain;f=t%2Fbasic.t;h=f337a5e1de5b9712480005bd23b618b2d66edc16;hp=b544ebf17a5d38a1a4dd6d976421559cafd1adf7;hb=00a70dfae49af9794176b7a836c5e9583e0bb398;hpb=a809d0e179c4fb1a2110cd5c14bb4074febcdad9 diff --git a/t/basic.t b/t/basic.t index b544ebf..f337a5e 100644 --- a/t/basic.t +++ b/t/basic.t @@ -118,7 +118,10 @@ foreach(['undef', total_size(undef)], my $before_size = total_size($uurk); my $before_length = length $uurk; cmp_ok($before_size, '>', $before_length, 'Size before is sane'); - $uurk =~ s/Perl //; + # As of 5.20.0, s/// doesn't trigger COW. + # Seems that formline is about the the only thing left that reliably calls + # sv_chop. See CPAN #95493, perl #122322 + formline '^<<<<~', $uurk; is(total_size($uurk), $before_size, "Size doesn't change because OOK is used"); cmp_ok(length $uurk, '<', $before_size, 'but string is shorter');