Example #1
0
    def test_expand_url_path(self):
        path = '/test/one/'
        domain = 'test.com:8080'

        actual = expand_url_path(path, domain=domain)
        expected = 'test.com:8080/test/one/'
        self.assertEqual(actual, expected)

        path = '/test/two/'
        domain = 'test.com'

        actual = expand_url_path(path, domain=domain)
        expected = 'test.com/test/two/'
        self.assertEqual(actual, expected)
Example #2
0
 def get_verify_link(self):
     key = str(self.verify_key)
     path = reverse("verify", args=[key])
     return expand_url_path(path)
Example #3
0
 def get_verify_link(self):
     key = str(self.verify_key)
     path = reverse('verify', args=[key])
     return expand_url_path(path)