use of org.eclipse.rdf4j.repository.Repository in project rdf4j by eclipse.
the class ContextAwareConnectionTest method testAddContexts.
@Test
public void testAddContexts() throws Exception {
RepositoryConnection stub = new RepositoryConnectionStub();
Repository repo = stub.getRepository();
ContextAwareConnection a = new ContextAwareConnection(repo, stub);
ContextAwareConnection b = new ContextAwareConnection(repo, a);
b.setAddContexts(context);
assertEquals(context, b.getAddContexts()[0]);
assertEquals(context, a.getAddContexts()[0]);
}
use of org.eclipse.rdf4j.repository.Repository in project rdf4j by eclipse.
the class ContextAwareConnectionTest method testInsertContexts.
@Test
public void testInsertContexts() throws Exception {
RepositoryConnection stub = new RepositoryConnectionStub();
Repository repo = stub.getRepository();
ContextAwareConnection a = new ContextAwareConnection(repo, stub);
ContextAwareConnection b = new ContextAwareConnection(repo, a);
b.setInsertContext(context);
assertEquals(context, b.getInsertContext());
assertEquals(context, a.getInsertContext());
}
use of org.eclipse.rdf4j.repository.Repository in project rdf4j by eclipse.
the class ContextAwareConnectionTest method testReadContexts.
@Test
public void testReadContexts() throws Exception {
RepositoryConnection stub = new RepositoryConnectionStub();
Repository repo = stub.getRepository();
ContextAwareConnection a = new ContextAwareConnection(repo, stub);
ContextAwareConnection b = new ContextAwareConnection(repo, a);
b.setReadContexts(context);
assertEquals(context, b.getReadContexts()[0]);
assertEquals(context, a.getReadContexts()[0]);
}
use of org.eclipse.rdf4j.repository.Repository in project rdf4j by eclipse.
the class ContextAwareConnectionTest method testRemoveContexts.
@Test
public void testRemoveContexts() throws Exception {
RepositoryConnection stub = new RepositoryConnectionStub();
Repository repo = stub.getRepository();
ContextAwareConnection a = new ContextAwareConnection(repo, stub);
ContextAwareConnection b = new ContextAwareConnection(repo, a);
b.setRemoveContexts(context);
assertEquals(context, b.getRemoveContexts()[0]);
assertEquals(context, a.getRemoveContexts()[0]);
}
use of org.eclipse.rdf4j.repository.Repository in project rdf4j by eclipse.
the class ContextAwareConnectionTest method testArchiveContexts.
@Test
public void testArchiveContexts() throws Exception {
RepositoryConnection stub = new RepositoryConnectionStub();
Repository repo = stub.getRepository();
ContextAwareConnection a = new ContextAwareConnection(repo, stub);
ContextAwareConnection b = new ContextAwareConnection(repo, a);
b.setArchiveContexts(context);
assertEquals(context, b.getArchiveContexts()[0]);
assertEquals(context, a.getArchiveContexts()[0]);
}
Aggregations