use of org.eclipse.xtext.parser.parameters.parametersTestLanguage.ParserRuleParameters in project xtext-core by eclipse.
the class AbstractParametersParsingTest method testScenario7_keyword.
@Test
public void testScenario7_keyword() {
try {
final ParserRuleParameters instance = this.getModel("#7 keyword");
Assert.assertEquals("keyword", instance.getScenario().getFirst());
} catch (Throwable _e) {
throw Exceptions.sneakyThrow(_e);
}
}
use of org.eclipse.xtext.parser.parameters.parametersTestLanguage.ParserRuleParameters in project xtext-core by eclipse.
the class AbstractParametersParsingTest method testScenario10_keyword.
@Test
public void testScenario10_keyword() {
try {
final ParserRuleParameters instance = this.getModelWithErrors("#10 keyword");
Assert.assertEquals("keyword", instance.getScenario().getSecond());
Assert.assertEquals("mismatched input \'<EOF>\' expecting \'keyword\'", IterableExtensions.<Resource.Diagnostic>head(instance.eResource().getErrors()).getMessage());
} catch (Throwable _e) {
throw Exceptions.sneakyThrow(_e);
}
}
use of org.eclipse.xtext.parser.parameters.parametersTestLanguage.ParserRuleParameters in project xtext-core by eclipse.
the class AbstractParametersParsingTest method testScenario11_id_keyword.
@Test
public void testScenario11_id_keyword() {
try {
final ParserRuleParameters instance = this.getModel("#11 id keyword");
Assert.assertEquals("id", instance.getScenario().getSecond());
} catch (Throwable _e) {
throw Exceptions.sneakyThrow(_e);
}
}
use of org.eclipse.xtext.parser.parameters.parametersTestLanguage.ParserRuleParameters in project xtext-core by eclipse.
the class AbstractParametersParsingTest method testScenario6_keyword.
@Test
public void testScenario6_keyword() {
try {
final ParserRuleParameters instance = this.getModelWithErrors("#6 keyword");
Assert.assertEquals(null, instance.getScenario());
Assert.assertEquals("no viable alternative at input \'#6\'", IterableExtensions.<Resource.Diagnostic>head(instance.eResource().getErrors()).getMessage());
} catch (Throwable _e) {
throw Exceptions.sneakyThrow(_e);
}
}
use of org.eclipse.xtext.parser.parameters.parametersTestLanguage.ParserRuleParameters in project xtext-core by eclipse.
the class AbstractParametersParsingTest method testScenario10_id_keyword.
@Test
public void testScenario10_id_keyword() {
try {
final ParserRuleParameters instance = this.getModel("#10 id keyword");
Assert.assertEquals("id", instance.getScenario().getSecond());
} catch (Throwable _e) {
throw Exceptions.sneakyThrow(_e);
}
}
Aggregations