mirror of
https://github.com/ezyang/htmlpurifier.git
synced 2024-12-22 16:31:53 +00:00
Move classes into Zend style setup.
git-svn-id: http://htmlpurifier.org/svnroot/htmlpurifier/trunk@88 48356398-32a2-884e-a903-53898d9a118a
This commit is contained in:
parent
758e70dd94
commit
1ab3ae160a
@ -1,7 +1,7 @@
|
||||
<?php
|
||||
|
||||
// emulates inserting a dir called HTMLPurifier into your class dir
|
||||
set_include_path(get_include_path() . PATH_SEPARATOR . '../../');
|
||||
set_include_path(get_include_path() . PATH_SEPARATOR . '../library/');
|
||||
|
||||
require_once 'HTMLPurifier/Lexer/DirectLex.php';
|
||||
require_once 'HTMLPurifier/Lexer/PEARSax3.php';
|
||||
|
@ -1,16 +0,0 @@
|
||||
<?php
|
||||
|
||||
require_once 'HTMLPurifier/HTMLPurifier.php';
|
||||
|
||||
class Test_HTMLPurifier extends UnitTestCase
|
||||
{
|
||||
|
||||
function Test_HTMLPurifier() {
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
?>
|
@ -4,13 +4,13 @@ require_once 'HTMLPurifier/ChildDef.php';
|
||||
require_once 'HTMLPurifier/Lexer.php';
|
||||
require_once 'HTMLPurifier/Generator.php';
|
||||
|
||||
class Test_HTMLPurifier_ChildDef extends UnitTestCase
|
||||
class HTMLPurifier_ChildDefTest extends UnitTestCase
|
||||
{
|
||||
|
||||
var $lex;
|
||||
var $gen;
|
||||
|
||||
function Test_HTMLPurifier_ChildDef() {
|
||||
function HTMLPurifier_ChildDefTest() {
|
||||
$this->lex = HTMLPurifier_Lexer::create();
|
||||
$this->gen = new HTMLPurifier_Generator();
|
||||
parent::UnitTestCase();
|
@ -3,12 +3,12 @@
|
||||
require_once 'HTMLPurifier/Definition.php';
|
||||
require_once 'HTMLPurifier/Lexer.php';
|
||||
|
||||
class Test_HTMLPurifier_Definition extends UnitTestCase
|
||||
class HTMLPurifier_DefinitionTest extends UnitTestCase
|
||||
{
|
||||
|
||||
var $def, $lex;
|
||||
|
||||
function Test_HTMLPurifier_Definition() {
|
||||
function HTMLPurifier_DefinitionTest() {
|
||||
$this->UnitTestCase();
|
||||
$this->def = new HTMLPurifier_Definition();
|
||||
$this->def->loadData();
|
@ -2,12 +2,12 @@
|
||||
|
||||
require_once 'HTMLPurifier/Generator.php';
|
||||
|
||||
class Test_HTMLPurifier_Generator extends UnitTestCase
|
||||
class HTMLPurifier_GeneratorTest extends UnitTestCase
|
||||
{
|
||||
|
||||
var $gen;
|
||||
|
||||
function Test_HTMLPurifier_Generator() {
|
||||
function HTMLPurifier_GeneratorTest() {
|
||||
$this->UnitTestCase();
|
||||
$this->gen = new HTMLPurifier_Generator();
|
||||
}
|
@ -3,7 +3,7 @@
|
||||
require_once 'HTMLPurifier/Lexer/DirectLex.php';
|
||||
require_once 'HTMLPurifier/Lexer/PEARSax3.php';
|
||||
|
||||
class Test_HTMLPurifier_Lexer extends UnitTestCase
|
||||
class HTMLPurifier_LexerTest extends UnitTestCase
|
||||
{
|
||||
|
||||
var $DirectLex, $PEARSax3, $DOMLex;
|
16
tests/HTMLPurifierTest.php
Normal file
16
tests/HTMLPurifierTest.php
Normal file
@ -0,0 +1,16 @@
|
||||
<?php
|
||||
|
||||
require_once 'HTMLPurifier.php';
|
||||
|
||||
class HTMLPurifierTest extends UnitTestCase
|
||||
{
|
||||
|
||||
function HTMLPurifierTest() {
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
?>
|
@ -3,16 +3,16 @@
|
||||
load_simpletest(); // includes all relevant simpletest files
|
||||
|
||||
// emulates inserting a dir called HTMLPurifier into your class dir
|
||||
set_include_path(get_include_path() . PATH_SEPARATOR . '../../');
|
||||
set_include_path(get_include_path() . PATH_SEPARATOR . '../library');
|
||||
|
||||
$test = new GroupTest('HTMLPurifier');
|
||||
|
||||
$test->addTestFile('HTMLPurifier.php');
|
||||
$test->addTestFile('Lexer.php');
|
||||
//$test->addTestFile('Token.php');
|
||||
$test->addTestFile('Definition.php');
|
||||
$test->addTestFile('ChildDef.php');
|
||||
$test->addTestFile('Generator.php');
|
||||
$test->addTestFile('HTMLPurifierTest.php');
|
||||
$test->addTestFile('HTMLPurifier/LexerTest.php');
|
||||
//$test->addTestFile('TokenTest.php');
|
||||
$test->addTestFile('HTMLPurifier/DefinitionTest.php');
|
||||
$test->addTestFile('HTMLPurifier/ChildDefTest.php');
|
||||
$test->addTestFile('HTMLPurifier/GeneratorTest.php');
|
||||
|
||||
$test->run( new HtmlReporter() );
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user