1 6 package com.hp.hpl.jena.rdf.arp.test; 7 import junit.framework.*; 8 import java.io.*; 10 11 import com.hp.hpl.jena.rdf.model.*; 12 13 17 public class TestScope extends TestCase { 18 public static Test suite() { 19 TestSuite s = new TestSuite(TestScope.class); 20 s.setName("ARP Scoping"); 21 return s; 22 } 23 public TestScope(String nm){ 24 super(nm); 25 } 26 27 public void test01() throws Exception { 28 29 check("testing/wg/rdfms-syntax-incomplete/test004.rdf"); 30 } 32 public void test02() throws Exception { 33 check("testing/arp/scope/test02.rdf"); 34 } 35 public void test03() throws Exception { 36 check("testing/arp/scope/test03.rdf"); 37 } 38 39 40 public void test04() throws Exception { 41 check("testing/arp/scope/test04.rdf"); 42 } 43 44 public void test05() throws Exception { 45 check("testing/arp/scope/test05.rdf"); 46 } 47 static RDFErrorHandler suppress = new RDFErrorHandler(){ 48 49 public void warning(Exception e) { 50 } 51 52 public void error(Exception e) { 53 } 54 55 public void fatalError(Exception e) { 56 } 57 58 }; 59 private void check(final String fn) throws IOException { 60 61 NTripleTestSuite.loadRDFx(new InFactoryX(){ 62 63 public InputStream open() throws IOException { 64 return new FileInputStream(fn); 65 } 66 },suppress,"http://example.org/a",false,0); 67 } 69 70 } 71 72 | Popular Tags |