diff options
author | Georg Brandl <georg@python.org> | 2013-01-09 15:17:02 +0100 |
---|---|---|
committer | Georg Brandl <georg@python.org> | 2013-01-09 15:17:02 +0100 |
commit | 1f5bc0f3209f8f62a11a9b1181f22180e8916d25 (patch) | |
tree | c031ad54a2f53dd96bda68f5eb6c12a183344ed4 /tests/test_examplefiles.py | |
parent | eaca2a8debdcbb647175ba796cfd24f9c1faef34 (diff) | |
parent | 9cc134d20b8505b6d472cca6872406dbecf5fda3 (diff) | |
download | pygments-1f5bc0f3209f8f62a11a9b1181f22180e8916d25.tar.gz |
Merged in fengxx/pygments-dev/v1.6 (pull request #122: Add AutoIt script lexer)
Diffstat (limited to 'tests/test_examplefiles.py')
-rw-r--r-- | tests/test_examplefiles.py | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/tests/test_examplefiles.py b/tests/test_examplefiles.py index 41acf4ef..d785cf3b 100644 --- a/tests/test_examplefiles.py +++ b/tests/test_examplefiles.py @@ -3,7 +3,7 @@ Pygments tests with example files ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - :copyright: Copyright 2006-2012 by the Pygments team, see AUTHORS. + :copyright: Copyright 2006-2013 by the Pygments team, see AUTHORS. :license: BSD, see LICENSE for details. """ @@ -58,6 +58,8 @@ def check_lexer(lx, absfn, outfn): text = text.strip(b('\n')) + b('\n') try: text = text.decode('utf-8') + if text.startswith(u'\ufeff'): + text = text[len(u'\ufeff'):] except UnicodeError: text = text.decode('latin1') ntext = [] |