aboutsummaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorMichael Williamson <mike@zwobble.org>2016-09-27 21:15:45 +0100
committerMichael Williamson <mike@zwobble.org>2016-09-27 21:15:45 +0100
commite300cd5236d238fcc3d638d4c481af017d2c623a (patch)
treead8697112146da3706df7f5c239f7abd0767149e /test
parent99b2d79d13703939f37e3ecb5becfdbf928e604a (diff)
Expect end token when parsing style mappings
Diffstat (limited to 'test')
-rw-r--r--test/style-reader.tests.js7
1 files changed, 7 insertions, 0 deletions
diff --git a/test/style-reader.tests.js b/test/style-reader.tests.js
index 19f9c00..ec17e3a 100644
--- a/test/style-reader.tests.js
+++ b/test/style-reader.tests.js
@@ -162,6 +162,13 @@ test("styleReader.read", {
to: htmlPaths.empty
}
);
+ },
+
+ "error when not all input is consumed": function() {
+ assert.deepEqual(
+ readStyle("r => span a"),
+ new results.Result(null, [results.warning("Did not understand this style mapping, so ignored it: r => span a\nError was at character number 10: Expected end but got whitespace")])
+ );
}
});