Origin implements Serializable { public static Origin create(String value) { try { return new Origin(value); } catch (NullPointerException e) { throw new IllegalArgumentException("value is out of range: null", e); } } @Deprecated  Origin(String scheme, String host, int port);  Origin(String originUrl); static Origin create(String value); String getScheme(); String getHost(); Integer getPort(); String getSchemeSpecificPart(); @JsonValue @Override String toString(); @Override boolean equals(Object o); @Override int hashCode();  }
@Test void create_with_null_test(){ assertThrows(IllegalArgumentException.class, () -> Origin.create(null) ); }