AdConfiguration implements Serializable { String getUserAgent() { return mUserAgent; } @VisibleForTesting  AdConfiguration(final Context context); static AdConfiguration extractFromMap(Map<String, Object> map); @VisibleForTesting void setResponseString(String responseString); long getBroadcastIdentifier();  }
@Test public void constructor_shouldSetUserAgent() throws Exception { assertThat(subject.getUserAgent()).isEqualTo("Mozilla/5.0 (Linux; U; Android 4.0.3; ko-kr; LG-L160L Build/IML74K) AppleWebkit/534.30 (KHTML, like Gecko) Version/4.0 Mobile Safari/534.30"); }
@Test public void constructor_withNullContext_shouldSetUserAgent() throws Exception { subject = new AdConfiguration(null); assertThat(subject.getUserAgent()).isNull(); }