-if ((defined $ENV{PERL_DESTRUCT_LEVEL} and $ENV{PERL_DESTRUCT_LEVEL} >= 3)
- or eval "use Perl::Destruct::Level level => 3; 1") {
- diag 'Test global destruction';
-}
-
-# is($c, 0, 'magic destructor is called');
+eval q[
+ use lib 't/lib';
+ BEGIN { require Variable::Magic::TestDestroyRequired; }
+];
+is $@, '', 'wizard destruction at the end of BEGIN-time require doesn\'t panic';