### Question:
IndexerWebAccess { @SuppressWarnings("unchecked") public <T> T get(URI uri, IndexerConfig indexerConfig) throws IndexerAccessException { return get(uri, indexerConfig, null); }  @SuppressWarnings("unchecked") T get(URI uri, IndexerConfig indexerConfig); @SuppressWarnings("unchecked") T get(URI uri, IndexerConfig indexerConfig, Class responseType);  }### Answer:
@Test public void shouldUseIndexerUserAgent() throws Exception{ testee.get(new URI("http: Map<String, String> headers = headersCaptor.getValue(); assertThat(headers).contains(entry("User-Agent", "indexerUa")); }
@Test public void shouldUseGlobalUserAgentIfNoIndexerUaIsSet() throws Exception{ indexerConfig.setUserAgent(null); testee.get(new URI("http: Map<String, String> headers = headersCaptor.getValue(); assertThat(headers).contains(entry("User-Agent", "globalUa")); }
@Test public void shouldUseIndexerTimeout() throws Exception{ testee.get(new URI("http: assertThat(timeoutCaptor.getValue()).isEqualTo(10); }
@Test public void shouldUseGlobalTimeoutNoIndexerTimeoutIsSet() throws Exception{ indexerConfig.setTimeout(null); testee.get(new URI("http: assertThat(timeoutCaptor.getValue()).isEqualTo(100); }