/** * test that a union model is a model over the union of the two underlying * graphs. (We don't check that Union works - that's done in the Union * tests, we hope.) */ public void testCreateUnion() { final Model m1 = ModelFactory.createDefaultModel(); final Model m2 = ModelFactory.createDefaultModel(); final Model m = ModelFactory.createUnion(m1, m2); JenaTestBase.assertInstanceOf(Union.class, m.getGraph()); Assert.assertSame(m1.getGraph(), ((Union) m.getGraph()).getL()); Assert.assertSame(m2.getGraph(), ((Union) m.getGraph()).getR()); }
/** * test that a union model is a model over the union of the two underlying * graphs. (We don't check that Union works - that's done in the Union * tests, we hope.) */ public void testCreateUnion() { final Model m1 = ModelFactory.createDefaultModel(); final Model m2 = ModelFactory.createDefaultModel(); final Model m = ModelFactory.createUnion(m1, m2); JenaTestBase.assertInstanceOf(Union.class, m.getGraph()); Assert.assertSame(m1.getGraph(), ((Union) m.getGraph()).getL()); Assert.assertSame(m2.getGraph(), ((Union) m.getGraph()).getR()); }