mirror of
https://github.com/tahoe-lafs/tahoe-lafs.git
synced 2025-01-19 11:16:24 +00:00
These values aren't used for the exercised codepaths
So just use None instead. Kind of a weak fix but a fix nonetheless.
This commit is contained in:
parent
89441d9169
commit
d29d9c57e7
@ -791,9 +791,7 @@ class Listeners(unittest.TestCase):
|
|||||||
|
|
||||||
with mock.patch("allmydata.node.Tub", return_value=t):
|
with mock.patch("allmydata.node.Tub", return_value=t):
|
||||||
with self.assertRaises(ValueError) as ctx:
|
with self.assertRaises(ValueError) as ctx:
|
||||||
i2p_provider = mock.Mock()
|
create_main_tub(config, tub_options, dfh, fch, None, None)
|
||||||
tor_provider = mock.Mock()
|
|
||||||
create_main_tub(config, tub_options, dfh, fch, i2p_provider, tor_provider)
|
|
||||||
self.assertIn(
|
self.assertIn(
|
||||||
"you must choose",
|
"you must choose",
|
||||||
str(ctx.exception),
|
str(ctx.exception),
|
||||||
@ -835,9 +833,7 @@ class Listeners(unittest.TestCase):
|
|||||||
t = FakeTub()
|
t = FakeTub()
|
||||||
|
|
||||||
with mock.patch("allmydata.node.Tub", return_value=t):
|
with mock.patch("allmydata.node.Tub", return_value=t):
|
||||||
i2p_provider = mock.Mock()
|
create_main_tub(config, tub_options, dfh, fch, None, None)
|
||||||
tor_provider = mock.Mock()
|
|
||||||
create_main_tub(config, tub_options, dfh, fch, i2p_provider, tor_provider)
|
|
||||||
self.assertEqual(t.listening_ports,
|
self.assertEqual(t.listening_ports,
|
||||||
["tcp:%d:interface=127.0.0.1" % port1,
|
["tcp:%d:interface=127.0.0.1" % port1,
|
||||||
"tcp:%d:interface=127.0.0.1" % port2])
|
"tcp:%d:interface=127.0.0.1" % port2])
|
||||||
|
Loading…
Reference in New Issue
Block a user