Browse files

Fixed staticfiles test that was broken on Windows due to the result o…

…f the stdout not being correctly handled as Unicode.

git-svn-id: bcc190cf-cafb-0310-a4f2-bffc1f526a37
  • Loading branch information...
1 parent 0ff6bbf commit bd0daa04f5c886c8eeebac0c48ef6a326cbf689e @jezdez jezdez committed Mar 18, 2011
Showing with 4 additions and 3 deletions.
  1. +4 −3 tests/regressiontests/staticfiles_tests/
7 tests/regressiontests/staticfiles_tests/
@@ -66,10 +66,10 @@ def setUp(self):
# To make sure SVN doesn't hangs itself with the non-ASCII characters
# during checkout, we actually create one file dynamically.
self._nonascii_filepath = os.path.join(
- TEST_ROOT, 'apps', 'test', 'static', 'test', u'fişier.txt')
+ TEST_ROOT, 'apps', 'test', 'static', 'test', u'fi\u015fier.txt')
f =, 'w', 'utf-8')
- f.write(u"fişier in the app dir")
+ f.write(u"fi\u015fier in the app dir")
@@ -183,7 +183,8 @@ def _get_file(self, filepath):
call_command('findstatic', filepath, all=False, verbosity='0')
lines = [l.strip() for l in sys.stdout.readlines()]
- contents =[1].strip(), "r", "utf-8").read()
+ contents =
+ smart_unicode(lines[1].strip()), "r", "utf-8").read()
sys.stdout = _stdout
return contents

0 comments on commit bd0daa0

Please sign in to comment.