summaryrefslogtreecommitdiff
path: root/src/test/java/dev/dnpm/oshelper/analyzer/TherapieplanAnalyzerTest.java
diff options
context:
space:
mode:
authorPaul-Christian Volkmer2026-09-03 14:35:10 +0200
committerGitHub2026-09-03 14:35:10 +0200
commitfb91356b7777dfa5b6088bcc3a48b43924c1c0fd (patch)
treea3d384390e388395953865a286f15292aaa04a86 /src/test/java/dev/dnpm/oshelper/analyzer/TherapieplanAnalyzerTest.java
parent59daf77a63bd17bb14248cf9881046dd6b331e2a (diff)
build: apply Spotless plugin (#293)
Diffstat (limited to 'src/test/java/dev/dnpm/oshelper/analyzer/TherapieplanAnalyzerTest.java')
-rw-r--r--src/test/java/dev/dnpm/oshelper/analyzer/TherapieplanAnalyzerTest.java38
1 files changed, 17 insertions, 21 deletions
diff --git a/src/test/java/dev/dnpm/oshelper/analyzer/TherapieplanAnalyzerTest.java b/src/test/java/dev/dnpm/oshelper/analyzer/TherapieplanAnalyzerTest.java
index 0ee1ef8..dc75e51 100644
--- a/src/test/java/dev/dnpm/oshelper/analyzer/TherapieplanAnalyzerTest.java
+++ b/src/test/java/dev/dnpm/oshelper/analyzer/TherapieplanAnalyzerTest.java
@@ -19,6 +19,8 @@
package dev.dnpm.oshelper.analyzer;
+import static org.mockito.Mockito.*;
+
import de.itc.onkostar.api.IOnkostarApi;
import de.itc.onkostar.api.Procedure;
import dev.dnpm.oshelper.services.FormService;
@@ -30,35 +32,29 @@ import org.junit.jupiter.api.extension.ExtendWith;
import org.mockito.Mock;
import org.mockito.junit.jupiter.MockitoExtension;
-import static org.mockito.Mockito.*;
-
@ExtendWith(MockitoExtension.class)
class TherapieplanAnalyzerTest {
- @Mock
- private IOnkostarApi onkostarApi;
-
- @Mock
- private FormService formService;
+ @Mock private IOnkostarApi onkostarApi;
- @Mock
- private TherapieplanServiceFactory therapieplanServiceFactory;
+ @Mock private FormService formService;
- private TherapieplanAnalyzer therapieplanAnalyzer;
+ @Mock private TherapieplanServiceFactory therapieplanServiceFactory;
- @BeforeEach
- void setUp() {
- this.therapieplanAnalyzer = new TherapieplanAnalyzer(therapieplanServiceFactory);
- }
+ private TherapieplanAnalyzer therapieplanAnalyzer;
- @Test
- void shouldRunServiceMethodsOnAnalyzeCalled() {
- when(this.therapieplanServiceFactory.currentUsableInstance())
- .thenReturn(new DefaultTherapieplanService(onkostarApi, formService));
+ @BeforeEach
+ void setUp() {
+ this.therapieplanAnalyzer = new TherapieplanAnalyzer(therapieplanServiceFactory);
+ }
- this.therapieplanAnalyzer.analyze(new Procedure(onkostarApi), null);
+ @Test
+ void shouldRunServiceMethodsOnAnalyzeCalled() {
+ when(this.therapieplanServiceFactory.currentUsableInstance())
+ .thenReturn(new DefaultTherapieplanService(onkostarApi, formService));
- verify(this.therapieplanServiceFactory, times(1)).currentUsableInstance();
- }
+ this.therapieplanAnalyzer.analyze(new Procedure(onkostarApi), null);
+ verify(this.therapieplanServiceFactory, times(1)).currentUsableInstance();
+ }
}