Search in sources :

Example 1 with NodeToLabel

use of org.apache.jena.riot.out.NodeToLabel in project jena by apache.

the class TestNodeToLabel method node2label_01.

@Test
public void node2label_01() {
    NodeToLabel mapper = factory.create();
    String x1 = mapper.create();
    String x2 = mapper.create();
    assertNotNull(x1);
    assertNotNull(x2);
    assertNotEquals(x1, x2);
}
Also used : NodeToLabel(org.apache.jena.riot.out.NodeToLabel) BaseTest(org.apache.jena.atlas.junit.BaseTest) Test(org.junit.Test)

Example 2 with NodeToLabel

use of org.apache.jena.riot.out.NodeToLabel in project jena by apache.

the class TestNodeToLabel method node2label_03.

@Test
public void node2label_03() {
    NodeToLabel mapper = factory.create();
    Node x1 = NodeFactory.createBlankNode();
    Node x2 = NodeFactory.createBlankNode();
    String s1 = mapper.get(null, x1);
    String s2 = mapper.get(null, x2);
    assertNotNull(s1);
    assertNotNull(s2);
    assertNotEquals(s1, s2);
}
Also used : Node(org.apache.jena.graph.Node) NodeToLabel(org.apache.jena.riot.out.NodeToLabel) BaseTest(org.apache.jena.atlas.junit.BaseTest) Test(org.junit.Test)

Example 3 with NodeToLabel

use of org.apache.jena.riot.out.NodeToLabel in project jena by apache.

the class TestNodeToLabel method node2label_02.

@Test
public void node2label_02() {
    NodeToLabel mapper = factory.create();
    Node x = NodeFactory.createBlankNode();
    String s1 = mapper.get(null, x);
    String s2 = mapper.get(null, x);
    assertNotNull(s1);
    assertNotNull(s2);
    assertEquals(s1, s2);
}
Also used : Node(org.apache.jena.graph.Node) NodeToLabel(org.apache.jena.riot.out.NodeToLabel) BaseTest(org.apache.jena.atlas.junit.BaseTest) Test(org.junit.Test)

Aggregations

BaseTest (org.apache.jena.atlas.junit.BaseTest)3 NodeToLabel (org.apache.jena.riot.out.NodeToLabel)3 Test (org.junit.Test)3 Node (org.apache.jena.graph.Node)2