Aozora2Epub
view release on metacpan or search on metacpan
use strict;
use warnings;
use utf8;
use Test::More;
use Test::Base;
use Aozora2Epub;
use Aozora2Epub::Gensym;
use lib qw/./;
use t::Util;
plan tests => 1 * blocks;
sub drop_nlsp {
my $s = shift;
$s =~ s/\n *//sg;
$s =~ s/\n$//sg;
$s;
}
t/gaiji-replace.t view on Meta::CPAN
use strict;
use warnings;
use utf8;
use Test::More;
use Test::Base;
use Aozora2Epub;
use Aozora2Epub::Gensym;
use lib qw/./;
use t::Util;
plan tests => 1 * blocks;
sub eval_unicode_notation {
my $s = shift;
$s =~ s|\\x\{([0-9a-fA-F]+)\}|chr(hex($1))|esg;
return $s;
}
t/gaiji-title-author.t view on Meta::CPAN
use strict;
use warnings;
use utf8;
use Test::More;
use Test::Base;
use Aozora2Epub::XHTML;
use lib qw/./;
use t::Util;
plan tests => 1 * blocks;
sub eval_unicode_notation {
my $s = shift;
$s =~ s|\\x\{([0-9a-fA-F]+)\}|chr(hex($1))|esg;
return $s;
}
t/okuzuke.t view on Meta::CPAN
use strict;
use warnings;
use utf8;
use Test::More;
use Test::Base;
use Aozora2Epub::XHTML;
use Aozora2Epub::Gensym;
use lib qw/./;
use t::Util;
sub drop_nlsp {
my $s = shift;
$s =~ s/\n *//sg;
$s =~ s/\n$//sg;
$s;
}
filters {
use strict;
use warnings;
use utf8;
use Test::More;
use Test::Base;
use Aozora2Epub;
use Aozora2Epub::Gensym;
use lib qw/./;
use t::Util;
sub drop_nlsp {
my $s = shift;
$s =~ s/\n *//sg;
$s;
}
filters {
html => 'chomp',
use strict;
use warnings;
use utf8;
use Test::More;
use Aozora2Epub;
use lib qw/./;
use xt::ZipDiff;
use t::Util;
use Path::Tiny;
use Aozora2Epub::Gensym;
{
local($Aozora2Epub::AOZORA_CARDS_URL) = 'xt/input';
local($Aozora2Epub::AOZORA_GAIJI_URL) = 'xt/input/gaiji/';
sub epub_eq {
xt/gappon.t view on Meta::CPAN
use strict;
use warnings;
use utf8;
use Test::More;
use Aozora2Epub;
use lib qw/./;
use xt::ZipDiff;
use t::Util;
use Path::Tiny;
use Aozora2Epub::Gensym;
{
local($Aozora2Epub::AOZORA_CARDS_URL) = 'xt/input';
local($Aozora2Epub::AOZORA_GAIJI_URL) = 'xt/input/gaiji/';
subtest "gappon" => sub {
use strict;
use warnings;
use utf8;
use Test::More;
use Aozora2Epub;
use Aozora2Epub::CachedGet;
use lib qw/./;
use t::Util;
use Path::Tiny;
plan skip_all => "LIVE_TEST not enabled" unless $ENV{LIVE_TEST};
sub dotest {
my ($url, $title, $author) = @_;
my $book = Aozora2Epub->new($url);
is $book->title, $title, "title $url";
( run in 0.311 second using v1.01-cache-2.11-cpan-3cd7ad12f66 )