diff options
| author | Michael Williamson <mike@zwobble.org> | 2013-05-04 16:17:21 +0100 |
|---|---|---|
| committer | Michael Williamson <mike@zwobble.org> | 2013-05-04 16:17:21 +0100 |
| commit | 3b13af8c30ea45149b900faebc2a439e9a2be84e (patch) | |
| tree | 448cde8049e5ad85f5482cb6e89fa8b23d44367d /tests | |
| parent | efca7fab18dfc9d6cc384bd133ecb57016784260 (diff) | |
Parse choice operator in HTML paths
Diffstat (limited to 'tests')
| -rw-r--r-- | tests/style-reader.tests.js | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/tests/style-reader.tests.js b/tests/style-reader.tests.js index 12dafca..114c28d 100644 --- a/tests/style-reader.tests.js +++ b/tests/style-reader.tests.js @@ -15,6 +15,15 @@ describe('styleReader.readHtmlPath', function() { assert.deepEqual(readHtmlPath("p"), htmlPaths.elements(["p"])); }); + test('reads choice of elements', function() { + assert.deepEqual( + readHtmlPath("ul|ol"), + htmlPaths.elements([ + htmlPaths.element(["ul", "ol"]) + ]) + ); + }); + test('reads nested elements', function() { assert.deepEqual(readHtmlPath("ul > li"), htmlPaths.elements(["ul", "li"])); }); |
