diff options
author | Matt Farina <[email protected]> | 2014-05-15 10:23:49 -0400 |
---|---|---|
committer | Matt Farina <[email protected]> | 2014-05-15 10:23:49 -0400 |
commit | 692140c902df735c6de2aa0863a4334f585f5f95 (patch) | |
tree | 7b21e902caa5da544f6f386ae1bad7f5d0264c01 /test/HTML5/Parser/InstructionProcessorMock.php | |
parent | 08711d17ad0dc08626347da9f48b477e2c717925 (diff) | |
parent | 30aa8a64547d2f1770489133b96269e9d5907a9a (diff) |
Merge pull request #34 from goetas/prs-tests
Fixes the testing errors and makes the tests PSR compatible
Diffstat (limited to 'test/HTML5/Parser/InstructionProcessorMock.php')
-rw-r--r-- | test/HTML5/Parser/InstructionProcessorMock.php | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/test/HTML5/Parser/InstructionProcessorMock.php b/test/HTML5/Parser/InstructionProcessorMock.php new file mode 100644 index 0000000..86572c7 --- /dev/null +++ b/test/HTML5/Parser/InstructionProcessorMock.php @@ -0,0 +1,22 @@ +<?php +namespace HTML5\Tests\Parser; + +class InstructionProcessorMock implements \HTML5\InstructionProcessor { + + public $name = NULL; + public $data = NULL; + public $count = 0; + + public function process(\DOMElement $element, $name, $data) { + $this->name = $name; + $this->data = $data; + $this->count++; + + $div = $element->ownerDocument->createElement("div"); + $div->nodeValue = 'foo'; + + $element->appendChild($div); + + return $div; + } +}
\ No newline at end of file |