@Test
public void build_throwsException_whenProxySetAndPasswordNull() {

  GoogleCloudStorageOptions.Builder builder =
      GoogleCloudStorageOptions.builder()
          .setProxyAddress("proxy-address")
          .setProxyPassword(null)
          .setProxyUsername(RedactedString.create("proxy-username"));
  IllegalArgumentException e = assertThrows(IllegalArgumentException.class, builder::build);
  assertThat(e)
      .hasMessageThat()
      .isEqualTo("both proxyUsername and proxyPassword should be null or not null together");
}