1
0
mirror of https://github.com/ezyang/htmlpurifier.git synced 2025-08-06 14:16:32 +02:00

[3.1.0] Make static ConfigSchema methods throw errors.

git-svn-id: http://htmlpurifier.org/svnroot/htmlpurifier/trunk@1571 48356398-32a2-884e-a903-53898d9a118a
This commit is contained in:
Edward Z. Yang
2008-02-20 00:37:08 +00:00
parent 6c9c8f2380
commit f2863557f5
2 changed files with 12 additions and 9 deletions

View File

@@ -7,13 +7,6 @@ class HTMLPurifier_DefinitionCacheTest extends HTMLPurifier_Harness
// using null subclass because parent is abstract
$cache = new HTMLPurifier_DefinitionCache_Null('Test');
$old_copy = HTMLPurifier_ConfigSchema::instance();
$o = new HTMLPurifier_ConfigSchema();
HTMLPurifier_ConfigSchema::instance($o);
HTMLPurifier_ConfigSchema::defineNamespace('Test', 'Test namespace');
HTMLPurifier_ConfigSchema::define('Test', 'DefinitionRev', 1, 'int', 'Definition revision.');
generate_mock_once('HTMLPurifier_Config');
$config = new HTMLPurifier_ConfigMock();
$config->version = '1.0.0'; // hopefully no conflicts
@@ -31,8 +24,6 @@ class HTMLPurifier_DefinitionCacheTest extends HTMLPurifier_Harness
$this->assertIdentical($cache->isOld('1.0.0-hash2-1', $config), false); // if hash is different, don't touch!
$this->assertIdentical($cache->isOld('1.0.0beta-hash2-11', $config), true);
HTMLPurifier_ConfigSchema::instance($old_copy);
}
}