]> git.vpit.fr Git - perl/modules/Variable-Magic.git/blobdiff - t/30-scalar.t
Update VPIT::TestHelpers to e8344578
[perl/modules/Variable-Magic.git] / t / 30-scalar.t
index bc9004f0fc6628a20a6727193c58b149e501d34c..59ab5e576a645685e596c8310b0581fc5fd0c22a 100644 (file)
@@ -7,6 +7,9 @@ use Config qw<%Config>;
 
 use Test::More tests => (2 * 14 + 2) + 2 * (2 * 8 + 4) + 5 + 1;
 
+use lib 't/lib';
+use VPIT::TestHelpers;
+
 use Variable::Magic qw<wizard cast dispell>;
 
 use lib 't/lib';
@@ -72,7 +75,7 @@ $b = watch { exists $a[1] } { }, 'array element: exists';
 is $b, 1, 'scalar: array element: exists correctly';
 
 # $b has to be set inside the block for the test to pass on 5.8.3 and lower
-watch { $b = delete $a[1] } { get => 1, free => ("$]" > 5.008005 ? 1 : 0) },
+watch { $b = delete $a[1] } { get => 1, free => ("$]" > 5.008_005 ? 1 : 0) },
                             'array element: delete';
 is $b, 6, 'scalar: array element: delete correctly';
 
@@ -103,10 +106,7 @@ is $b, 6, 'scalar: hash element: delete correctly';
 watch { $h{b} = 4 } { }, 'hash element: set after delete';
 
 SKIP: {
- unless (do { local $@; eval { require Tie::Array; 1 } }) {
-  skip 'Tie::Array required to test clear magic on tied array values' => 5;
- }
- defined and diag "Using Tie::Array $_" for $Tie::Array::VERSION;
+ load_or_skip('Tie::Array', undef, undef, 5);
 
  tie my @a, 'Tie::StdArray';
  $a[0] = $$;