1 6 7 package com.hp.hpl.jena.rdf.model.test; 8 9 import com.hp.hpl.jena.rdf.model.*; 10 11 import junit.framework.TestSuite; 12 13 16 public class TestContainers extends ModelTestBase 17 { 18 public TestContainers( String name ) 19 { super( name ); } 20 21 public static TestSuite suite() 22 { return new TestSuite( TestContainers.class ); } 23 24 27 public void testCanAsContainer() 28 { 29 String seqUri = "http://example.com/#seq"; 30 Model model = ModelFactory.createDefaultModel(); 31 Seq seq = model.createSeq( seqUri ); 32 Resource res = model.createResource( seqUri ); 33 assertTrue( res.canAs( Seq.class ) ); 34 assertTrue( res.canAs( Container.class ) ); 35 } 36 } 37 38 39 | Popular Tags |