### Question:
QueryImpl extends ResourceImpl implements Query { @Override public void accept(ResourceVisitor visitor) { super.accept(visitor); Stream.of(dataSource).filter(Objects::nonNull).forEach(o -> o.accept(visitor)); }  ResourceReference getDataSource(); void setDataSource(ResourceReference dataSource); void setDataSource(ReportDataSource dataSource); void setDataSourceReference(String referenceURI); String getSql(); void setSql(String sql); String getLanguage(); void setLanguage(String language); @Override void setParameters(List<QueryParameterDescriptor> descriptors); @Override List<QueryParameterDescriptor> getParameters(); @Override void accept(ResourceVisitor visitor);  }### Answer:
@Test public void accept_nullDependencies_success() { QueryImpl query = new QueryImpl(); query.accept(visitor); verify(visitor, times(1)).visit(query); }