Skip to content

Commit

Permalink
Fix styles and tests
Browse files Browse the repository at this point in the history
  • Loading branch information
jianghaolu committed May 19, 2016
1 parent aabe677 commit b443c0f
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -35,10 +35,20 @@ public UserAgentInterceptor() {
this.userAgent = DEFAULT_USER_AGENT_HEADER;
}

/**
* Overwrite the User-Agent header.
*
* @param userAgent the new user agent value.
*/
public void setUserAgent(String userAgent) {
this.userAgent = userAgent;
}

/**
* Append a text to the User-Agent header.
*
* @param userAgent the user agent value to append.
*/
public void appendUserAgent(String userAgent) {
this.userAgent += " " + userAgent;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,18 +8,17 @@
package com.microsoft.rest;

import com.microsoft.rest.serializer.JacksonMapperAdapter;
import okhttp3.Interceptor;
import okhttp3.OkHttpClient;
import okhttp3.Protocol;
import okhttp3.Request;
import okhttp3.Response;
import retrofit2.Retrofit;

import org.junit.Assert;
import org.junit.Test;

import java.io.IOException;

import okhttp3.Interceptor;
import okhttp3.Protocol;
import okhttp3.Request;
import okhttp3.Response;

public class UserAgentTests {
@Test
public void defaultUserAgentTests() throws Exception {
Expand Down

0 comments on commit b443c0f

Please sign in to comment.