Skip to content

Commit

Permalink
Item14152: Recommitting incorrectly resolved conflict.
Browse files Browse the repository at this point in the history
  • Loading branch information
vrurg committed Dec 16, 2016
1 parent 6dccd69 commit 6e53a93
Showing 1 changed file with 16 additions and 5 deletions.
21 changes: 16 additions & 5 deletions UnitTestContrib/lib/Unit/TestApp.pm
Expand Up @@ -79,11 +79,19 @@ has engineParams => (
default => sub { {} },
);

# cfgParams hash is used to initialize a new cfg object.
=begin TML
---++ ObjectAttribute cfgParams -> hash
This is a hash of parameters to be passed over to =Foswiki::Config=
constructor.
=cut

has cfgParams => (
is => 'rw',
lazy => 1,
default => sub { {} },
builder => 'prepareCfgParams',
);

=begin TML
Expand All @@ -96,14 +104,14 @@ respective callbacks. Each handler =data= parameter is a hash whith the only
key =app= containing reference to the application object.
=cut

has callbacks => (
is => 'rw',
lazy => 1,
predicate => 1,
isa => Foswiki::Object::isaHASH('callbacks'),
default => sub { {} },
);

has _cbRegistered => (
is => 'rw',
default => 0,
Expand Down Expand Up @@ -196,8 +204,7 @@ around _prepareConfig => sub {
my $orig = shift;
my $this = shift;

my $cfg = $this->create( 'Foswiki::Config', %{ $this->cfgParams } );
return $cfg;
return $this->create( 'Foswiki::Config', %{ $this->cfgParams }, );
};

around handleRequest => sub {
Expand All @@ -219,6 +226,10 @@ around handleRequest => sub {
return $rc;
};

sub prepareCfgParams {
return {};
}

=begin TML
---++ Examples
Expand Down

0 comments on commit 6e53a93

Please sign in to comment.