"Fossies" - the Fresh Open Source Software Archive

Member "Module-Build-0.4224/t/versions.t" (30 May 2017, 502 Bytes) of package /linux/privat/Module-Build-0.4224.tar.gz:


As a special service "Fossies" has tried to format the requested source page into HTML format using (guessed) Perl source code syntax highlighting (style: standard) with prefixed line numbers and code folding option. Alternatively you can here view or download the uninterpreted source code file.

    1 #!/usr/bin/perl -w
    2 
    3 use strict;
    4 use lib 't/lib';
    5 use MBTest tests => 2;
    6 
    7 blib_load('Module::Build');
    8 
    9 my $tmp = MBTest->tmpdir;
   10 
   11 use DistGen;
   12 my $dist = DistGen->new( dir => $tmp );
   13 $dist->regen;
   14 
   15 #########################
   16 
   17 my @mod = split( /::/, $dist->name );
   18 my $file = File::Spec->catfile( $dist->dirname, 'lib', @mod ) . '.pm';
   19 is( Module::Build->version_from_file( $file ), '0.01', 'version_from_file' );
   20 
   21 ok( Module::Build->compare_versions( '1.01_01', '>', '1.01' ), 'compare: 1.0_01 > 1.0' );