[New-bugs-announce] [issue3840] test_urllib fails on cygwin

Hirokazu Yamamoto report at bugs.python.org
Thu Sep 11 20:27:36 CEST 2008


New submission from Hirokazu Yamamoto <ocean-city at m2.ccsnet.ne.jp>:

test_urllib's test_geturl fails with following messege.

test_urllib
test test_urllib failed -- Traceback (most recent call last):
  File "/home/WhiteRabbit/python-dev/trunk/Lib/test/test_urllib.py",
line 84, in
 test_geturl
    self.assertEqual(self.returned_obj.geturl(), self.pathname)
AssertionError: 'file:///tmp/@test' != '/tmp/@test'

test_support.TESTFN is /tmp/@test on cygwin, and Lib/urllib.py(484,485)
specially cares about leading slash. 

            if file[:1] == '/':
                urlfile = 'file://' + file

If this is geturl()'s design, probably test should be changed like
attached patch.

----------
components: Tests
files: test_urllib.patch
keywords: patch
messages: 73047
nosy: ocean-city
severity: normal
status: open
title: test_urllib fails on cygwin
versions: Python 2.5, Python 2.6, Python 3.0
Added file: http://bugs.python.org/file11468/test_urllib.patch

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue3840>
_______________________________________


More information about the New-bugs-announce mailing list