diff --git a/src/wormhole/test/test_transit.py b/src/wormhole/test/test_transit.py index 8b17dad..0f13523 100644 --- a/src/wormhole/test/test_transit.py +++ b/src/wormhole/test/test_transit.py @@ -171,6 +171,11 @@ class Basic(unittest.TestCase): d.addBoth(results.append) hints = results[0] c._stop_listening() + # If there are non-localhost hints, then localhost hints should be + # removed. But if the only hint is localhost, it should stay. + if len(hints) == 1: + if hints[0][u'hostname'] == u'127.0.0.1': + return for hint in hints: self.assertFalse(hint[u'hostname'] == u'127.0.0.1')