0
0
mirror of https://github.com/ezyang/htmlpurifier.git synced 2024-09-18 18:25:18 +00:00

Add text parameter to unit tests, forces text output.

Signed-off-by: Edward Z. Yang <edwardzyang@thewritingpot.com>
This commit is contained in:
Edward Z. Yang 2009-02-16 02:59:33 -05:00
parent 77f57aa264
commit 1d70929eba
2 changed files with 5 additions and 1 deletions

1
NEWS
View File

@ -23,6 +23,7 @@ NEWS ( CHANGELOG and HISTORY ) HTMLPurifier
Thanks Pierre Attar for reporting.
- Fix YouTube rendering problem on certain versions of Firefox.
- Fix CSSDefinition Printer problems with decorators
- Add text parameter to unit tests, forces text output
. Add verbose mode to command line test runner, use (--verbose)
. Turn on unit tests for UnitConverter
. Fix missing version number in configuration %Attr.DefaultImageAlt (added 3.2.0)

View File

@ -40,6 +40,7 @@ $AC['dry'] = false;
$AC['php'] = $php;
$AC['help'] = false;
$AC['verbose'] = false;
$AC['txt'] = false;
$AC['type'] = '';
$AC['disable-phpt'] = false;
@ -62,6 +63,7 @@ Allowed options:
--standalone
--file (-f) HTMLPurifier/NameOfTest.php
--xml
--txt
--dry
--php /path/to/php
--type ( htmlpurifier | configdoc | fstools | htmlt | vtest | phpt )
@ -100,7 +102,8 @@ require 'HTMLPurifier/Harness.php';
if ($AC['xml']) {
if (!SimpleReporter::inCli()) header('Content-Type: text/xml;charset=UTF-8');
$reporter = new XmlReporter();
} elseif (SimpleReporter::inCli()) {
} elseif (SimpleReporter::inCli() || $AC['txt']) {
if (!SimpleReporter::inCli()) header('Content-Type: text/plain;charset=UTF-8');
$reporter = new HTMLPurifier_SimpleTest_TextReporter($AC);
} else {
$reporter = new HTMLPurifier_SimpleTest_Reporter('UTF-8', $AC);