diff options
author | Calum Lind <calumlind+deluge@gmail.com> | 2021-08-01 08:33:59 +0100 |
---|---|---|
committer | Calum Lind <calumlind+deluge@gmail.com> | 2021-08-01 08:35:17 +0100 |
commit | e1e0999de6575519be3567e72f65b3927bb9f362 (patch) | |
tree | 61c0209b7ff28547c181b056d4d0a4935e6ad7e3 | |
parent | 5c9378ac5e86aa9700b4c941fa70bc036329e766 (diff) | |
download | deluge-e1e0999de6575519be3567e72f65b3927bb9f362.tar.gz deluge-e1e0999de6575519be3567e72f65b3927bb9f362.tar.bz2 deluge-e1e0999de6575519be3567e72f65b3927bb9f362.zip |
[Tests] Fix skipping torrent test for libtorrent >= 1.2
Test is still failing with libtorrent 2 so also skip.
-rw-r--r-- | deluge/tests/test_torrent.py | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/deluge/tests/test_torrent.py b/deluge/tests/test_torrent.py index 960a22aed..5da817924 100644 --- a/deluge/tests/test_torrent.py +++ b/deluge/tests/test_torrent.py @@ -20,7 +20,7 @@ import deluge.component as component import deluge.core.torrent import deluge.tests.common as common from deluge._libtorrent import lt -from deluge.common import utf8_encode_structure, windows_check +from deluge.common import VersionSplit, utf8_encode_structure, windows_check from deluge.core.core import Core from deluge.core.rpcserver import RPCServer from deluge.core.torrent import Torrent @@ -217,8 +217,8 @@ class TorrentTestCase(BaseTestCase): def test_torrent_error_resume_data_unaltered(self): if windows_check(): raise unittest.SkipTest('unexpected end of file in bencoded string') - if lt.__version__.split('.')[1] == '2': - raise unittest.SkipTest('Test not working as expected on lt 1.2') + if VersionSplit(lt.__version__) >= VersionSplit('1.2.0.0'): + raise unittest.SkipTest('Test not working as expected on lt 1.2 or greater') resume_data = { 'active_time': 13399, |