front_foundation #9
@ -52,7 +52,8 @@ public class EntrepreneurApi {
|
||||
@DeleteMapping("/entrepreneur/sectionCells/{sectionCellId}")
|
||||
public void removeSectionCell(
|
||||
@PathVariable Long sectionCellId, @AuthenticationPrincipal Jwt principal) {
|
||||
entrepreneurApiService.removeSectionCell(sectionCellId, principal.getClaimAsString("email"));
|
||||
entrepreneurApiService.removeSectionCell(
|
||||
sectionCellId, principal.getClaimAsString("email"));
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -121,8 +121,7 @@ public class SharedApiServiceTest {
|
||||
// Assuming staticUnauthorizedMail is an entrepreneur NOT linked to staticAuthorizedProject
|
||||
// or staticUnauthorizedProject:
|
||||
when(mockUtilsService.isAllowedToCheckProject(eq(staticUnauthorizedMail), anyLong()))
|
||||
.thenReturn(
|
||||
false); // Unauthorized entrepreneur NOT allowed for ANY project ID by
|
||||
.thenReturn(false); // Unauthorized entrepreneur NOT allowed for ANY project ID by
|
||||
// default
|
||||
|
||||
// Add more specific mock setups here if needed for entrepreneur tests
|
||||
@ -626,8 +625,7 @@ public class SharedApiServiceTest {
|
||||
cell ->
|
||||
projectAppointmentsList.addAll(
|
||||
sectionCellService.getAppointmentsBySectionCellId(
|
||||
cell
|
||||
.getIdSectionCell()))); // Get appointments for
|
||||
cell.getIdSectionCell()))); // Get appointments for
|
||||
// those cells
|
||||
|
||||
Optional<Appointment> createdAppointmentOpt =
|
||||
@ -944,9 +942,7 @@ public class SharedApiServiceTest {
|
||||
.anyMatch(
|
||||
a ->
|
||||
a.getIdAppointment()
|
||||
.equals(
|
||||
otherApp
|
||||
.getIdAppointment()))); // Ensure
|
||||
.equals(otherApp.getIdAppointment()))); // Ensure
|
||||
// appointment from other project is not included
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user