AnyEvent-Net-Curl-Queued

 view release on metacpan or  search on metacpan

t/43-loopback-yada.t  view on Meta::CPAN

                        header
                        initial_url
                    ));

                    is($self->final_url, $url, 'initial/final URLs match');
                    is(0 + $result, 0, 'got CURLE_OK');
                    ok(!$self->has_error, "libcurl message: '$result'");

                    like(${$self->data}, qr{\bContent-Type:\s*application/json\b}ix, 'got data: ' . ${$self->data});
                    like(${$self->data}, qr{\bUser-Agent\s*:\s*\Q$ua_string\E\b}sx, 'got User-Agent tag');
                    like(${$self->data}, qr{\bCookie\s*:\s*time=\d+\b}sx, 'got Cookie tag');
                },
            )
        });
    }

    my $json_string = qq({ "word": "ímã", "j": $j, "seed": @{[ rand ]} });
    my $json_hash = { word => "ímã", j => $j, seed => rand };
    for my $post (
        $json_string,
        encode_utf8($json_string) . "\n",           # whitespace padding hack



( run in 0.712 second using v1.01-cache-2.11-cpan-e9199f4ba4c )