Permalink
Browse files

t/Plack-Request/cookie.t: add documentation to some of the trickier t…

…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...
1 parent 8129630 commit 8b6b24518f4fa4ffb52459fa7aa7a64906902cd7 @avar committed Sep 21, 2012
Showing with 2 additions and 2 deletions.
  1. +2 −2 t/Plack-Request/cookie.t
View
@@ -8,11 +8,11 @@ use Plack::Request;
my $app = sub {
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->{Bar}, 'Baz';
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;
};

0 comments on commit 8b6b245

Please sign in to comment.