mirror of
https://github.com/pkkid/python-plexapi
synced 2024-11-22 03:33:08 +00:00
addToWatchlist
raise NotFound
exception for invalid media (#1401)
This commit is contained in:
parent
f5126a7ff1
commit
bf925c60e1
2 changed files with 4 additions and 2 deletions
|
@ -963,7 +963,9 @@ class MyPlexAccount(PlexObject):
|
|||
objects to be added to the watchlist.
|
||||
|
||||
Raises:
|
||||
:exc:`~plexapi.exceptions.BadRequest`: When trying to add invalid or existing
|
||||
:exc:`~plexapi.exceptions.BadRequest`: When trying to add existing
|
||||
media to the watchlist.
|
||||
:exc:`~plexapi.exceptions.NotFound`: When trying to add invalid
|
||||
media to the watchlist.
|
||||
"""
|
||||
if not isinstance(items, list):
|
||||
|
|
|
@ -310,7 +310,7 @@ def test_myplex_watchlist(account, movie, show, artist):
|
|||
account.removeFromWatchlist(movie)
|
||||
|
||||
# Test adding invalid item to watchlist
|
||||
with pytest.raises(BadRequest):
|
||||
with pytest.raises(NotFound):
|
||||
account.addToWatchlist(artist)
|
||||
|
||||
|
||||
|
|
Loading…
Reference in a new issue