RobotsConfig { public void setReadTimeoutMillis(@Nonnegative int readTimeoutMillis) { checkArgument(readTimeoutMillis >= 0, "readTimeoutMillis is negative"); this.readTimeoutMillis = readTimeoutMillis; }  long getRequestTimeoutMillis(); void setRequestTimeoutMillis(@Nonnegative long requestTimeoutMillis); int getReadTimeoutMillis(); void setReadTimeoutMillis(@Nonnegative int readTimeoutMillis); @Nonnull String getUserAgent(); void setUserAgent(@Nonnull String userAgent); @Nonnull Charset getDefaultCharset(); void setDefaultCharset(@Nonnull Charset defaultCharset); @Nonnegative int getMaxRedirectHops(); void setMaxRedirectHops(@Nonnegative int maxRedirectHops); @Nonnegative long getCacheExpiresHours(); void setCacheExpiresHours(@Nonnegative long cacheExpiresHours); @Nonnegative long getCacheMaxSizeRecords(); void setCacheMaxSizeRecords(@Nonnegative long cacheMaxSizeRecords); @Nonnegative int getMaxFileSizeBytes(); void setMaxFileSizeBytes(@Nonnegative int maxFileSizeBytes); @Override @Nonnull String toString();  }
@Test(expected = IllegalArgumentException.class) public void givenNegativeValue_whenSetReadTimeoutMillis_thenThrowsIAE() { final int readTimeoutMillis = -1; config.setReadTimeoutMillis(readTimeoutMillis); }