summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohn Coggeshall <john@php.net>2004-01-14 06:57:23 +0000
committerJohn Coggeshall <john@php.net>2004-01-14 06:57:23 +0000
commita06377c32db5f3dc6dd383249ddeb23d3ba33119 (patch)
tree57f58f6c2a72066a35823e29108ba80b84d87f0d
parent31f7699a857534d24990b1c7d5e06ed81e85ad9b (diff)
downloadphp-git-a06377c32db5f3dc6dd383249ddeb23d3ba33119.tar.gz
Forgot to add these tests
-rw-r--r--ext/tidy/tests/016.html1
-rw-r--r--ext/tidy/tests/016.phpt27
-rw-r--r--ext/tidy/tests/016.tcfg1
-rw-r--r--ext/tidy/tests/017.phpt20
4 files changed, 49 insertions, 0 deletions
diff --git a/ext/tidy/tests/016.html b/ext/tidy/tests/016.html
new file mode 100644
index 0000000000..7dc6e4aba8
--- /dev/null
+++ b/ext/tidy/tests/016.html
@@ -0,0 +1 @@
+<P><B><FONT SIZE=10 COLOR=#FF0000>testing</FONT></I></P>
diff --git a/ext/tidy/tests/016.phpt b/ext/tidy/tests/016.phpt
new file mode 100644
index 0000000000..1b0fa1e38f
--- /dev/null
+++ b/ext/tidy/tests/016.phpt
@@ -0,0 +1,27 @@
+--TEST--
+Passing configuration file through tidy_parse_file()
+--SKIPIF--
+<?php if (!extension_loaded("tidy")) print "skip"; ?>
+--POST--
+--GET--
+--INI--
+--FILE--
+<?php
+ $tidy = tidy_parse_file("ext/tidy/tests/016.html", "ext/tidy/tests/016.tcfg");
+ tidy_clean_repair($tidy);
+ echo tidy_get_output($tidy);
+?>
+--EXPECT--
+<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 3.2//EN">
+<html>
+<head>
+<title></title>
+
+<style type="text/css">
+ p.c1 {font-weight: bold}
+</style>
+</head>
+<body>
+<p class="c1">testing</p>
+</body>
+</html>
diff --git a/ext/tidy/tests/016.tcfg b/ext/tidy/tests/016.tcfg
new file mode 100644
index 0000000000..fd6e4e44f4
--- /dev/null
+++ b/ext/tidy/tests/016.tcfg
@@ -0,0 +1 @@
+clean: yes
diff --git a/ext/tidy/tests/017.phpt b/ext/tidy/tests/017.phpt
new file mode 100644
index 0000000000..893e902f19
--- /dev/null
+++ b/ext/tidy/tests/017.phpt
@@ -0,0 +1,20 @@
+--TEST--
+The Tidy Output Buffer Filter
+--SKIPIF--
+<?php if (!extension_loaded("tidy")) print "skip"; ?>
+--POST--
+--GET--
+--INI--
+--FILE--
+<?php ob_start("ob_tidyhandler"); ?>
+<B>testing</I>
+--EXPECT--
+<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 3.2//EN">
+<html>
+<head>
+<title></title>
+</head>
+<body>
+<b>testing</b>
+</body>
+</html> \ No newline at end of file