diff --git a/src/tests/core.py b/src/tests/core.py index 172ae219..cf70689d 100644 --- a/src/tests/core.py +++ b/src/tests/core.py @@ -245,6 +245,16 @@ class TestCore(unittest.TestCase): self._initiate_bootstrap() self._check_connection() self._check_knownnodes() + # spend another 30 sec to check maxoutboundconnections + for _ in range(30): + time.sleep(1) + self.assertLessEqual( + len([ + con + for con in BMConnectionPool().outboundConnections.values() + if con.fullyEstablished]), + BMConfigParser().safeGetInt( + 'bitmessagesettings', 'maxoutboundconnections')) @unittest.skipIf(tor_port_free, 'no running tor detected') def test_bootstrap_tor(self):