Search in sources :

Example 1 with ItemException

use of org.apache.jena.sparql.sse.ItemException in project jena by apache.

the class TestSSE_Basic method testNum_04.

@Test
public void testNum_04() {
    Item item = SSE.parse("abc");
    try {
        item.getInt();
        fail("Succeeded where exceptiSSE.on expected");
    } catch (ItemException ex) {
    }
}
Also used : Item(org.apache.jena.sparql.sse.Item) ItemException(org.apache.jena.sparql.sse.ItemException) Test(org.junit.Test)

Example 2 with ItemException

use of org.apache.jena.sparql.sse.ItemException in project jena by apache.

the class TestSSE_Basic method testNum_05.

@Test
public void testNum_05() {
    Item item = SSE.parse("<x>");
    try {
        item.getInt();
        fail("Succeeded where exception expected");
    } catch (ItemException ex) {
    }
}
Also used : Item(org.apache.jena.sparql.sse.Item) ItemException(org.apache.jena.sparql.sse.ItemException) Test(org.junit.Test)

Aggregations

Item (org.apache.jena.sparql.sse.Item)2 ItemException (org.apache.jena.sparql.sse.ItemException)2 Test (org.junit.Test)2