0
0
mirror of https://github.com/ezyang/htmlpurifier.git synced 2024-12-22 08:21:52 +00:00

Sync with SimpleTest codebase

git-svn-id: http://htmlpurifier.org/svnroot/htmlpurifier/trunk@1701 48356398-32a2-884e-a903-53898d9a118a
This commit is contained in:
Edward Z. Yang 2008-04-28 19:52:13 +00:00
parent 4b862f64e6
commit aaf6ba421c

View File

@ -12,8 +12,8 @@ class HTMLPurifier_ErrorCollectorEMock extends HTMLPurifier_ErrorCollectorMock
private $_expected_context = array();
private $_expected_context_at = array();
public function prepare(&$context) {
$this->_context =& $context;
public function prepare($context) {
$this->_context = $context;
}
public function expectContext($key, $value) {
@ -27,13 +27,7 @@ class HTMLPurifier_ErrorCollectorEMock extends HTMLPurifier_ErrorCollectorMock
// test for context
$context = SimpleTest::getContext();
$test = $context->getTest();
// compat
if (empty($this->_mock)) {
$mock = $this;
} else {
$mock = $this->_mock;
}
$mock = $this->mock;
foreach ($this->_expected_context as $key => $value) {
$test->assertEqual($value, $this->_context->get($key));