mirror of
https://github.com/LukeHagar/plexpy.git
synced 2025-12-07 04:20:54 +00:00
75 lines
3.8 KiB
Python
75 lines
3.8 KiB
Python
"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT."""
|
|
|
|
from plex_api_client import PlexAPI
|
|
from plex_api_client.models import operations
|
|
|
|
|
|
def test_updater_get_update_status():
|
|
s = PlexAPI(
|
|
access_token="<YOUR_API_KEY_HERE>",
|
|
)
|
|
|
|
assert s is not None
|
|
|
|
res = s.updater.get_update_status()
|
|
assert res.status_code == 200
|
|
assert res.object is not None
|
|
assert res.object == operations.GetUpdateStatusResponseBody(
|
|
media_container=operations.GetUpdateStatusMediaContainer(
|
|
size=1,
|
|
can_install=False,
|
|
checked_at=1705801232,
|
|
download_url="https://plex.tv/downloads/latest/5?channel=8&build=linux-x86_64&distro=redhat&X-Plex-Token=xxxxxxxxxxxxxxxxxxxx",
|
|
status=0,
|
|
release=[
|
|
operations.Release(
|
|
key="https://plex.tv/updater/releases/5136",
|
|
version="1.40.0.7775-456fbaf97",
|
|
added="(PLEASE NOTE) This version makes changes to the database which will make it compatible only with server versions 1.31.2 or higher (released March 14). You will not be able to use your database on Plex Media Server versions lower than this after this update. Please also be patient when updating to this version if you have a very large database and allow the upgrade process to finish.\n"
|
|
+ "(Collections) Items added to a collection from the item context menu will now lock the collection field on the items (#12793)\n"
|
|
+ "(Music) Store track genres and add filtering options (#14653)\n"
|
|
+ "(Music) Support ID3v2.4 null-separated tags for genres and release type (#14653)\n"
|
|
+ "(View History) No longer create a view history entry for items marked as played (#10888)\n"
|
|
+ "(Web) Updated to 4.118.0",
|
|
fixed="(Agents) Changing a 'Other Videos' type library to the modern movie agent would fail (#14483)\n"
|
|
+ "(Agents) It is possible that agents are not initialised during startup on rare occasions (#14654)\n"
|
|
+ "(Agents) Remove the legacy OpenSubtitles agent which is no longer supported upstream (#14667)\n"
|
|
+ "(Collection) Server could become unresponsive when collection membership changes (#14612)\n"
|
|
+ "(DVR) Previously watched recordings could be deleted without being watched again (#13779)\n"
|
|
+ "(Libraries) When performing fix match on items from certain music libraries the language would default to Arabic (#14501)\n"
|
|
+ "(Library) The Content Rating not equal to None filter does not work (#14620)\n"
|
|
+ "(Search) Album search results could contain all the album's tracks too (#14486)\n"
|
|
+ "(Subtitles) In some circumstances, sidecar subtitles can show up for media when they're no longer available (#14674)\n"
|
|
+ "(Transcoder) HW encoding would fail on devices with no rate control (#14222)\n"
|
|
+ "(Transcoder) Software transcoding on Ubuntu could cause unexpected behavior (#14605)",
|
|
download_url="https://plex.tv/downloads/latest/5?channel=8&build=linux-x86_64&distro=redhat&X-Plex-Token=xxxxxxxxxxxxxxxxxxxx",
|
|
state="notify",
|
|
),
|
|
],
|
|
),
|
|
)
|
|
|
|
|
|
def test_updater_check_for_updates_():
|
|
s = PlexAPI(
|
|
access_token="<YOUR_API_KEY_HERE>",
|
|
)
|
|
|
|
assert s is not None
|
|
|
|
res = s.updater.check_for_updates(download=operations.Download.ONE)
|
|
assert res.status_code == 200
|
|
|
|
|
|
def test_updater_apply_updates_():
|
|
s = PlexAPI(
|
|
access_token="<YOUR_API_KEY_HERE>",
|
|
)
|
|
|
|
assert s is not None
|
|
|
|
res = s.updater.apply_updates(
|
|
tonight=operations.Tonight.ONE, skip=operations.Skip.ONE
|
|
)
|
|
assert res.status_code == 200
|