|
|
|
@ -30,6 +30,7 @@ import java.util.Optional; |
|
|
|
import java.util.StringTokenizer; |
|
|
|
import java.util.StringTokenizer; |
|
|
|
import java.util.stream.Collectors; |
|
|
|
import java.util.stream.Collectors; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
import org.apache.commons.cli.MissingOptionException; |
|
|
|
import org.apache.commons.cli.MissingOptionException; |
|
|
|
import org.hamcrest.Matchers; |
|
|
|
import org.hamcrest.Matchers; |
|
|
|
import org.junit.jupiter.api.BeforeEach; |
|
|
|
import org.junit.jupiter.api.BeforeEach; |
|
|
|
@ -200,7 +201,7 @@ class GeneratorTests { |
|
|
|
doThrow(new TemplateException(null)).when(template).process(any(Map.class), any(Writer.class)); |
|
|
|
doThrow(new TemplateException(null)).when(template).process(any(Map.class), any(Writer.class)); |
|
|
|
|
|
|
|
|
|
|
|
Generator generator = new Generator(config, template); |
|
|
|
Generator generator = new Generator(config, template); |
|
|
|
GeneratorException ex = assertThrows(GeneratorException.class, () -> generator.start()); |
|
|
|
GeneratorException ex = assertThrows(GeneratorException.class, generator::start); |
|
|
|
assertThat(ex.getCause()).isInstanceOf(TemplateException.class); |
|
|
|
assertThat(ex.getCause()).isInstanceOf(TemplateException.class); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|