### Question:
StatusInfo implements Serializable { public static StatusInfo valueOf(String statusCode, @Nullable Map<String, ?> details) { return new StatusInfo(statusCode, details); } private  StatusInfo(String status, @Nullable Map<String, ?> details); static StatusInfo valueOf(String statusCode, @Nullable Map<String, ?> details); static StatusInfo valueOf(String statusCode); static StatusInfo ofUnknown(); static StatusInfo ofUp(); static StatusInfo ofDown(); static StatusInfo ofOffline(); static StatusInfo ofUp(@Nullable Map<String, Object> details); static StatusInfo ofDown(@Nullable Map<String, Object> details); static StatusInfo ofOffline(@Nullable Map<String, Object> details); Map<String, Object> getDetails(); @JsonIgnore boolean isUp(); @JsonIgnore boolean isOffline(); @JsonIgnore boolean isDown(); @JsonIgnore boolean isUnknown(); static Comparator<String> severity(); @SuppressWarnings("unchecked") static StatusInfo from(Map<String, ?> body); static final String STATUS_UNKNOWN; static final String STATUS_OUT_OF_SERVICE; static final String STATUS_UP; static final String STATUS_DOWN; static final String STATUS_OFFLINE; static final String STATUS_RESTRICTED; }### Answer:
@Test public void invariants() { assertThatThrownBy(() -> StatusInfo.valueOf("")).isInstanceOf(IllegalArgumentException.class) .hasMessage("'status' must not be empty."); }