From 3bd3f8eda2f01ab1d2368640f086515f5087aa42 Mon Sep 17 00:00:00 2001 From: Dmitri Bogomolov <4glitch@gmail.com> Date: Tue, 27 Jul 2021 00:58:21 +0300 Subject: [PATCH] Separate the test using protocol.checkSocksIP() and skip it on python3 Closes: #1792 --- src/tests/test_protocol.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/tests/test_protocol.py b/src/tests/test_protocol.py index d612b934..ee649481 100644 --- a/src/tests/test_protocol.py +++ b/src/tests/test_protocol.py @@ -2,6 +2,7 @@ Tests for common protocol functions """ +import sys import unittest from pybitmessage import protocol, state @@ -67,6 +68,10 @@ class TestProtocol(unittest.TestCase): self.assertFalse(protocol.checkIPAddress(globalhost, True)) self.assertEqual(protocol.checkIPAddress(globalhost), '8.8.8.8') + @unittest.skipIf( + sys.hexversion >= 0x3000000, 'this is still not working with python3') + def test_check_local_socks(self): + """The SOCKS part of the local check""" self.assertTrue( not protocol.checkSocksIP('127.0.0.1') or state.socksIP)