1
0
mirror of https://github.com/mikf/gallery-dl.git synced 2024-11-25 04:02:32 +01:00

fix job tests for Python 3.4 and 3.5

assert_called() and assert_not_called() got added in Python 3.6
This commit is contained in:
Mike Fährmann 2021-05-22 20:57:47 +02:00
parent 724ca61f36
commit da6806a161
No known key found for this signature in database
GPG Key ID: 5680CA389D365A88

View File

@ -276,12 +276,12 @@ class TestDataJob(TestJob):
with patch("gallery_dl.util.number_to_string") as nts:
tjob.run()
nts.assert_not_called()
self.assertEqual(len(nts.call_args_list), 0)
config.set(("output",), "num-to-str", True)
with patch("gallery_dl.util.number_to_string") as nts:
tjob.run()
nts.assert_called()
self.assertEqual(len(nts.call_args_list), 52)
tjob.run()
self.assertEqual(tjob.data[-1][0], Message.Url)