use of com.nike.backstopper.model.DefaultErrorContractDTO in project riposte by Nike-Inc.
the class ErrorResponseBodyImplTest method copy_constructor_throws_IllegalArgumentException_when_passed_DTO_with_null_errorId.
@Test
public void copy_constructor_throws_IllegalArgumentException_when_passed_DTO_with_null_errorId() {
// when
Throwable ex = catchThrowable(() -> new ErrorResponseBodyImpl(new DefaultErrorContractDTO(null, Collections.emptyList())));
// then
Assertions.assertThat(ex).isInstanceOf(IllegalArgumentException.class).hasMessage("The DefaultErrorContractDTO.error_id value cannot be null.");
}
Aggregations