Changeset 768

Show
Ignore:
Timestamp:
05/17/06 19:13:21
Author:
miyagawa
Message:
  • Load tests from subdirectories as well
  • set config name as 'config' if it's loaded from non-file data
Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/plagger/Makefile.PL

    r764 r768  
    253253} 
    254254 
     255tests 't/*.t t/*/*.t t/*/*/*.t'; 
     256 
    255257auto_include; 
    256258auto_install; 
  • trunk/plagger/lib/Plagger.pm

    r766 r768  
    5454    $self->{conf}->{log} ||= { level => 'debug' }; 
    5555 
     56    no warnings 'redefine'; 
    5657    local *Plagger::context = sub { $self }; 
    5758 
     
    146147 
    147148    # use config filename as a base directory for cache 
    148     my $base = ( basename($config) =~ /^(.*?)\.yaml$/ )[0]
     149    my $base = ( basename($config) =~ /^(.*?)\.yaml$/ )[0] || 'config'
    149150    my $dir  = $base eq 'config' ? ".plagger" : ".plagger-$base"; 
    150151