summaryrefslogtreecommitdiff
path: root/dist/ExtUtils-ParseXS/t/101-standard_typemap_locations.t
blob: e9e7e59650ebead702496d05781a8f434adf7c2d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
#!/usr/bin/perl
use strict;
use warnings;
use Test::More tests =>  3;
use lib qw( lib );
use ExtUtils::ParseXS::Utilities qw(
  standard_typemap_locations
);

{
    local @INC = @INC;
    my @stl = standard_typemap_locations( \@INC );
    ok( @stl >= 9, "At least 9 entries in typemap locations list" );
    is( $stl[$#stl], 'typemap',
        "Last element is typemap in current directory");
    SKIP: {
        skip "No lib/ExtUtils/ directories under directories in \@INC",
        1
        unless @stl > 9;
        ok( -f $stl[-10],
            "At least one typemap file exists underneath \@INC directories"
        );
    }
}