This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
No longer print experimental::isa warning (closes #18754)
[perl5.git] / lib / B / Deparse-core.t
index cdbd27c..48d23f7 100644 (file)
@@ -36,7 +36,6 @@ BEGIN {
 
 use strict;
 use Test::More;
-plan tests => 3904;
 
 use feature (sprintf(":%vd", $^V)); # to avoid relying on the feature
                                     # logic to add CORE::
@@ -82,20 +81,21 @@ sub testit {
         my $code_ref;
         if ($lexsub) {
             package lexsubtest;
-            no warnings 'experimental::lexical_subs', 'experimental::isa';
+            no warnings 'experimental::lexical_subs';
             use feature 'lexical_subs';
             no strict 'vars';
             $code = "sub { state sub $keyword; ${vars}() = $expr }";
             $code = "use feature 'isa';\n$code" if $keyword eq "isa";
+            $code = "use feature 'switch';\n$code" if $keyword eq "break";
             $code_ref = eval $code or die "$@ in $expr";
         }
         else {
             package test;
-            no warnings 'experimental::isa';
             use subs ();
             import subs $keyword;
             $code = "no strict 'vars'; sub { ${vars}() = $expr }";
             $code = "use feature 'isa';\n$code" if $keyword eq "isa";
+            $code = "use feature 'switch';\n$code" if $keyword eq "break";
             $code_ref = eval $code or die "$@ in $expr";
         }
 
@@ -362,9 +362,12 @@ my %not_tested = map { $_ => 1} qw(
     END
     INIT
     UNITCHECK
+    catch
     default
+    defer
     else
     elsif
+    finally
     for
     foreach
     format
@@ -381,6 +384,7 @@ my %not_tested = map { $_ => 1} qw(
     require
     s
     tr
+    try
     unless
     until
     use
@@ -430,6 +434,8 @@ SKIP:
     ok($pass, "sanity checks");
 }
 
+done_testing();
+
 __DATA__
 #
 # format:
@@ -635,7 +641,7 @@ sin              01    $
 sleep            01    -
 socket           4     p
 socketpair       5     p
-sort             @     p1+
+sort             12    p+
 # split handled specially
 # splice handled specially
 sprintf          123   p