# This file documents the revision history for Perl extension Catalyst.
+ - Fix calling use Catalyst::Test 'MyApp' 'foo' which used to work,
+ but stopped as the 2nd parameter can be an options hash now (t0m)
- Bump Moose dependency to fix make_immutable bug (t0m)
- Use compile time extends in Catalyst::Controller (t0m)
- Make Catalyst::Request::uploads attribute non-lazy, to fix
sub import {
my ($self, $class, $opts) = @_;
$import->($self, '-all' => { class => $class });
- $opts ||= {};
+ $opts = {} unless ref $opts eq 'HASH';
$default_host = $opts->{default_host} if exists $opts->{default_host};
}
}
use warnings;
use Test::More;
+use FindBin qw/$Bin/;
+use lib "$Bin/lib";
use Catalyst::Utils;
-plan tests => 8;
+plan tests => 9;
use_ok('Catalyst::Test');
customize( $req, { host => '' } );
is( $req->header('Host'), undef, 'default value can be temporarily cleared via opts hash' );
}
+
+# Back compat test, extra args used to be ignored, now a hashref of options.
+use_ok('Catalyst::Test', 'TestApp', 'foobar');