diff options
author | RaNaN <Mast3rRaNaN@hotmail.de> | 2012-01-16 21:07:09 +0100 |
---|---|---|
committer | RaNaN <Mast3rRaNaN@hotmail.de> | 2012-01-16 21:07:09 +0100 |
commit | 00ea635a0528619c0ff2f09e8781418f4207504e (patch) | |
tree | 9e443411b1f174293eca9a4bd0ff585e3fd019ba | |
parent | hosterlinks.txt - little fix (diff) | |
download | pyload-00ea635a0528619c0ff2f09e8781418f4207504e.tar.xz |
unicode fix
-rw-r--r-- | tests/HosterPluginTester.py | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/tests/HosterPluginTester.py b/tests/HosterPluginTester.py index 23e9507f1..2dd674367 100644 --- a/tests/HosterPluginTester.py +++ b/tests/HosterPluginTester.py @@ -96,6 +96,7 @@ class HosterPluginTester(PluginTester): c = Core() +# decode everything as unicode f = codecs.open(join(dirname(__file__), "hosterlinks.txt"), "r", "utf_8") links = [x.strip() for x in f.readlines()] urls = [] @@ -106,12 +107,12 @@ for l in links: if l.startswith("http"): if "||" in l: l, flag = l.split("||") - flags[l] = flag.strip() + flags[l] = str(flag.strip()) urls.append(l) elif len(l.rsplit(" ", 1)) == 2: name, hash = l.rsplit(" ", 1) - HosterPluginTester.files[name] = hash + HosterPluginTester.files[name] = str(hash) hoster, c = c.pluginManager.parseUrls(urls) @@ -147,4 +148,4 @@ for plugin, urls in plugins.iteritems(): #register class locals()[plugin] = _testerClass # remove from locals, or tested twice - del _testerClass
\ No newline at end of file + del _testerClass |