JenaConnection implements Connection { @Override public boolean contains(Axiom<?> axiom, URI context) throws JenaDriverException { ensureOpen(); Objects.requireNonNull(axiom); try { return adapter.contains(axiom, context); } catch (RuntimeException e) { throw new JenaDriverException(e); } } JenaConnection(JenaAdapter adapter); @Override boolean isOpen(); @Override void commit(); @Override void rollback(); @Override void setAutoCommit(boolean autoCommit); @Override boolean isAutoCommit(); @Override JenaStatement createStatement(); @Override PreparedStatement prepareStatement(String sparql); @Override boolean isConsistent(URI context); @Override List<URI> getContexts(); @Override boolean contains(Axiom<?> axiom, URI context); @Override Collection<Axiom<?>> find(AxiomDescriptor descriptor); @Override void persist(AxiomValueDescriptor descriptor); @Override URI generateIdentifier(URI classUri); @Override void update(AxiomValueDescriptor descriptor); @Override void remove(AxiomDescriptor descriptor); @Override JenaLists lists(); @Override JenaTypes types(); @Override JenaProperties properties(); @Override T unwrap(Class<T> cls); @Override void close();  }
@Test public void containsCallsAdapterWithArguments() throws Exception { final Axiom<?> axiom = new AxiomImpl<>(SUBJECT, Assertion.createClassAssertion(false), new Value<>(NamedResource.create(Generator.generateUri()))); final URI context = Generator.generateUri(); connection.contains(axiom, context); verify(adapterMock).contains(axiom, context); }