Exemple #1
0
 def test_encode_decode(self):
     """Encode and Decode should be able to run one on the result of the
     other and return the original"""
     original = URL(u'https://w3af.com:443/file.asp?id=1%202')
     encoded = original.url_encode()
     decoded = URL(encoded).url_decode()
     self.assertEqual(original, decoded)
Exemple #2
0
 def test_encode_decode(self):
     """Encode and Decode should be able to run one on the result of the
     other and return the original"""
     original = URL(u'https://w3af.com:443/file.asp?id=1%202')
     encoded = original.url_encode()
     decoded = URL(encoded).url_decode()
     self.assertEqual(original, decoded)
Exemple #3
0
 def test_url_encode_non_ascii(self):
     u = URL('http://w3af.com/foo/á.txt')
     self.assertEqual(u.url_encode(), u'http://w3af.com/foo/%C3%A1.txt')
Exemple #4
0
 def test_url_encode_non_ascii(self):
     u = URL('http://w3af.com/foo/á.txt')
     self.assertEqual(u.url_encode(), u'http://w3af.com/foo/%C3%A1.txt')