Esempio n. 1
0
 def __init__(self,
              key,
              secure=True,
              retry_delay=None,
              backoff=None,
              timeout=None):
     # override __init__ so that we can set secure of False for testing
     ConnectionKey.__init__(self,
                            key,
                            secure,
                            timeout=timeout,
                            retry_delay=retry_delay,
                            backoff=backoff)
Esempio n. 2
0
 def request(self, action, params=None, data='', headers=None, method='GET'):
     if not headers:
         headers = {}
     if not params:
         params = {}
     # Override this method to prepend the api_context
     return ConnectionKey.request(self, self.api_context + action,
                                  params, data, headers, method)
Esempio n. 3
0
 def request(self, action, params=None, data='', headers=None, method='GET'):
     if not headers:
         headers = {}
     if not params:
         params = {}
     # Override this method to prepend the api_context
     return ConnectionKey.request(self, self.api_context + action,
                                  params, data, headers, method)
Esempio n. 4
0
 def __init__(self, key, secure=True):
     # override __init__ so that we can set secure of False for testing
     ConnectionKey.__init__(self, key, secure)
Esempio n. 5
0
 def test_base_connection_key(self):
     ConnectionKey('foo')
Esempio n. 6
0
 def test_base_response(self):
     Response(MockResponse(status=200, body='foo'), ConnectionKey('foo'))
 def __init__(self, key, secure=True):
     # override __init__ so that we can set secure of False for testing
     ConnectionKey.__init__(self, key, secure)
Esempio n. 8
0
 def test_base_connection_key(self):
     ConnectionKey("foo")
Esempio n. 9
0
 def __init__(self, key, secure=True, retry_delay=None,
              backoff=None, timeout=None):
     # override __init__ so that we can set secure of False for testing
     ConnectionKey.__init__(self, key, secure, timeout=timeout,
                            retry_delay=retry_delay, backoff=backoff)