Make extensions in ext run their tests from the extension's own directory.
[p5sagit/p5-mst-13.2.git] / ext / XS-APItest / t / op.t
CommitLineData
d8c5b3c5 1#!perl -w
2
3BEGIN {
d8c5b3c5 4 push @INC, "::lib:$MacPerl::Architecture:" if $^O eq 'MacOS';
5 require Config; import Config;
6 if ($Config{'extensions'} !~ /\bXS\/APItest\b/) {
7 # Look, I'm using this fully-qualified variable more than once!
8 my $arch = $MacPerl::Architecture;
9 print "1..0 # Skip: XS::APItest was not built\n";
10 exit 0;
11 }
9568a123 12 if ($] < 5.009) {
13 print "1..0 # Skip: hints hash not present before 5.10.0\n";
14 exit 0;
15 }
d8c5b3c5 16}
17
18use strict;
19use utf8;
20use Test::More 'no_plan';
21
22use_ok('XS::APItest');
23
24*hint_exists = *hint_exists = \&XS::APItest::Hash::refcounted_he_exists;
25*hint_fetch = *hint_fetch = \&XS::APItest::Hash::refcounted_he_fetch;
26
2adbc9b6 27require '../../t/op/caller.pl';