Search in sources :

Example 1 with TypeParserException

use of org.eclipse.ceylon.model.loader.TypeParserException in project ceylon by eclipse.

the class TypeParserTests method testIterableAbbrev.

@Test
public void testIterableAbbrev() {
    try {
        new TypeParser(MockLoader.instance).decodeType("{a}", null, mockDefaultModule, mockPkgUnit);
        Assert.fail();
    } catch (TypeParserException e) {
        Assert.assertEquals("org.eclipse.ceylon.model.loader.TypeParserException: Expected multiplicity in abbreviated Iterable type: 2", e.toString());
    }
}
Also used : TypeParser(org.eclipse.ceylon.model.loader.TypeParser) TypeParserException(org.eclipse.ceylon.model.loader.TypeParserException) Test(org.junit.Test)

Aggregations

TypeParser (org.eclipse.ceylon.model.loader.TypeParser)1 TypeParserException (org.eclipse.ceylon.model.loader.TypeParserException)1 Test (org.junit.Test)1