mirror of
https://github.com/unshackle-dl/unshackle.git
synced 2026-11-27 03:15:08 +00:00
fix(api): cache the health update check and fix a remote-session test fixture
This commit is contained in:
+1
-4
@@ -37,10 +37,7 @@ def loopback_only(request: pytest.FixtureRequest, monkeypatch: pytest.MonkeyPatc
|
||||
def no_update_check(monkeypatch: pytest.MonkeyPatch) -> None:
|
||||
"""Keep the release lookup of the health route off the network."""
|
||||
|
||||
async def no_release(*args: Any, **kwargs: Any) -> None:
|
||||
return None
|
||||
|
||||
monkeypatch.setattr(UpdateChecker, "check_for_updates", no_release)
|
||||
monkeypatch.setattr(UpdateChecker, "check_for_updates_sync", lambda *args, **kwargs: None)
|
||||
|
||||
|
||||
@pytest.fixture(autouse=True)
|
||||
|
||||
@@ -121,6 +121,7 @@ def test_remote_get_tracks_scopes_server_cookies():
|
||||
service.__dict__.update(
|
||||
_tracks_by_title={},
|
||||
_chapters_by_title={},
|
||||
_title_alias={},
|
||||
_sample_decrypt_tracks=set(),
|
||||
_server_cdm=None,
|
||||
_session=requests.Session(),
|
||||
|
||||
Reference in New Issue
Block a user