1
0
mirror of https://github.com/ezyang/htmlpurifier.git synced 2025-08-31 09:31:48 +02:00

Release 2.0.0, merged in 1026 to HEAD.

git-svn-id: http://htmlpurifier.org/svnroot/htmlpurifier/branches/strict@1179 48356398-32a2-884e-a903-53898d9a118a
This commit is contained in:
Edward Z. Yang
2007-06-21 00:36:12 +00:00
parent c35eb3e95f
commit 0101311193
172 changed files with 7713 additions and 2520 deletions

View File

@@ -38,8 +38,11 @@ if ( is_string($GLOBALS['HTMLPurifierTest']['PEAR']) ) {
}
// initialize and load HTML Purifier
set_include_path('../library' . PATH_SEPARATOR . get_include_path());
require_once 'HTMLPurifier.php';
require_once '../library/HTMLPurifier.auto.php';
// setup special DefinitionCacheFactory decorator
$factory =& HTMLPurifier_DefinitionCacheFactory::instance();
$factory->addDecorator('Memory'); // since we deal with a lot of config objects
// load tests
$test_files = array();
@@ -61,19 +64,17 @@ if (isset($_GET['f']) && isset($test_file_lookup[$_GET['f']])) {
// we can't use addTestFile because SimpleTest chokes on E_STRICT warnings
if ($test_file = $GLOBALS['HTMLPurifierTest']['File']) {
$test = new GroupTest($test_file . ' - HTML Purifier');
$path = 'HTMLPurifier/' . $test_file;
require_once $path;
$test->addTestClass(path2class($path));
$test = new GroupTest($test_file);
require_once $test_file;
$test->addTestClass(path2class($test_file));
} else {
$test = new GroupTest('All Tests - HTML Purifier');
$test = new GroupTest('All Tests');
foreach ($test_files as $test_file) {
$path = 'HTMLPurifier/' . $test_file;
require_once $path;
$test->addTestClass(path2class($path));
require_once $test_file;
$test->addTestClass(path2class($test_file));
}
}