|
2 | 2 | import pytest |
3 | 3 | from plexapi.exceptions import NotFound |
4 | 4 | from . import conftest as utils |
| 5 | +from time import sleep |
5 | 6 |
|
6 | 7 |
|
7 | 8 | def test_library_Library_section(plex): |
@@ -201,6 +202,41 @@ def test_library_and_section_search_for_movie(plex): |
201 | 202 | assert l_search == s_search |
202 | 203 |
|
203 | 204 |
|
| 205 | +def test_library_colletion_hide(collection): |
| 206 | + collection.modeUpdate(mode='hide') |
| 207 | + collection.reload() |
| 208 | + assert collection.collectionMode == '0' |
| 209 | + |
| 210 | + |
| 211 | +def test_library_colletion_default(collection): |
| 212 | + collection.modeUpdate(mode='default') |
| 213 | + collection.reload() |
| 214 | + assert collection.collectionMode == '-2' |
| 215 | + |
| 216 | + |
| 217 | +def test_library_colletion_hideItems(collection): |
| 218 | + collection.modeUpdate(mode='hideItems') |
| 219 | + collection.reload() |
| 220 | + assert collection.collectionMode == '1' |
| 221 | + |
| 222 | + |
| 223 | +def test_library_colletion_showItems(collection): |
| 224 | + collection.modeUpdate(mode='showItems') |
| 225 | + collection.reload() |
| 226 | + assert collection.collectionMode == '2' |
| 227 | + |
| 228 | + |
| 229 | +def test_library_colletion_sortAlpha(collection): |
| 230 | + collection.sortUpdate(mode='alpha') |
| 231 | + collection.reload() |
| 232 | + assert collection.collectionMode == '1' |
| 233 | + |
| 234 | + |
| 235 | +def test_library_colletion_sortRelease(collection): |
| 236 | + collection.sortUpdate(mode='release') |
| 237 | + collection.reload() |
| 238 | + assert collection.collectionMode == '0' |
| 239 | + |
204 | 240 | # This started failing on more recent Plex Server builds |
205 | 241 | @pytest.mark.xfail |
206 | 242 | def test_search_with_apostrophe(plex): |
|
0 commit comments