Re: [Python-Dev] [Python-checkins] cpython (3.2): Issue #11919: try to fix test_imp failure on some buildbots.

This seems to be changing what is tested -- are you saying that filenames with an included directory name are not intended to be supported?
On 4/25/11, antoine.pitrou python-checkins@python.org wrote:
http://hg.python.org/cpython/rev/2f2c7eb27437 changeset: 69556:2f2c7eb27437 branch: 3.2 parent: 69554:77cf9e4b144b user: Antoine Pitrou solipsis@pitrou.net date: Mon Apr 25 21:39:49 2011 +0200 summary: Issue #11919: try to fix test_imp failure on some buildbots.
files: Lib/test/test_imp.py | 3 ++- 1 files changed, 2 insertions(+), 1 deletions(-)
diff --git a/Lib/test/test_imp.py b/Lib/test/test_imp.py --- a/Lib/test/test_imp.py +++ b/Lib/test/test_imp.py @@ -171,8 +171,9 @@ support.rmtree(test_package_name)
def test_issue9319(self):
path = os.path.dirname(__file__) self.assertRaises(SyntaxError,
imp.find_module, "test/badsyntax_pep3120")
imp.find_module, "badsyntax_pep3120", [path])
class ReloadTests(unittest.TestCase):
-- Repository URL: http://hg.python.org/cpython

Le mardi 26 avril 2011 à 10:03 -0400, Jim Jewett a écrit :
This seems to be changing what is tested -- are you saying that filenames with an included directory name are not intended to be supported?
I don't know, but that's not the point of this very test. (I also find it a bit surprising that find_module() would accept a module name - and not a filename - containing a slash and treat it as some kind of directory path)
Regards
Antoine.

Le mardi 26 avril 2011 à 10:03 -0400, Jim Jewett a écrit :
This seems to be changing what is tested -- are you saying that filenames with an included directory name are not intended to be supported?
The test checks the Python parser, not the imp module :-)
I don't understand why: sometimes, find_module() accepts a (relative) path, sometimes it doesn't.
Victor
participants (3)
-
Antoine Pitrou
-
Jim Jewett
-
Victor Stinner