diff options
Diffstat (limited to 'Lib/test/test_normalization.py')
-rw-r--r-- | Lib/test/test_normalization.py | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/Lib/test/test_normalization.py b/Lib/test/test_normalization.py index 96b1ba1..5884334 100644 --- a/Lib/test/test_normalization.py +++ b/Lib/test/test_normalization.py @@ -3,10 +3,17 @@ import unittest import sys import os -from unicodedata import normalize +from unicodedata import normalize, unidata_version TESTDATAFILE = "NormalizationTest.txt" -TESTDATAURL = "http://www.unicode.org/Public/5.1.0/ucd/" + TESTDATAFILE +TESTDATAURL = "http://www.unicode.org/Public/" + unidata_version + "/ucd/" + TESTDATAFILE + +if os.path.exists(TESTDATAFILE): + f = open(TESTDATAFILE) + l = f.readline() + f.close() + if not unidata_version in l: + os.unlink(TESTDATAFILE) class RangeError(Exception): pass |