+
+
+
+
diff --git a/src/test/java/de/focusshift/zeiterfassung/report/ReportControllerTest.java b/src/test/java/de/focusshift/zeiterfassung/report/ReportControllerTest.java
index 0426212c6..df785ff56 100644
--- a/src/test/java/de/focusshift/zeiterfassung/report/ReportControllerTest.java
+++ b/src/test/java/de/focusshift/zeiterfassung/report/ReportControllerTest.java
@@ -16,12 +16,9 @@
import org.springframework.test.web.servlet.request.MockHttpServletRequestBuilder;
import org.threeten.extra.YearWeek;
-import java.time.Clock;
-import java.time.LocalDate;
-import java.time.Month;
-import java.time.Year;
-import java.time.YearMonth;
+import java.time.*;
import java.util.List;
+import java.util.Set;
import static org.mockito.Mockito.when;
import static org.springframework.security.test.web.servlet.request.SecurityMockMvcRequestPostProcessors.oidcLogin;
@@ -162,7 +159,7 @@ void ensureWeekReportCsvDownloadUrlWithUsersParam() throws Exception {
void ensureWeekReportUserFilterRelatedUrlsAreNotAddedWhenCurrentUserHasNoPermission() throws Exception {
when(reportPermissionService.findAllPermittedUsersForCurrentUser())
- .thenReturn(List.of(new User(new UserId("batman"), new UserLocalId(1L), "", "", new EMailAddress(""))));
+ .thenReturn(List.of(new User(new UserId("batman"), new UserLocalId(1L), "", "", new EMailAddress(""), Set.of())));
when(reportService.getReportWeek(Year.of(2022), 1, new UserId("batman")))
.thenReturn(anyReportWeek());
@@ -174,9 +171,9 @@ void ensureWeekReportUserFilterRelatedUrlsAreNotAddedWhenCurrentUserHasNoPermiss
@Test
void ensureWeekReportUserFilterRelatedUrls() throws Exception {
- final User batman = new User(new UserId("batman"), new UserLocalId(1L), "Bruce", "Wayne", new EMailAddress(""));
- final User joker = new User(new UserId("joker"), new UserLocalId(2L), "Jack", "Napier", new EMailAddress(""));
- final User robin = new User(new UserId("robin"), new UserLocalId(3L), "Dick", "Grayson", new EMailAddress(""));
+ final User batman = new User(new UserId("batman"), new UserLocalId(1L), "Bruce", "Wayne", new EMailAddress(""), Set.of());
+ final User joker = new User(new UserId("joker"), new UserLocalId(2L), "Jack", "Napier", new EMailAddress(""), Set.of());
+ final User robin = new User(new UserId("robin"), new UserLocalId(3L), "Dick", "Grayson", new EMailAddress(""), Set.of());
when(reportPermissionService.findAllPermittedUsersForCurrentUser())
.thenReturn(List.of(batman, joker, robin));
@@ -198,9 +195,9 @@ void ensureWeekReportUserFilterRelatedUrls() throws Exception {
@Test
void ensureWeekReportUserFilterRelatedUrlsForEveryone() throws Exception {
- final User batman = new User(new UserId("batman"), new UserLocalId(1L), "Bruce", "Wayne", new EMailAddress(""));
- final User joker = new User(new UserId("joker"), new UserLocalId(2L), "Jack", "Napier", new EMailAddress(""));
- final User robin = new User(new UserId("robin"), new UserLocalId(3L), "Dick", "Grayson", new EMailAddress(""));
+ final User batman = new User(new UserId("batman"), new UserLocalId(1L), "Bruce", "Wayne", new EMailAddress(""), Set.of());
+ final User joker = new User(new UserId("joker"), new UserLocalId(2L), "Jack", "Napier", new EMailAddress(""), Set.of());
+ final User robin = new User(new UserId("robin"), new UserLocalId(3L), "Dick", "Grayson", new EMailAddress(""), Set.of());
when(reportPermissionService.findAllPermittedUsersForCurrentUser())
.thenReturn(List.of(batman, joker, robin));
@@ -226,9 +223,9 @@ void ensureWeekReportUserFilterRelatedUrlsForEveryone() throws Exception {
@Test
void ensureWeekReportUserFilterRelatedUrlsForWithSelectedUser() throws Exception {
- final User batman = new User(new UserId("batman"), new UserLocalId(1L), "Bruce", "Wayne", new EMailAddress(""));
- final User joker = new User(new UserId("joker"), new UserLocalId(2L), "Jack", "Napier", new EMailAddress(""));
- final User robin = new User(new UserId("robin"), new UserLocalId(3L), "Dick", "Grayson", new EMailAddress(""));
+ final User batman = new User(new UserId("batman"), new UserLocalId(1L), "Bruce", "Wayne", new EMailAddress(""), Set.of());
+ final User joker = new User(new UserId("joker"), new UserLocalId(2L), "Jack", "Napier", new EMailAddress(""), Set.of());
+ final User robin = new User(new UserId("robin"), new UserLocalId(3L), "Dick", "Grayson", new EMailAddress(""), Set.of());
when(reportPermissionService.findAllPermittedUsersForCurrentUser())
.thenReturn(List.of(batman, joker, robin));
@@ -357,7 +354,7 @@ void ensureMonthReportCsvDownloadUrlWithUsersParam() throws Exception {
void ensureMonthReportUserFilterRelatedUrlsAreNotAddedWhenCurrentUserHasNoPermission() throws Exception {
when(reportPermissionService.findAllPermittedUsersForCurrentUser())
- .thenReturn(List.of(new User(new UserId("batman"), new UserLocalId(1L), "", "", new EMailAddress(""))));
+ .thenReturn(List.of(new User(new UserId("batman"), new UserLocalId(1L), "", "", new EMailAddress(""), Set.of())));
when(reportService.getReportMonth(YearMonth.of(2022, 1), new UserId("batman")))
.thenReturn(anyReportMonth());
@@ -369,9 +366,9 @@ void ensureMonthReportUserFilterRelatedUrlsAreNotAddedWhenCurrentUserHasNoPermis
@Test
void ensureMonthReportUserFilterRelatedUrls() throws Exception {
- final User batman = new User(new UserId("batman"), new UserLocalId(1L), "Bruce", "Wayne", new EMailAddress(""));
- final User joker = new User(new UserId("joker"), new UserLocalId(2L), "Jack", "Napier", new EMailAddress(""));
- final User robin = new User(new UserId("robin"), new UserLocalId(3L), "Dick", "Grayson", new EMailAddress(""));
+ final User batman = new User(new UserId("batman"), new UserLocalId(1L), "Bruce", "Wayne", new EMailAddress(""), Set.of());
+ final User joker = new User(new UserId("joker"), new UserLocalId(2L), "Jack", "Napier", new EMailAddress(""), Set.of());
+ final User robin = new User(new UserId("robin"), new UserLocalId(3L), "Dick", "Grayson", new EMailAddress(""), Set.of());
when(reportPermissionService.findAllPermittedUsersForCurrentUser())
.thenReturn(List.of(batman, joker, robin));
@@ -393,9 +390,9 @@ void ensureMonthReportUserFilterRelatedUrls() throws Exception {
@Test
void ensureMonthReportUserFilterRelatedUrlsForEveryone() throws Exception {
- final User batman = new User(new UserId("batman"), new UserLocalId(1L), "Bruce", "Wayne", new EMailAddress(""));
- final User joker = new User(new UserId("joker"), new UserLocalId(2L), "Jack", "Napier", new EMailAddress(""));
- final User robin = new User(new UserId("robin"), new UserLocalId(3L), "Dick", "Grayson", new EMailAddress(""));
+ final User batman = new User(new UserId("batman"), new UserLocalId(1L), "Bruce", "Wayne", new EMailAddress(""), Set.of());
+ final User joker = new User(new UserId("joker"), new UserLocalId(2L), "Jack", "Napier", new EMailAddress(""), Set.of());
+ final User robin = new User(new UserId("robin"), new UserLocalId(3L), "Dick", "Grayson", new EMailAddress(""), Set.of());
when(reportPermissionService.findAllPermittedUsersForCurrentUser())
.thenReturn(List.of(batman, joker, robin));
@@ -421,9 +418,9 @@ void ensureMonthReportUserFilterRelatedUrlsForEveryone() throws Exception {
@Test
void ensureMonthReportUserFilterRelatedUrlsForWithSelectedUser() throws Exception {
- final User batman = new User(new UserId("batman"), new UserLocalId(1L), "Bruce", "Wayne", new EMailAddress(""));
- final User joker = new User(new UserId("joker"), new UserLocalId(2L), "Jack", "Napier", new EMailAddress(""));
- final User robin = new User(new UserId("robin"), new UserLocalId(3L), "Dick", "Grayson", new EMailAddress(""));
+ final User batman = new User(new UserId("batman"), new UserLocalId(1L), "Bruce", "Wayne", new EMailAddress(""), Set.of());
+ final User joker = new User(new UserId("joker"), new UserLocalId(2L), "Jack", "Napier", new EMailAddress(""), Set.of());
+ final User robin = new User(new UserId("robin"), new UserLocalId(3L), "Dick", "Grayson", new EMailAddress(""), Set.of());
when(reportPermissionService.findAllPermittedUsersForCurrentUser())
.thenReturn(List.of(batman, joker, robin));
diff --git a/src/test/java/de/focusshift/zeiterfassung/report/ReportCsvServiceTest.java b/src/test/java/de/focusshift/zeiterfassung/report/ReportCsvServiceTest.java
index 5abeba178..4b2110746 100644
--- a/src/test/java/de/focusshift/zeiterfassung/report/ReportCsvServiceTest.java
+++ b/src/test/java/de/focusshift/zeiterfassung/report/ReportCsvServiceTest.java
@@ -15,15 +15,11 @@
import java.io.PrintWriter;
import java.io.StringWriter;
-import java.time.LocalDate;
-import java.time.LocalDateTime;
-import java.time.Year;
-import java.time.YearMonth;
-import java.time.ZoneId;
-import java.time.ZonedDateTime;
+import java.time.*;
import java.time.format.DateTimeFormatter;
import java.util.List;
import java.util.Locale;
+import java.util.Set;
import static org.assertj.core.api.Assertions.assertThat;
import static org.mockito.ArgumentMatchers.any;
@@ -80,7 +76,7 @@ void ensureWeekReportCsvRoundsWorkedHoursToTwoDigit() {
mockDateFormatter("dd.MM.yyyy");
- final User batman = new User(new UserId("batman"), new UserLocalId(1L), "Bruce", "Wayne", new EMailAddress("batman@example.org"));
+ final User batman = new User(new UserId("batman"), new UserLocalId(1L), "Bruce", "Wayne", new EMailAddress("batman@example.org"), Set.of());
final ZonedDateTime from = ZonedDateTime.of(LocalDateTime.of(2021, 1, 4, 10, 0), ZONE_ID_BERLIN);
final ZonedDateTime to = ZonedDateTime.of(LocalDateTime.of(2021, 1, 4, 10, 30), ZONE_ID_BERLIN);
@@ -106,7 +102,7 @@ void ensureWeekReportCsvContainsSummarizedInfoPerDay() {
mockDateFormatter("dd.MM.yyyy");
- final User batman = new User(new UserId("batman"), new UserLocalId(1L), "Bruce", "Wayne", new EMailAddress("batman@example.org"));
+ final User batman = new User(new UserId("batman"), new UserLocalId(1L), "Bruce", "Wayne", new EMailAddress("batman@example.org"), Set.of());
// day one
final ZonedDateTime d1_1_From = ZonedDateTime.of(LocalDateTime.of(2021, 1, 4, 10, 0), ZONE_ID_BERLIN);
@@ -165,7 +161,7 @@ void ensureMonthReportCsvRoundsWorkedHoursToTwoDigit() {
mockDateFormatter("dd.MM.yyyy");
- final User batman = new User(new UserId("batman"), new UserLocalId(1L), "Bruce", "Wayne", new EMailAddress("batman@example.org"));
+ final User batman = new User(new UserId("batman"), new UserLocalId(1L), "Bruce", "Wayne", new EMailAddress("batman@example.org"), Set.of());
final ZonedDateTime from = ZonedDateTime.of(LocalDateTime.of(2021, 1, 4, 10, 0), ZONE_ID_BERLIN);
final ZonedDateTime to = ZonedDateTime.of(LocalDateTime.of(2021, 1, 4, 10, 30), ZONE_ID_BERLIN);
@@ -197,7 +193,7 @@ void ensureMonthReportCsvContainsSummarizedInfoPerDay() {
mockDateFormatter("dd.MM.yyyy");
- final User batman = new User(new UserId("batman"), new UserLocalId(1L), "Bruce", "Wayne", new EMailAddress("batman@example.org"));
+ final User batman = new User(new UserId("batman"), new UserLocalId(1L), "Bruce", "Wayne", new EMailAddress("batman@example.org"), Set.of());
// week one, day one
final ZonedDateTime d1_1_From = ZonedDateTime.of(LocalDateTime.of(2021, 1, 4, 10, 0), ZONE_ID_BERLIN);
diff --git a/src/test/java/de/focusshift/zeiterfassung/report/ReportPermissionServiceTest.java b/src/test/java/de/focusshift/zeiterfassung/report/ReportPermissionServiceTest.java
index 75713563c..ccf1fc238 100644
--- a/src/test/java/de/focusshift/zeiterfassung/report/ReportPermissionServiceTest.java
+++ b/src/test/java/de/focusshift/zeiterfassung/report/ReportPermissionServiceTest.java
@@ -14,6 +14,7 @@
import org.springframework.security.authentication.TestingAuthenticationToken;
import java.util.List;
+import java.util.Set;
import static de.focusshift.zeiterfassung.security.SecurityRoles.ZEITERFASSUNG_VIEW_REPORT_ALL;
import static org.assertj.core.api.Assertions.assertThat;
@@ -72,7 +73,7 @@ void ensureFilterUserLocalIdsByCurrentUserHasPermissionForReturnsListForCurrentU
.thenReturn(new TestingAuthenticationToken("", "", List.of()));
when(currentUserProvider.getCurrentUser())
- .thenReturn(new User(new UserId(""), new UserLocalId(2L), "", "", new EMailAddress("")));
+ .thenReturn(new User(new UserId(""), new UserLocalId(2L), "", "", new EMailAddress(""), Set.of()));
final List actual = sut.filterUserLocalIdsByCurrentUserHasPermissionFor(
List.of(new UserLocalId(1L), new UserLocalId(2L), new UserLocalId(3L)));
@@ -87,7 +88,7 @@ void ensureFilterUserLocalIdsByCurrentUserHasPermissionForReturnsEmptyList() {
.thenReturn(new TestingAuthenticationToken("", "", List.of()));
when(currentUserProvider.getCurrentUser())
- .thenReturn(new User(new UserId(""), new UserLocalId(2L), "", "", new EMailAddress("")));
+ .thenReturn(new User(new UserId(""), new UserLocalId(2L), "", "", new EMailAddress(""), Set.of()));
final List actual = sut.filterUserLocalIdsByCurrentUserHasPermissionFor(
List.of(new UserLocalId(1L), new UserLocalId(3L)));
@@ -103,9 +104,9 @@ void ensureFindAllPermittedUserLocalIdsForCurrentUser() {
when(userManagementService.findAllUsers())
.thenReturn(List.of(
- new User(new UserId(""), new UserLocalId(1L), "", "", new EMailAddress("")),
- new User(new UserId(""), new UserLocalId(2L), "", "", new EMailAddress("")),
- new User(new UserId(""), new UserLocalId(3L), "", "", new EMailAddress(""))
+ new User(new UserId(""), new UserLocalId(1L), "", "", new EMailAddress(""), Set.of()),
+ new User(new UserId(""), new UserLocalId(2L), "", "", new EMailAddress(""), Set.of()),
+ new User(new UserId(""), new UserLocalId(3L), "", "", new EMailAddress(""), Set.of())
));
assertThat(sut.findAllPermittedUserLocalIdsForCurrentUser())
@@ -119,7 +120,7 @@ void ensureFindAllPermittedUserLocalIdsForCurrentUserReturnsCurrentUserOnly() {
.thenReturn(new TestingAuthenticationToken("", "", List.of()));
when(currentUserProvider.getCurrentUser())
- .thenReturn(new User(new UserId(""), new UserLocalId(2L), "", "", new EMailAddress("")));
+ .thenReturn(new User(new UserId(""), new UserLocalId(2L), "", "", new EMailAddress(""), Set.of()));
assertThat(sut.findAllPermittedUserLocalIdsForCurrentUser()).containsOnly(new UserLocalId(2L));
}
@@ -131,9 +132,9 @@ void ensureFindAllPermittedUsersForCurrentUser() {
.thenReturn(new TestingAuthenticationToken("", "", List.of(ZEITERFASSUNG_VIEW_REPORT_ALL.authority())));
final List userList = List.of(
- new User(new UserId(""), new UserLocalId(1L), "", "", new EMailAddress("")),
- new User(new UserId(""), new UserLocalId(2L), "", "", new EMailAddress("")),
- new User(new UserId(""), new UserLocalId(3L), "", "", new EMailAddress(""))
+ new User(new UserId(""), new UserLocalId(1L), "", "", new EMailAddress(""), Set.of()),
+ new User(new UserId(""), new UserLocalId(2L), "", "", new EMailAddress(""), Set.of()),
+ new User(new UserId(""), new UserLocalId(3L), "", "", new EMailAddress(""), Set.of())
);
when(userManagementService.findAllUsers()).thenReturn(userList);
@@ -148,9 +149,9 @@ void ensureFindAllPermittedUsersForCurrentUserReturnsOnlyItself() {
.thenReturn(new TestingAuthenticationToken("", "", List.of()));
when(currentUserProvider.getCurrentUser())
- .thenReturn(new User(new UserId(""), new UserLocalId(2L), "", "", new EMailAddress("")));
+ .thenReturn(new User(new UserId(""), new UserLocalId(2L), "", "", new EMailAddress(""), Set.of()));
assertThat(sut.findAllPermittedUsersForCurrentUser())
- .containsOnly(new User(new UserId(""), new UserLocalId(2L), "", "", new EMailAddress("")));
+ .containsOnly(new User(new UserId(""), new UserLocalId(2L), "", "", new EMailAddress(""), Set.of()));
}
}
diff --git a/src/test/java/de/focusshift/zeiterfassung/report/ReportServiceRawTest.java b/src/test/java/de/focusshift/zeiterfassung/report/ReportServiceRawTest.java
index 0fb26f4e9..08eae653f 100644
--- a/src/test/java/de/focusshift/zeiterfassung/report/ReportServiceRawTest.java
+++ b/src/test/java/de/focusshift/zeiterfassung/report/ReportServiceRawTest.java
@@ -14,14 +14,9 @@
import org.mockito.Mock;
import org.mockito.junit.jupiter.MockitoExtension;
-import java.time.Duration;
-import java.time.LocalDate;
-import java.time.LocalDateTime;
-import java.time.Year;
-import java.time.YearMonth;
-import java.time.ZoneId;
-import java.time.ZonedDateTime;
+import java.time.*;
import java.util.List;
+import java.util.Set;
import static java.time.DayOfWeek.MONDAY;
import static org.assertj.core.api.Assertions.assertThat;
@@ -98,7 +93,7 @@ void ensureReportWeekWithOneTimeEntryADay() {
.thenReturn(List.of(firstTimeEntry, secondTimeEntry));
when(userManagementService.findAllUsersByIds(List.of(new UserId("batman"))))
- .thenReturn(List.of(new User(new UserId("batman"), new UserLocalId(1L), "Bruce", "Wayne", new EMailAddress("batman@example.org"))));
+ .thenReturn(List.of(new User(new UserId("batman"), new UserLocalId(1L), "Bruce", "Wayne", new EMailAddress("batman@example.org"), Set.of())));
final ReportWeek actualReportWeek = sut.getReportWeek(Year.of(2021), 1, new UserId("batman"));
@@ -130,7 +125,7 @@ void ensureReportWeekWithMultipleTimeEntriesADay() {
.thenReturn(List.of(morningTimeEntry, noonTimeEntry));
when(userManagementService.findAllUsersByIds(List.of(new UserId("batman"))))
- .thenReturn(List.of(new User(new UserId("batman"), new UserLocalId(1L), "Bruce", "Wayne", new EMailAddress("batman@example.org"))));
+ .thenReturn(List.of(new User(new UserId("batman"), new UserLocalId(1L), "Bruce", "Wayne", new EMailAddress("batman@example.org"), Set.of())));
final ReportWeek actualReportWeek = sut.getReportWeek(Year.of(2021), 1, new UserId("batman"));
@@ -158,7 +153,7 @@ void ensureReportWeekWithTimeEntryTouchingNextDayIsReportedForStartingDate() {
.thenReturn(List.of(timeEntry));
when(userManagementService.findAllUsersByIds(List.of(new UserId("batman"))))
- .thenReturn(List.of(new User(new UserId("batman"), new UserLocalId(1L), "Bruce", "Wayne", new EMailAddress("batman@example.org"))));
+ .thenReturn(List.of(new User(new UserId("batman"), new UserLocalId(1L), "Bruce", "Wayne", new EMailAddress("batman@example.org"), Set.of())));
final ReportWeek actualReportWeek = sut.getReportWeek(Year.of(2021), 1, new UserId("batman"));
@@ -259,7 +254,7 @@ void ensureReportMonthDecemberWithOneTimeEntryAWeek() {
.thenReturn(List.of(w1_d1_TimeEntry, w1_d2_TimeEntry, w2_d1_TimeEntry, w2_d2_TimeEntry, w3_d1_TimeEntry, w3_d2_TimeEntry, w4_d1_TimeEntry, w4_d2_TimeEntry));
when(userManagementService.findAllUsersByIds(List.of(batman)))
- .thenReturn(List.of(new User(batman, new UserLocalId(1L), "Bruce", "Wayne", new EMailAddress("batman@example.org"))));
+ .thenReturn(List.of(new User(batman, new UserLocalId(1L), "Bruce", "Wayne", new EMailAddress("batman@example.org"), Set.of())));
final ReportMonth actualReportMonth = sut.getReportMonth(YearMonth.of(2021, 1), batman);
diff --git a/src/test/java/de/focusshift/zeiterfassung/timeentry/TimeEntryRepositoryIT.java b/src/test/java/de/focusshift/zeiterfassung/timeentry/TimeEntryRepositoryIT.java
index 8fe0f121c..f3a7ee792 100644
--- a/src/test/java/de/focusshift/zeiterfassung/timeentry/TimeEntryRepositoryIT.java
+++ b/src/test/java/de/focusshift/zeiterfassung/timeentry/TimeEntryRepositoryIT.java
@@ -16,13 +16,9 @@
import org.springframework.security.oauth2.core.user.OAuth2User;
import org.springframework.test.annotation.Rollback;
-import java.time.Instant;
-import java.time.LocalDate;
-import java.time.LocalDateTime;
-import java.time.LocalTime;
-import java.time.ZoneId;
-import java.time.ZoneOffset;
+import java.time.*;
import java.util.List;
+import java.util.Set;
import java.util.UUID;
import static org.assertj.core.api.Assertions.assertThat;
@@ -46,8 +42,8 @@ void countAllByOwner() {
tenantService.create("ab143c2f");
prepareSecurityContextWithTenantId("ab143c2f");
- final TenantUser batman = tenantUserService.createNewUser(UUID.randomUUID(), "Bruce", "Wayne", new EMailAddress("batman@example.org"));
- final TenantUser superman = tenantUserService.createNewUser(UUID.randomUUID(), "Kent", "Clark", new EMailAddress("Clark@example.org"));
+ final TenantUser batman = tenantUserService.createNewUser(UUID.randomUUID(), "Bruce", "Wayne", new EMailAddress("batman@example.org"), Set.of());
+ final TenantUser superman = tenantUserService.createNewUser(UUID.randomUUID(), "Kent", "Clark", new EMailAddress("Clark@example.org"), Set.of());
final LocalDateTime anyDate = LocalDateTime.of(2022, 9, 24, 14, 0, 0, 0);
@@ -69,8 +65,8 @@ void ensureFindAllByOwnerForTimePeriodIncludesTimeEntryWithStartAtPeriodStartAnd
tenantService.create("ab143c2f");
prepareSecurityContextWithTenantId("ab143c2f");
- final TenantUser batman = tenantUserService.createNewUser(UUID.randomUUID(), "Bruce", "Wayne", new EMailAddress("batman@example.org"));
- final TenantUser superman = tenantUserService.createNewUser(UUID.randomUUID(), "Kent", "Clark", new EMailAddress("Clark@example.org"));
+ final TenantUser batman = tenantUserService.createNewUser(UUID.randomUUID(), "Bruce", "Wayne", new EMailAddress("batman@example.org"), Set.of());
+ final TenantUser superman = tenantUserService.createNewUser(UUID.randomUUID(), "Kent", "Clark", new EMailAddress("Clark@example.org"), Set.of());
final LocalDate periodFrom = LocalDate.of(2022, 1, 3);
final LocalDate periodToExclusive = LocalDate.of(2022, 1, 10);
@@ -114,8 +110,8 @@ void ensureFindAllByOwnerForTimePeriodIncludesTimeEntryWithStartWithinPeriodAndE
tenantService.create("ab143c2f");
prepareSecurityContextWithTenantId("ab143c2f");
- final TenantUser batman = tenantUserService.createNewUser(UUID.randomUUID(), "Bruce", "Wayne", new EMailAddress("batman@example.org"));
- final TenantUser superman = tenantUserService.createNewUser(UUID.randomUUID(), "Kent", "Clark", new EMailAddress("Clark@example.org"));
+ final TenantUser batman = tenantUserService.createNewUser(UUID.randomUUID(), "Bruce", "Wayne", new EMailAddress("batman@example.org"), Set.of());
+ final TenantUser superman = tenantUserService.createNewUser(UUID.randomUUID(), "Kent", "Clark", new EMailAddress("Clark@example.org"), Set.of());
final LocalDate periodFrom = LocalDate.of(2022, 1, 3);
final LocalDate periodToExclusive = LocalDate.of(2022, 1, 10);
@@ -159,8 +155,8 @@ void ensureFindAllByOwnerForTimePeriodIncludesTimeEntryWithStartBeforePeriodAndE
tenantService.create("ab143c2f");
prepareSecurityContextWithTenantId("ab143c2f");
- final TenantUser batman = tenantUserService.createNewUser(UUID.randomUUID(), "Bruce", "Wayne", new EMailAddress("batman@example.org"));
- final TenantUser superman = tenantUserService.createNewUser(UUID.randomUUID(), "Kent", "Clark", new EMailAddress("Clark@example.org"));
+ final TenantUser batman = tenantUserService.createNewUser(UUID.randomUUID(), "Bruce", "Wayne", new EMailAddress("batman@example.org"), Set.of());
+ final TenantUser superman = tenantUserService.createNewUser(UUID.randomUUID(), "Kent", "Clark", new EMailAddress("Clark@example.org"), Set.of());
final LocalDate periodFrom = LocalDate.of(2022, 1, 3);
final LocalDate periodToExclusive = LocalDate.of(2022, 1, 10);
@@ -204,8 +200,8 @@ void ensureFindAllByOwnerForTimePeriodIncludesTimeEntryWithStartBeforePeriodAndE
tenantService.create("ab143c2f");
prepareSecurityContextWithTenantId("ab143c2f");
- final TenantUser batman = tenantUserService.createNewUser(UUID.randomUUID(), "Bruce", "Wayne", new EMailAddress("batman@example.org"));
- final TenantUser superman = tenantUserService.createNewUser(UUID.randomUUID(), "Kent", "Clark", new EMailAddress("Clark@example.org"));
+ final TenantUser batman = tenantUserService.createNewUser(UUID.randomUUID(), "Bruce", "Wayne", new EMailAddress("batman@example.org"), Set.of());
+ final TenantUser superman = tenantUserService.createNewUser(UUID.randomUUID(), "Kent", "Clark", new EMailAddress("Clark@example.org"), Set.of());
final LocalDate periodFrom = LocalDate.of(2022, 1, 3);
final LocalDate periodToExclusive = LocalDate.of(2022, 1, 10);
@@ -249,8 +245,8 @@ void ensureFindAllByOwnerForTimePeriodIncludesTimeEntryStartingBeforePeriodAndEn
tenantService.create("ab143c2f");
prepareSecurityContextWithTenantId("ab143c2f");
- final TenantUser batman = tenantUserService.createNewUser(UUID.randomUUID(), "Bruce", "Wayne", new EMailAddress("batman@example.org"));
- final TenantUser superman = tenantUserService.createNewUser(UUID.randomUUID(), "Kent", "Clark", new EMailAddress("Clark@example.org"));
+ final TenantUser batman = tenantUserService.createNewUser(UUID.randomUUID(), "Bruce", "Wayne", new EMailAddress("batman@example.org"), Set.of());
+ final TenantUser superman = tenantUserService.createNewUser(UUID.randomUUID(), "Kent", "Clark", new EMailAddress("Clark@example.org"), Set.of());
final LocalDate periodFrom = LocalDate.of(2022, 1, 3);
final LocalDate periodToExclusive = LocalDate.of(2022, 1, 10);