Skip to content

Commit

Permalink
t/Plack-Request/cookie.t: add documentation to some of the trickier t…
Browse files Browse the repository at this point in the history
…ests

Change the t/Plack-Request/cookie.t tests to use three-arg is() for
the undef tests and the multi-cookie test.
  • Loading branch information
avar committed Sep 21, 2012
1 parent 8129630 commit 8b6b245
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions t/Plack-Request/cookie.t
Original file line number Original file line Diff line number Diff line change
Expand Up @@ -8,11 +8,11 @@ use Plack::Request;
my $app = sub { my $app = sub {
my $req = Plack::Request->new(shift); my $req = Plack::Request->new(shift);


is $req->cookies->{undef}, undef; is $req->cookies->{undef}, undef, "non-existing keys return undef";
is $req->cookies->{Foo}, 'Bar'; is $req->cookies->{Foo}, 'Bar';
is $req->cookies->{Bar}, 'Baz'; is $req->cookies->{Bar}, 'Baz';
is $req->cookies->{XXX}, 'Foo Bar'; is $req->cookies->{XXX}, 'Foo Bar';
is $req->cookies->{YYY}, 0; is $req->cookies->{YYY}, 0, "When we get multiple values we return the first one (which e.g. Apache does too)";


$req->new_response(200)->finalize; $req->new_response(200)->finalize;
}; };
Expand Down

0 comments on commit 8b6b245

Please sign in to comment.