summaryrefslogtreecommitdiff
path: root/src/test/java/dev/dnpm/oshelper/services/StudieTest.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/services/StudieTest.java
parent59daf77a63bd17bb14248cf9881046dd6b331e2a (diff)
build: apply Spotless plugin (#293)
Diffstat (limited to 'src/test/java/dev/dnpm/oshelper/services/StudieTest.java')
-rw-r--r--src/test/java/dev/dnpm/oshelper/services/StudieTest.java60
1 files changed, 18 insertions, 42 deletions
diff --git a/src/test/java/dev/dnpm/oshelper/services/StudieTest.java b/src/test/java/dev/dnpm/oshelper/services/StudieTest.java
index f8d64c2..b65760a 100644
--- a/src/test/java/dev/dnpm/oshelper/services/StudieTest.java
+++ b/src/test/java/dev/dnpm/oshelper/services/StudieTest.java
@@ -19,56 +19,32 @@
package dev.dnpm.oshelper.services;
+import static org.assertj.core.api.Assertions.assertThat;
+
import dev.dnpm.oshelper.dto.Studie;
import org.junit.jupiter.api.Test;
-import static org.assertj.core.api.Assertions.assertThat;
-
class StudieTest {
- @Test
- void shouldDetectStudieWithNctNumber() {
- var studie = new Studie(
- "Kat 1",
- 1,
- null,
- "Nct-12345678",
- "Teststudie 1",
- "Teststudie 1",
- true
- );
-
- assertThat(studie.getType()).isEqualTo(Studie.Type.NCT);
- }
+ @Test
+ void shouldDetectStudieWithNctNumber() {
+ var studie = new Studie("Kat 1", 1, null, "Nct-12345678", "Teststudie 1", "Teststudie 1", true);
- @Test
- void shouldDetectStudieWithEudraCtNumber() {
- var studie = new Studie(
- "Kat 1",
- 1,
- null,
- "2023-012345-12",
- "Teststudie 1",
- "Teststudie 1",
- true
- );
+ assertThat(studie.getType()).isEqualTo(Studie.Type.NCT);
+ }
- assertThat(studie.getType()).isEqualTo(Studie.Type.EUDRA_CT);
- }
+ @Test
+ void shouldDetectStudieWithEudraCtNumber() {
+ var studie =
+ new Studie("Kat 1", 1, null, "2023-012345-12", "Teststudie 1", "Teststudie 1", true);
- @Test
- void shouldReturnStudieWithUnknownNumberScheme() {
- var studie = new Studie(
- "Kat 1",
- 1,
- "teststudie1",
- null,
- "Teststudie 1",
- "Teststudie 1",
- true
- );
+ assertThat(studie.getType()).isEqualTo(Studie.Type.EUDRA_CT);
+ }
- assertThat(studie.getType()).isEqualTo(Studie.Type.UNKNOWN);
- }
+ @Test
+ void shouldReturnStudieWithUnknownNumberScheme() {
+ var studie = new Studie("Kat 1", 1, "teststudie1", null, "Teststudie 1", "Teststudie 1", true);
+ assertThat(studie.getType()).isEqualTo(Studie.Type.UNKNOWN);
+ }
}