Disable tests which rely on carriage returns in the input
For some reason, the test generator is not currently able to create string literals containing these characters, so the tests will fail.
This commit is contained in:
parent
12efe2f83b
commit
80a881e132
|
@ -1,5 +1,9 @@
|
|||
TestType() ::= "Lexer"
|
||||
|
||||
Options ::= [
|
||||
"Ignore": "Currently unable to generate the required CRLF input sequence."
|
||||
]
|
||||
|
||||
Grammar ::= [
|
||||
"L": {<grammar("L")>}
|
||||
]
|
||||
|
|
|
@ -1,5 +1,9 @@
|
|||
TestType() ::= "Lexer"
|
||||
|
||||
Options ::= [
|
||||
"Ignore": "Currently unable to generate the required CRLF input sequence."
|
||||
]
|
||||
|
||||
Grammar ::= [
|
||||
"L": {<grammar("L")>}
|
||||
]
|
||||
|
|
|
@ -1,5 +1,9 @@
|
|||
TestType() ::= "Lexer"
|
||||
|
||||
Options ::= [
|
||||
"Ignore": "Currently unable to generate the required CRLF input sequence."
|
||||
]
|
||||
|
||||
Grammar ::= [
|
||||
"L": {<grammar("L")>}
|
||||
]
|
||||
|
|
|
@ -1,5 +1,9 @@
|
|||
TestType() ::= "Lexer"
|
||||
|
||||
Options ::= [
|
||||
"Ignore": "Currently unable to generate the required CRLF input sequence."
|
||||
]
|
||||
|
||||
Grammar ::= [
|
||||
"L": {<grammar("L")>}
|
||||
]
|
||||
|
|
|
@ -2,6 +2,7 @@ TestFile(file) ::= <<
|
|||
package org.antlr4.runtime.test;
|
||||
|
||||
import org.antlr.v4.test.rt.java.BaseTest;
|
||||
import org.junit.Ignore;
|
||||
import org.junit.Test;
|
||||
|
||||
import static org.junit.Assert.*;
|
||||
|
@ -21,7 +22,7 @@ public class Test<file.name> extends BaseTest {
|
|||
>>
|
||||
|
||||
LexerTestMethod(test) ::= <<
|
||||
@Test
|
||||
<testAnnotations(test)>
|
||||
public void test<test.name>() throws Exception {
|
||||
mkdir(tmpdir);
|
||||
|
||||
|
@ -52,6 +53,13 @@ CompositeLexerTestMethod(test) ::= <<
|
|||
<LexerTestMethod(test)>
|
||||
>>
|
||||
|
||||
testAnnotations(test) ::= <%
|
||||
@Test
|
||||
<if(test.Options.("Ignore"))>
|
||||
<\n>@Ignore(<writeStringLiteral(test.Options.("Ignore"))>)
|
||||
<endif>
|
||||
%>
|
||||
|
||||
writeBoolean(o) ::= "<if(o && !isEmpty.(o))>true<else>false<endif>"
|
||||
|
||||
buildStringLiteral(text, variable) ::= <<
|
||||
|
@ -78,7 +86,7 @@ writeLines(textLines) ::= <%
|
|||
%>
|
||||
|
||||
ParserTestMethod(test) ::= <<
|
||||
@Test
|
||||
<testAnnotations(test)>
|
||||
public void test<test.name>() throws Exception {
|
||||
mkdir(tmpdir);
|
||||
|
||||
|
@ -125,7 +133,7 @@ String test<test.name>(String input) throws Exception {
|
|||
>>
|
||||
|
||||
ConcreteParserTestMethod(test) ::= <<
|
||||
@Test
|
||||
<testAnnotations(test)>
|
||||
public void test<test.name>() throws Exception {
|
||||
String found = test<test.baseName>("<test.input>");
|
||||
assertEquals("<test.expectedOutput>", found);
|
||||
|
|
Loading…
Reference in New Issue