1use strict;
2use Plack::Test;
3use Test::More;
4use HTTP::Request::Common;
5
6use Plack::Middleware::Lint;
7
8my @good = map { Plack::Middleware::Lint->wrap($_) } (
9    sub {
10        my $body = "abc";
11        utf8::upgrade($body);
12        return [ 200, [ "Content-Type", "text/plain;charset=utf-8"], [ $body ] ];
13    },
14);
15
16for my $app (@good) {
17    test_psgi $app, sub {
18        my $cb = shift;
19        my $res = $cb->(GET "/");
20        is $res->code, 200, $res->content;
21    };
22}
23
24done_testing;
25