From 5493925ea07aabc569d0f6cddffff49fda59383c Mon Sep 17 00:00:00 2001 From: Aldo Cortesi Date: Sat, 5 Jan 2013 20:29:46 +1300 Subject: CONNECT through proxy mode for pathoc Also, use this to unit test the pathod CONNECT implementation. --- test/tutils.py | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'test/tutils.py') diff --git a/test/tutils.py b/test/tutils.py index 0a5455a3..580174d9 100644 --- a/test/tutils.py +++ b/test/tutils.py @@ -44,11 +44,11 @@ class DaemonTests: def get(self, spec): return requests.get(self.d.p(spec), verify=False) - def pathoc(self, spec, timeout=None): - c = pathoc.Pathoc("localhost", self.d.port) - c.connect() - if self.ssl: - c.convert_to_ssl() + def pathoc(self, spec, timeout=None, connect_to=None, ssl=None): + if ssl is None: + ssl = self.ssl + c = pathoc.Pathoc("localhost", self.d.port, ssl=ssl) + c.connect(connect_to) if timeout: c.settimeout(timeout) return c.request(spec) -- cgit v1.2.3