@@ -0,0 +1,1958 @@
+package com.ibm.watson.developer_cloud.service;%0A%0Aimport com.ibm.watson.developer_cloud.WatsonServiceUnitTest;%0Aimport com.ibm.watson.developer_cloud.http.HttpMediaType;%0Aimport com.ibm.watson.developer_cloud.http.RequestBuilder;%0Aimport com.ibm.watson.developer_cloud.http.ServiceCall;%0Aimport com.ibm.watson.developer_cloud.service.model.GenericModel;%0Aimport com.ibm.watson.developer_cloud.util.ResponseConverterUtils;%0Aimport okhttp3.HttpUrl;%0Aimport okhttp3.mockwebserver.MockResponse;%0Aimport okhttp3.mockwebserver.RecordedRequest;%0Aimport org.junit.Before;%0Aimport org.junit.Test;%0A%0Aimport static org.junit.Assert.assertTrue;%0A%0Apublic class HeadersTest extends WatsonServiceUnitTest %7B%0A%0A  public class TestModel extends GenericModel %7B %7D%0A%0A  public class TestService extends WatsonService %7B%0A%0A    private static final String SERVICE_NAME = %22test%22;%0A%0A    public TestService() %7B%0A      super(SERVICE_NAME);%0A    %7D%0A%0A    public ServiceCall%3CTestModel%3E testMethod() %7B%0A      RequestBuilder builder = RequestBuilder.get(HttpUrl.parse(getEndPoint() + %22/v1/test%22));%0A      return createServiceCall(builder.build(), ResponseConverterUtils.getObject(TestModel.class));%0A    %7D%0A  %7D%0A%0A  TestService service;%0A%0A  /*%0A   * (non-Javadoc)%0A   *%0A   * @see com.ibm.watson.developer_cloud.WatsonServiceTest#setUp()%0A   */%0A  @Override%0A  @Before%0A  public void setUp() throws Exception %7B%0A    super.setUp();%0A    service = new TestService();%0A    service.setApiKey(%22%22);%0A    service.setEndPoint(getMockWebServerUrl());%0A  %7D%0A%0A  @Test%0A  public void testAddHeader() throws InterruptedException %7B%0A    server.enqueue(new MockResponse()%0A        .addHeader(CONTENT_TYPE, HttpMediaType.APPLICATION_JSON)%0A        .setBody(%22%7B%5C%22test_key%5C%22: %5C%22test_value%5C%22%7D%22));%0A%0A    String headerName = %22X-Test%22;%0A    TestModel response = service.testMethod()%0A        .addHeader(headerName, %22test%22)%0A        .execute();%0A    final RecordedRequest request = server.takeRequest();%0A    assertTrue(request.getHeader(headerName) != null);%0A  %7D%0A%7D%0A

Add unit test for adding headers