diff options
Diffstat (limited to 'cpan/ExtUtils-MakeMaker/t/writemakefile_args.t')
-rw-r--r-- | cpan/ExtUtils-MakeMaker/t/writemakefile_args.t | 31 |
1 files changed, 29 insertions, 2 deletions
diff --git a/cpan/ExtUtils-MakeMaker/t/writemakefile_args.t b/cpan/ExtUtils-MakeMaker/t/writemakefile_args.t index 10913b9f37..421a311c18 100644 --- a/cpan/ExtUtils-MakeMaker/t/writemakefile_args.t +++ b/cpan/ExtUtils-MakeMaker/t/writemakefile_args.t @@ -8,7 +8,7 @@ BEGIN { } use strict; -use Test::More tests => 35; +use Test::More tests => 39; use TieOut; use MakeMaker::Test::Utils; @@ -61,7 +61,7 @@ VERIFY }; is( $warnings, <<VERIFY ); -WARNING: AUTHOR takes a string/number not a CODE reference. +WARNING: AUTHOR takes a ARRAY reference not a CODE reference. Please inform the author. VERIFY @@ -212,4 +212,31 @@ VERIFY }; is( $warnings, '' ); is( $mm->{DISTVNAME}, 'Hooballoo' ); + + + # AUTHOR / scalar + $warnings = ''; + eval { + $mm = WriteMakefile( + NAME => 'Big::Dummy', + VERSION => '1.00', + AUTHOR => "test", + ); + }; + is( $warnings, '' ); + is_deeply( $mm->{AUTHOR}, ["test"] ); + + + # AUTHOR / array + $warnings = ''; + eval { + $mm = WriteMakefile( + NAME => 'Big::Dummy', + VERSION => '1.00', + AUTHOR => ["test1", "test2"], + ); + }; + is( $warnings, '' ); + is_deeply( $mm->{AUTHOR}, ["test1","test2"] ); + } |