562c54f6d17f50e83d9dd8683097a604f6cc2d72
[gitmo/MooseX-ConfigFromFile.git] / t / 04a_getopt.t
1 use strict;
2 use warnings FATAL => 'all';
3
4 use Test::More tests => 2;
5 use Test::Warnings;
6
7 use Test::Without::Module 'MooseX::Getopt';
8
9 {
10     package Foo::NoOptions;
11
12     use Moose;
13     with qw(MooseX::ConfigFromFile);
14     sub get_config_from_file { }
15 }
16
17 ok(
18     !Foo::NoOptions->meta->find_attribute_by_name('configfile')->does('MooseX::Getopt::Meta::Attribute::Trait'),
19     'the Getopt attr trait is not added if not installed',
20 );
21