mirror of
https://github.com/pkkid/python-plexapi
synced 2024-11-10 14:14:19 +00:00
add ne and ne test.
This commit is contained in:
parent
bdee9ad1f1
commit
b5a3018c6b
2 changed files with 5 additions and 0 deletions
|
@ -11,6 +11,7 @@ OPERATORS = {
|
|||
'iexact': lambda v, q: v.lower() == q.lower(),
|
||||
'contains': lambda v, q: q in v,
|
||||
'icontains': lambda v, q: q.lower() in v.lower(),
|
||||
'ne': lambda v, q: v != q,
|
||||
'in': lambda v, q: v in q,
|
||||
'gt': lambda v, q: v > q,
|
||||
'gte': lambda v, q: v >= q,
|
||||
|
|
|
@ -10,6 +10,10 @@ def test_video_Movie(movies, movie):
|
|||
assert movie2.title == movie.title
|
||||
|
||||
|
||||
def test_video_ne(movies):
|
||||
assert len(movies.fetchItems('/library/sections/7/all', title__ne='Sintel')) == 3
|
||||
|
||||
|
||||
def test_video_Movie_delete(monkeypatch, movie):
|
||||
monkeypatch.delattr('requests.sessions.Session.request')
|
||||
with pytest.raises(AttributeError):
|
||||
|
|
Loading…
Reference in a new issue