Dancer2-Plugin-Routing
view release on metacpan or search on metacpan
t/01-base.t view on Meta::CPAN
131415161718192021222324252627282930313233}
use
t::lib::TestApp;
use
t::lib::TestAPI;
my
$app
= builder {
mount
'/'
=> t::lib::TestApp->to_app;
mount
'/api'
=> t::lib::TestAPI->to_app;
};
is(
ref
$app
,
"CODE"
,
"Got a code ref"
);
my
$moved
=
q~<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>Moved</title>
</head>
<body>
<p>This item has moved <a href="http://localhost/">here</a>.</p>
</body>
</html>
~
;
test_psgi
$app
,
sub
{
( run in 0.954 second using v1.01-cache-2.11-cpan-87723dcf8b7 )