Skip to content

Commit

Permalink
[#553] Test whether unicode urls break url comparison
Browse files Browse the repository at this point in the history
  • Loading branch information
domoritz committed Mar 5, 2013
1 parent 1d6b899 commit b15e688
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions ckan/tests/lib/test_datapreview.py
@@ -1,3 +1,4 @@
# -*- coding: utf-8 -*-
import ckan.lib.datapreview as datapreview


Expand All @@ -20,6 +21,8 @@ def test_compare_domains(self):

assert comp(['http://de.okfn.org', 'http:www.foo.com']) is False

assert comp(['httpö://wöwöwö.ckan.dö', 'www.ckän.örg']) is False
assert comp(['www.ckän.örg', 'www.ckän.örg']) is True

# Wrong URL. Makes urlparse choke
assert comp(['http://Server=cda3; Service=sde:sqlserver:cda3; Database=NationalDatasets; User=sde; Version=sde.DEFAULT', 'http://www.okf.org']) is False

0 comments on commit b15e688

Please sign in to comment.