summaryrefslogtreecommitdiff
path: root/ext
diff options
context:
space:
mode:
authorMarc Green <marcgreen@cpan.org>2011-06-28 07:55:33 -0400
committerMarc Green <marcgreen@cpan.org>2011-10-31 13:26:42 -0400
commit367d88894aa7f901de9fac379e8b42de07c076c4 (patch)
tree7adec786b9599631e6e5f1a0b668d9f491b3d4e1 /ext
parent7b7d94fd07e15987d4d1afb12a16b635c370a159 (diff)
downloadperl-367d88894aa7f901de9fac379e8b42de07c076c4.tar.gz
Add a test case
Diffstat (limited to 'ext')
-rw-r--r--ext/Pod-Html/t/htmldir5.pod15
-rw-r--r--ext/Pod-Html/t/htmldir5.t61
2 files changed, 76 insertions, 0 deletions
diff --git a/ext/Pod-Html/t/htmldir5.pod b/ext/Pod-Html/t/htmldir5.pod
new file mode 100644
index 0000000000..7b9be919ce
--- /dev/null
+++ b/ext/Pod-Html/t/htmldir5.pod
@@ -0,0 +1,15 @@
+=head1 NAME
+
+htmldir - Test --htmldir feature
+
+=head1 LINKS
+
+Normal text, a L<link> to nowhere,
+
+a link to L<perlvar>,
+
+L<htmlescp>,
+
+L<htmlfeature/Another Head 1>,
+
+and another L<htmlfeature/"Another Head 1">.
diff --git a/ext/Pod-Html/t/htmldir5.t b/ext/Pod-Html/t/htmldir5.t
new file mode 100644
index 0000000000..63d6b7a4bc
--- /dev/null
+++ b/ext/Pod-Html/t/htmldir5.t
@@ -0,0 +1,61 @@
+#!/usr/bin/perl -w # -*- perl -*-
+
+BEGIN {
+ require "t/pod2html-lib.pl";
+}
+
+use strict;
+use Test::More tests => 1;
+
+use Cwd;
+
+my $cwd = Cwd::cwd();
+
+convert_n_test("htmldir5", "test --htmldir and --htmlroot 5a",
+ "--podpath=t:test.lib",
+ "--podroot=$cwd",
+ "--htmldir=$cwd",
+ "--htmlroot=/",
+);
+
+__DATA__
+<?xml version="1.0" ?>
+<!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></title>
+<meta http-equiv="content-type" content="text/html; charset=utf-8" />
+<link rev="made" href="mailto:[PERLADMIN]" />
+</head>
+
+<body style="background-color: white">
+
+
+
+<ul id="index">
+ <li><a href="#NAME">NAME</a></li>
+ <li><a href="#LINKS">LINKS</a></li>
+</ul>
+
+<h1 id="NAME">NAME</h1>
+
+<p>htmldir - Test --htmldir feature</p>
+
+<h1 id="LINKS">LINKS</h1>
+
+<p>Normal text, a <a>link</a> to nowhere,</p>
+
+<p>a link to <a href="../test.lib/perlvar.html">perlvar</a>,</p>
+
+<p><a href="./htmlescp.html">htmlescp</a>,</p>
+
+<p><a href="./htmlfeature.html#Another-Head-1">&quot;Another Head 1&quot; in htmlfeature</a>,</p>
+
+<p>and another <a href="./htmlfeature.html#Another-Head-1">&quot;Another Head 1&quot; in htmlfeature</a>.</p>
+
+
+</body>
+
+</html>
+
+