forked from jasder/antlr
Merge pull request #1659 from bhamiltoncx/js-use-code-points-for-tests
JavaScript: Allow Unicode code points > U+FFFF in tests
This commit is contained in:
commit
877f6a396b
|
@ -678,7 +678,7 @@ public abstract class BaseBrowserTest implements RuntimeTestSupport {
|
|||
" test = function() {\r\n" +
|
||||
" document.getElementById('output').value = ''\r\n" +
|
||||
" var input = document.getElementById('input').value;\r\n" +
|
||||
" var stream = new antlr4.InputStream(input);\n" +
|
||||
" var stream = new antlr4.InputStream(input, true);\n" +
|
||||
" var lexer = new " + lexerName + "." + lexerName + "(stream);\n" +
|
||||
" lexer._listeners = [new listener()];\r\n" +
|
||||
" var tokens = new antlr4.CommonTokenStream(lexer);\n" +
|
||||
|
@ -737,7 +737,7 @@ public abstract class BaseBrowserTest implements RuntimeTestSupport {
|
|||
" test = function() {\r\n" +
|
||||
" document.getElementById('output').value = ''\r\n" +
|
||||
" var input = document.getElementById('input').value;\r\n" +
|
||||
" var chars = new antlr4.InputStream(input);\r\n" +
|
||||
" var chars = new antlr4.InputStream(input, true);\r\n" +
|
||||
" var lexer = new " + lexerName + "." + lexerName + "(chars);\r\n" +
|
||||
" lexer._listeners = [new listener()];\r\n" +
|
||||
" var stream = new antlr4.CommonTokenStream(lexer);\r\n" +
|
||||
|
|
|
@ -643,7 +643,7 @@ public class BaseNodeTest implements RuntimeTestSupport {
|
|||
+ "};\n"
|
||||
+ "\n"
|
||||
+ "function main(argv) {\n"
|
||||
+ " var input = new antlr4.FileStream(argv[2]);\n"
|
||||
+ " var input = new antlr4.FileStream(argv[2], true);\n"
|
||||
+ " var lexer = new <lexerName>.<lexerName>(input);\n"
|
||||
+ " var stream = new antlr4.CommonTokenStream(lexer);\n"
|
||||
+ "<createParser>"
|
||||
|
@ -679,7 +679,7 @@ public class BaseNodeTest implements RuntimeTestSupport {
|
|||
+ "var <lexerName> = require('./<lexerName>');\n"
|
||||
+ "\n"
|
||||
+ "function main(argv) {\n"
|
||||
+ " var input = new antlr4.FileStream(argv[2]);\n"
|
||||
+ " var input = new antlr4.FileStream(argv[2], true);\n"
|
||||
+ " var lexer = new <lexerName>.<lexerName>(input);\n"
|
||||
+ " var stream = new antlr4.CommonTokenStream(lexer);\n"
|
||||
+ " stream.fill();\n"
|
||||
|
|
Loading…
Reference in New Issue