Skip to content

Commit

Permalink
P4ADEV-2037 add test
Browse files Browse the repository at this point in the history
  • Loading branch information
RiccardoGiuliani committed Jan 29, 2025
1 parent ec55be8 commit ad1b5a1
Showing 1 changed file with 15 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,11 @@
import org.junit.jupiter.params.ParameterizedTest;
import org.junit.jupiter.params.provider.ValueSource;

import static org.junit.jupiter.api.Assertions.assertFalse;
import java.time.LocalDateTime;
import java.time.OffsetDateTime;
import java.time.ZoneOffset;

import static org.junit.jupiter.api.Assertions.assertEquals;
import static org.junit.jupiter.api.Assertions.assertNull;
import static org.junit.jupiter.api.Assertions.*;

class UtilitiesTest {

Expand Down Expand Up @@ -44,4 +42,18 @@ void testLocalDatetimeToOffsetDateTimeWithNull() {

assertNull(result, "The result should be null for a null input.");
}

@Test
void testGetRandomIUD() {
String iud = Utilities.getRandomIUD();

assertTrue(iud.startsWith("000"));
}

@Test
void testGetRandomicUUID() {
String uuid = Utilities.getRandomicUUID();

assertEquals(32, uuid.length());
}
}

0 comments on commit ad1b5a1

Please sign in to comment.