Jasmine: Convert tests of parser's "classCharacter" rule

redux
David Majda 13 years ago
parent b9ae8f9561
commit d29a753b8d

@ -86,6 +86,14 @@ describe("PEG.js grammar parser", function() {
});
});
/* Canonical classCharacter is "a". */
it("parses classCharacter", function() {
expect('start = [a]').toParseAs(classGrammar(["a"], "[a]"));
/* This test demonstrates that |rawText| is not really "raw". */
expect('start = [\u0080]').toParseAs(classGrammar(["\x80"], "[\\x80]"));
});
/* Canonical bracketDelimitedCharacter is "a". */
it("parses bracketDelimitedCharacter", function() {
expect('start = [a]' ).toParseAs(classGrammar(["a"], "[a]"));

@ -442,9 +442,4 @@ test("parses classCharacterRange", function() {
);
});
/* Canonical classCharacter is "a". */
test("parses classCharacter", function() {
parserParses("start = [a]", classGrammar(false, ["a"], "[a]"));
});
})();

Loading…
Cancel
Save