Skip to content

Commit

Permalink
fixed bug
Browse files Browse the repository at this point in the history
  • Loading branch information
nekokak committed Jan 18, 2012
1 parent baa375c commit 4de3afa
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions t/030_plugin/session/basic.t
Original file line number Diff line number Diff line change
Expand Up @@ -58,19 +58,20 @@ subtest 'test regenerate method' => sub {
done_testing;
};

my $res;
subtest 'test finalize method' => sub {
$c->res->status(200);
$c->session->finalize($c->res);
ok $c->res->cookies;
my $res = $c->res->finalize;
$res = $c->res->finalize;
is $res->[1]->[0], 'Set-Cookie';
done_testing;
};

subtest 'next request test' => sub {
my $prev_rquest_session_id = $c->session->{session_id};
my $env = +{
HTTP_COOKIE => $c->res->header('Set-Cookie'),
HTTP_COOKIE => $res->[1]->[1],
REQUEST_METHOD => 'GET',
SCRIPT_NAME => '/',
};
Expand Down

0 comments on commit 4de3afa

Please sign in to comment.