1
0
mirror of https://github.com/yt-dlp/yt-dlp.git synced 2025-06-27 17:08:32 +00:00

[test:update] fix Ruff style warnings in test_update.py

This commit is contained in:
moonshinerd 2025-06-09 00:15:56 -03:00
parent 17f278b555
commit 2720157593

View File

@ -249,12 +249,12 @@ def make_updater(target, *, current_version=None,
if api_response is not None:
upd._call_api = lambda _: api_response
return upd
def test(target, expected, current_version=None, current_commit=None, identifier=None):
updater = make_updater(target, current_version=current_version, current_commit=current_commit, identifier=identifier)
update_info = updater.query_update(_output=True)
self.assertDictEqual(update_info.__dict__ if update_info else {}, expected.__dict__ if expected else {})
def test_version_info_error(api_response, expected_msg):
updater = make_updater('stable', api_response=api_response)
stderr = io.StringIO()
@ -298,7 +298,7 @@ def test_version_info_error(api_response, expected_msg):
'body': '- Implements extra parameter validation\n'
'- Optimizes performance in date parser\n',
},
expected_msg="One of either version or commit hash must be available on the release"
expected_msg='One of either version or commit hash must be available on the release',
)
if __name__ == '__main__':