-
-
Save yko/068b7ffe5cd281719cac to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/perl | |
use Test::More; | |
use Test::Mojo; | |
use Mojolicious::Lite; | |
plan tests => 3; | |
get '/' => sub { | |
my $c = shift; | |
my $async = $c->client->async; | |
$async->get('http://mojolicio.us' => | |
sub { pass "Mojolicious page fetched"; $c->render_text('Ok') }); | |
}; | |
my $t = Test::Mojo->new(app => app); | |
$t->get_ok('/')->content_is('Ok'); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment