SesameAdapter implements Closeable, Wrapper { void remove(AxiomDescriptor axiomDescriptor) throws SesameDriverException { startTransactionIfNotActive(); new EpistemicAxiomRemover(connector, valueFactory).remove(axiomDescriptor); } SesameAdapter(Connector connector, DriverConfiguration configuration); @Override void close(); @Override boolean isOpen(); @Override T unwrap(Class<T> cls);  }
@Test void testRemove() throws Exception { final AxiomDescriptor desc = new AxiomDescriptor(SUBJECT); desc.addAssertion(Assertion.createClassAssertion(false)); desc.addAssertion(Assertion.createDataPropertyAssertion( URI.create("http: final Collection<Statement> statements = new HashSet<>(initStatementsForDescriptor(desc) .values()); when(connectorMock .findStatements(eq(subjectIri), any(org.eclipse.rdf4j.model.IRI.class), any(), eq(false), eq(null))) .thenReturn(statements); adapter.remove(desc); for (Assertion ass : desc.getAssertions()) { verify(connectorMock).findStatements(subjectIri, vf.createIRI(ass.getIdentifier().toString()), null, false, null); } verify(connectorMock).removeStatements(statements); }