summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAsmir Mustafic <[email protected]>2014-05-14 09:07:17 -0300
committerAsmir Mustafic <[email protected]>2014-05-14 09:07:17 -0300
commit208928c35004e73c684ec7858ad8d8858d6d68c2 (patch)
tree9848814e41a19595b67d1f489bfaf05298a0734b
parent0e278f75b5dcd72882977198b26138f7ca347922 (diff)
Moved some class in separate files
-rw-r--r--test/HTML5/Parser/EventStackError.php5
-rw-r--r--test/HTML5/Parser/InstructionProcessorMock.php22
2 files changed, 27 insertions, 0 deletions
diff --git a/test/HTML5/Parser/EventStackError.php b/test/HTML5/Parser/EventStackError.php
new file mode 100644
index 0000000..8465b33
--- /dev/null
+++ b/test/HTML5/Parser/EventStackError.php
@@ -0,0 +1,5 @@
+<?php
+namespace HTML5\Tests\Parser;
+
+class EventStackParseError extends \Exception {
+}
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