3 class XHTMLCompilerHarness
extends UnitTestCase
7 * Instances of the XHTMLCompiler and XHTMLCompiler_PHP mocks we
13 * The old XHTMLCompiler and XHTMLCompiler_PHP instances that are
14 * restored after testing.
16 protected $oldPhp, $oldXc;
19 $this->xc
= new XHTMLCompilerMock();
20 $this->php
= new XHTMLCompiler_PHPMock();
21 if (empty($this->oldPhp
) && empty($this->oldXc
)) {
22 $this->oldXc
= XHTMLCompiler
::getInstance();
23 $this->oldPhp
= XHTMLCompiler
::getPHPWrapper();
25 XHTMLCompiler
::setInstance($this->xc
);
26 XHTMLCompiler
::setPHPWrapper($this->php
);
30 XHTMLCompiler
::setInstance($this->oldXc
);
31 XHTMLCompiler
::setPHPWrapper($this->oldPhp
);