mirror of
https://github.com/advplyr/audiobookshelf.git
synced 2025-06-24 17:59:06 +02:00
Remove req.oldLibraryItem usage
This commit is contained in:
parent
eb853d9f09
commit
5cd14108f9
2 changed files with 20 additions and 22 deletions
|
@ -83,12 +83,10 @@ describe('LibraryItemController', () => {
|
|||
|
||||
it('should remove authors and series with no books on library item delete', async () => {
|
||||
const libraryItem = await Database.libraryItemModel.getExpandedById(libraryItem1Id)
|
||||
const oldLibraryItem = Database.libraryItemModel.getOldLibraryItem(libraryItem)
|
||||
|
||||
const fakeReq = {
|
||||
query: {},
|
||||
libraryItem,
|
||||
oldLibraryItem
|
||||
libraryItem
|
||||
}
|
||||
const fakeRes = {
|
||||
sendStatus: sinon.spy()
|
||||
|
@ -159,7 +157,6 @@ describe('LibraryItemController', () => {
|
|||
|
||||
it('should remove authors and series with no books on library item update media', async () => {
|
||||
const libraryItem = await Database.libraryItemModel.getExpandedById(libraryItem1Id)
|
||||
const oldLibraryItem = Database.libraryItemModel.getOldLibraryItem(libraryItem)
|
||||
|
||||
// Update library item 1 remove all authors and series
|
||||
const fakeReq = {
|
||||
|
@ -170,8 +167,7 @@ describe('LibraryItemController', () => {
|
|||
series: []
|
||||
}
|
||||
},
|
||||
libraryItem,
|
||||
oldLibraryItem
|
||||
libraryItem
|
||||
}
|
||||
const fakeRes = {
|
||||
json: sinon.spy()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue