1b39c5158Smillert#!/usr/bin/perl -w
2b39c5158Smillert
3*256a93a4Safresh1use strict;
4*256a93a4Safresh1use warnings;
5*256a93a4Safresh1
6b39c5158SmillertBEGIN {
7b39c5158Smillert    unshift @INC, 't/lib';
8b39c5158Smillert}
9b39c5158Smillertchdir 't';
10b39c5158Smillert
11b39c5158Smillertuse Test::More tests => 7;
12b39c5158SmillertBEGIN { use_ok('ExtUtils::MM') }
13b39c5158Smillert
14b39c5158Smillert
15b39c5158Smillert### OS Flavor methods
16b39c5158Smillert
17b39c5158Smillertcan_ok( 'MM', 'os_flavor', 'os_flavor_is' );
18b39c5158Smillert
19b39c5158Smillert# Can't really know what the flavors are going to be, so we just
20b39c5158Smillert# make sure it returns something.
21b39c5158Smillertmy @flavors = MM->os_flavor;
22b39c5158Smillertok( @flavors,   'os_flavor() returned something' );
23b39c5158Smillert
24b39c5158Smillertok( MM->os_flavor_is($flavors[rand @flavors]),
25b39c5158Smillert                                          'os_flavor_is() one flavor' );
26b39c5158Smillertok( MM->os_flavor_is($flavors[rand @flavors], 'BogusOS'),
27b39c5158Smillert                                          '    many flavors' );
28b39c5158Smillertok( !MM->os_flavor_is('BogusOS'),        '    wrong flavor' );
29b39c5158Smillertok( !MM->os_flavor_is(),                 '    no flavor' );
30b39c5158Smillert
31