Adding check that charset range is in correct order

This commit is contained in:
Jeff Avallone
2014-12-22 15:18:49 -05:00
parent 9b8eef9c02
commit d882ee8e08
2 changed files with 11 additions and 0 deletions
@@ -17,6 +17,13 @@ describe('parser/javascript/charset_range.js', function() {
}));
});
it('throws an exception when the range is out of order', function() {
var parser = new javascript.Parser('z-a');
expect(() => {
parser.__consume__charset_range();
}).toThrow('Range out of order in character class: z-a');
});
describe('#_render', function() {
beforeEach(function() {