Exemple #1
0
 def test_full_url_override(self):
     """
     User can override url to be whatever they like
     """
     subject = HelloSign()
     subject.url = 'http://example.com/test/my/url'
     eq_(subject.url, 'http://example.com/test/my/url')
Exemple #2
0
    def test_url_path_override(self):
        """
        Allow user to manually specify a path
        useful for when a dynamic part of a url is required
        """
        subject = HelloSign()
        subject.url = 'my/special/path'
        eq_(subject.url, 'https://api.hellosign.com/v3/my/special/path')

        subject.url = '//my/special/path'  # note the double slash
        eq_(subject.url, 'https://api.hellosign.com/v3/my/special/path')