diff options
author | John Mark Bell <jmb@netsurf-browser.org> | 2009-01-19 00:44:21 +0000 |
---|---|---|
committer | John Mark Bell <jmb@netsurf-browser.org> | 2009-01-19 00:44:21 +0000 |
commit | dc1f016626194d2f73e62e6ae6c083a7c36da013 (patch) | |
tree | ce60276e8337135e24a345f917dd47b4ea29f82a /test/data/parse2/README | |
parent | c3053699eb33a9b29c1f98ea5473bb24a8721420 (diff) | |
download | libcss-dc1f016626194d2f73e62e6ae6c083a7c36da013.tar.gz libcss-dc1f016626194d2f73e62e6ae6c083a7c36da013.tar.bz2 |
Another test harness for parser tests. This one compares the reserialised output, thus allowing us to sensibly test handling of invalid input and suchlike.
Also, some rudimentary tests using this harness, and some documentation of the test data format.
This doesn't use the dumping code from the library itself, as that's likely to disappear.
svn path=/trunk/libcss/; revision=6144
Diffstat (limited to 'test/data/parse2/README')
-rw-r--r-- | test/data/parse2/README | 39 |
1 files changed, 39 insertions, 0 deletions
diff --git a/test/data/parse2/README b/test/data/parse2/README new file mode 100644 index 0000000..dec15f4 --- /dev/null +++ b/test/data/parse2/README @@ -0,0 +1,39 @@ +Parser testcases +================ + +Format +------ + +#data +<css source data> +#errors +<list of expected errors, with line/col offsets> (ignored at present) +#expected +<cssom tree, as below> +#reset + +Format of cssom tree +-------------------- + + line ::= rule | declaration + rule ::= '| ' name + name ::= .+ + declaration ::= '| ' property-name ': ' property-value + +Example +------- + +#data +* { color: #ff0000; background-image: url("foo.png"); } +#errors +#expected +| * +| color: #ff000000 +| background-image: url("foo.png") +#reset + +TODO +---- + + + Permit nesting of rules (for nested block support) + |