[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]
[tor-commits] [stem/master] Stub address in get_exit_policy unit test
commit febe3f4128b49f1380a8f32f23e3c5a8466582d3
Author: Damian Johnson <atagar@xxxxxxxxxxxxxx>
Date: Tue Sep 25 16:16:15 2018 -0700
Stub address in get_exit_policy unit test
Ok, got it. Jenkins test runs are failing because it's expanding 'reject
private:*' to a different address. Completely understandable, our unit
tests should hardcode a test address.
---
test/unit/control/controller.py | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/test/unit/control/controller.py b/test/unit/control/controller.py
index 29be956f..ed00385d 100644
--- a/test/unit/control/controller.py
+++ b/test/unit/control/controller.py
@@ -218,7 +218,7 @@ class TestControl(unittest.TestCase):
'reject 192.168.0.0/16:*',
'reject 10.0.0.0/8:*',
'reject 172.16.0.0/12:*',
- 'reject 127.0.1.1:*',
+ 'reject 1.2.3.4:*',
'accept *:80',
'accept *:443',
'accept 43.5.5.5:*',
@@ -233,7 +233,7 @@ class TestControl(unittest.TestCase):
def getinfo_response(param, default = None):
if param == 'address':
- return default
+ return '1.2.3.4'
elif param == 'exit-policy/default':
return ''
elif param == 'exit-policy/full' and exit_policy_exception:
_______________________________________________
tor-commits mailing list
tor-commits@xxxxxxxxxxxxxxxxxxxx
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits