class InstrumentedOkHttpClients {

  public static OkHttpClient create(MetricRegistry registry) {
    return new InstrumentedOkHttpClient(registry, new OkHttpClient(), null);
  }

}

class InstrumentedOkHttpClientsTest {

  private MetricRegistry registry;

  @Test public void instrumentProvidedClient() {

    OkHttpClient rawClient = new OkHttpClient();
    OkHttpClient client = InstrumentedOkHttpClients.create(registry, rawClient);
    assertThatClientsAreEqual(client, rawClient);
  }

}