X-Git-Url: http://git.vpit.fr/?a=blobdiff_plain;f=t%2Flib%2FScope%2FUpper%2FTestGenerator.pm;h=18ced2475f672c0380e48c08b9fe11c3228f3434;hb=fe22a6565e85581207e3f4222eae26bc268223e4;hp=af267870189e2a2f629a12d89c42266b8e6f3839;hpb=bac4fc46c2d48ce5db75de6c88e0983aeeedf865;p=perl%2Fmodules%2FScope-Upper.git diff --git a/t/lib/Scope/Upper/TestGenerator.pm b/t/lib/Scope/Upper/TestGenerator.pm index af26787..18ced24 100644 --- a/t/lib/Scope/Upper/TestGenerator.pm +++ b/t/lib/Scope/Upper/TestGenerator.pm @@ -25,6 +25,14 @@ my @blocks = ( [ 'eval q[', '];' ], ); +sub import { + if ($] >= 5.010001) { + push @blocks, [ 'given (1) {', '}' ]; + require feature; + feature->import('switch'); + } +} + @blocks = map [ map "$_\n", @$_ ], @blocks; sub _block {