Kotlin, Kotest, Property Based Testing.
ApplicationService() @Test fun `throws exception if date is below minDate`() { // given val inputDto = createValidInputDto().copy( date = LocalDate.of(2020, 1, 1) ) // when + then val exception = shouldThrow<IllegalArgumentException> { applicationService.createOutput(inputDto) } exception.message