Commit Graph

29 Commits

Author SHA1 Message Date
iska c524b25051 Add HTML5 Lib's test detail message to all assertions in the Tree Construction tests 2015-04-12 19:35:53 +02:00
iska 0911e46dba Add HTMLKit Parser Performance test
This tests measures the parsing time of the HTML Living Standard page, about 8.1MB in
size (as of 23 October 2014)
2015-04-12 18:33:01 +02:00
iska 4158ef0237 Use a accumulator-character-token in the tokenizer to reduce the initialization overhead
Initializing character tokens, and the NSString objects they use, results in a relatively high overhead. The tokenizer
now accumulated all successive characters in on accumulator token until a non-character token is emitted.

This change reduces the execution time of the performance test on the local machine by 48% (reference to baseline)
2015-04-11 22:12:51 +02:00
iska 936c76d142 Remove the superfluous allObjects method from the tokenizer class
Being a NSEnumerator, the tokenizer cannot be reset, hence the change in the tests to create a new
instance for each iteration.
2015-04-11 21:47:55 +02:00
iska 8bfccb124f Use the debug description for Tree Construction tests which dumps a tree structure 2015-04-11 21:44:40 +02:00
iska 0ac909fb66 Add HTML5 Lib Tree Construction tests
https://github.com/html5lib/html5lib-tests
2015-04-11 00:51:37 +02:00
iska 83c9841122 Add implementation for HTML Node Tree Enumerator
Tree-Order (pre-order) enumeration for HTML Node and its descendants
2015-03-29 00:00:01 +01:00
iska 3b4970202d Move Tokenizer tests loading into the helper HTML5Lib Tokenizer Test class
Helps keeping the test-case class uncluttered
2015-03-25 23:01:42 +01:00
iska 7fb04f3394 Refactor Tokenizer tests into separate group and generate the test cases dynamically
Instead of loading and running the HTML5Lib test files manually, the Xcode test cases are generated
on start for all the HTML5Lib tokenizer tests. Also, the performance test is moved into its own class.

This setup shouldn't require any extra maintenance when HTML5Lib adds new tokenizer test cases.
2015-03-24 23:50:19 +01:00
iska 90cbccbc16 Remove NSFastEnumeration for the Tokenizer and subclass the NSEnumerator instead
Memory management tends to be a bit complex in this case, especially under ARC, hence the
change to prevent a headache
2015-03-22 00:12:38 +01:00
iska 352b34b76c Update html5lib-tests submodule to the latest commit as of 2015.03.16
Commit SHA-1: e633ddfeb0180f71238763576b1f5fdd26a7038f
2015-03-16 01:16:45 +01:00
iska a7b526dc14 Restore the EOF Token and emit it in the tokenizer 2015-03-16 00:17:11 +01:00
iska 6c7e3465e9 Add implementation for a ordered dictionary for HTML attributes 2015-03-15 15:14:14 +01:00
iska 4afa6d11e1 Change HTML test's description property to "title" 2015-02-19 22:26:10 +01:00
iska 8787e1b0b9 Add all HTML5 Lib's tokenizer tests 2014-11-01 22:25:20 +01:00
iska aaec5971b8 Add performance test for tokenizing step 2014-10-31 18:06:59 +01:00
iska a28580b258 Fix initialisation of HTML5 Lib tests
Checks for nil values and inits accordingly
2014-10-30 21:18:56 +01:00
iska dd95a639c3 Add nil checks for DOCTYPE identifiers when initing HTML5 Lib tests 2014-10-26 23:43:52 +01:00
iska 9d2664fce0 Fix regex match range index in Process Double Escaped method 2014-10-26 23:43:29 +01:00
iska f2993181a8 Change method names in HTML5 Lib test class
Change Fixture to Dctionary
2014-10-26 23:43:21 +01:00
iska e7126a720f Add category to overwrite isEqual method in Parse Error tokens for testing
All parse error are treated as equal
2014-10-26 18:12:25 +01:00
iska a3358dd8b0 Fix HTML5 Lib test to correctly handle ParseError token
JSON structure is not strong with this one
2014-10-26 18:10:32 +01:00
iska e73a8dc512 Revert "Adapt HTML5 Lib test class to break output into multiple character tokens"
This reverts commit 79da32ed72.
2014-10-26 18:02:47 +01:00
iska 79da32ed72 Adapt HTML5 Lib test class to break output into multiple character tokens 2014-10-26 02:02:58 +02:00
iska 7d9b66ff8d Add "HTML Standarad" html file to tests resource for benchmarking
As of the latest update (2014/10/23) the test file is 8.1MB
2014-10-26 02:01:48 +02:00
iska 8088d239df Add common test case class 2014-10-26 01:59:52 +02:00
iska 5c28638be6 Add html5lib-tests as git submodule 2014-10-25 17:37:47 +02:00
iska 0910290ef2 Add generic HTML5LibTest class for performing HTML5lib tests
https://github.com/html5lib/html5lib-tests
2014-10-25 17:35:58 +02:00
iska d3be396ffc Add Xcode framework project for HTMLKit 2014-09-15 22:26:03 +02:00