1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18 package org.apache.commons.rdf.api;
19
20 import org.junit.Test;
21
22
23
24
25
26 @SuppressWarnings("deprecation")
27 public class DefaultRDFTermFactoryTest {
28
29 RDFTermFactory factory = new RDFTermFactory() {};
30
31 @Test(expected=UnsupportedOperationException.class)
32 public void createBlankNode() throws Exception {
33 factory.createBlankNode();
34 }
35 @Test(expected=UnsupportedOperationException.class)
36 public void createBlankNodeName() throws Exception {
37 factory.createBlankNode("fred");
38 }
39 @Test(expected=UnsupportedOperationException.class)
40 public void createGraph() throws Exception {
41 factory.createGraph();
42 }
43 @Test(expected=UnsupportedOperationException.class)
44 public void createIRI() throws Exception {
45 factory.createIRI("http://example.com/");
46 }
47 @Test(expected=UnsupportedOperationException.class)
48 public void createLiteral() throws Exception {
49 factory.createLiteral("Alice");
50 }
51 @Test(expected=UnsupportedOperationException.class)
52 public void createLiteralLang() throws Exception {
53 factory.createLiteral("Alice", "en");
54 }
55 @Test(expected=UnsupportedOperationException.class)
56 public void createLiteralTyped() throws Exception {
57 factory.createLiteral("Alice", new DummyIRI(0));
58 }
59 @Test(expected=UnsupportedOperationException.class)
60 public void createTriple() throws Exception {
61 factory.createTriple(new DummyIRI(1), new DummyIRI(2), new DummyIRI(3));
62 }
63 }