Opened 9 years ago

Closed 9 years ago

#16203 closed Bug (fixed)

'servers' test fails on Windows

Reported by: Dmitry Jemerov Owned by: nobody
Component: contrib.admin Version: 1.3
Severity: Release blocker Keywords:
Cc: Triage Stage: Accepted
Has patch: yes Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no


The failure happens because the expected path is normalized with os.path.normcase, but the actually returned path is not.

C:\Python27\python.exe C:/src/django/django/tests/ --settings=test_sqlite servers
Creating test database for alias 'default'...
Creating test database for alias 'other'...
FAIL: test_media_urls (regressiontests.servers.tests.AdminMediaHandlerTests)
Traceback (most recent call last):
  File "C:\src\django\django\tests\regressiontests\servers\", line 62, in test_media_urls
    "Got: %s, Expected: %s, URL was: %s" % (output, desired, url))
AssertionError: Got: C:\src\django\django\django\contrib\admin\media\css\base.css, Expected: c:\src\django\django\django\contrib\admin\media\css\base.css, URL was: /static/admin/css/base.css

Ran 1 test in 0.001s

FAILED (failures=1)
Destroying test database for alias 'default'...
Destroying test database for alias 'other'...

Attachments (1)

16203.diff (598 bytes) - added by Dmitry Jemerov 9 years ago.

Download all attachments as: .zip

Change History (3)

Changed 9 years ago by Dmitry Jemerov

Attachment: 16203.diff added

comment:1 Changed 9 years ago by Aymeric Augustin

Triage Stage: UnreviewedAccepted

Should os.path.normcase should be added in the code, as suggested by the patch, or in the test case?

comment:2 Changed 9 years ago by Aymeric Augustin

Component: Uncategorizedcontrib.admin
Resolution: fixed
Severity: NormalRelease blocker
Status: newclosed

This was fixed at r17280.

Note: See TracTickets for help on using tickets.
Back to Top