Fix: Two users cannot put the same book on their Kobo shelves (#1189)
This commit is contained in:
+2
-2
@@ -192,12 +192,12 @@ class OpdsServiceTest {
|
||||
|
||||
when(request.getHeader("Accept")).thenReturn(null); // v1 default; feed version not relevant for allowed-books logic
|
||||
when(request.getRequestURI()).thenReturn("/opds/catalog");
|
||||
when(bookQueryService.getAllBooksByLibraryIds(Set.of(7L), true)).thenReturn(List.of());
|
||||
when(bookQueryService.getAllBooksByLibraryIds(Set.of(7L), true, 21L)).thenReturn(List.of());
|
||||
|
||||
String feed = service.generateCatalogFeed(request);
|
||||
|
||||
assertNotNull(feed);
|
||||
verify(bookQueryService).getAllBooksByLibraryIds(Set.of(7L), true);
|
||||
verify(bookQueryService).getAllBooksByLibraryIds(Set.of(7L), true, 21L);
|
||||
verify(userRepository).findById(21L);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user