classification
Title: test_argparse fails with root permissions
Type: Stage: resolved
Components: Tests Versions: Python 3.2, Python 3.3, Python 2.7
process
Status: closed Resolution: fixed
Dependencies: Superseder:
Assigned To: Nosy List: Arfrever, Neurogeek, bethard, python-dev
Priority: normal Keywords: easy, patch

Created on 2011-11-14 15:20 by Arfrever, last changed 2011-11-20 22:09 by python-dev. This issue is now closed.

Files
File name Uploaded Description Edit
python-test_argparse.patch Arfrever, 2011-11-14 16:10 Skip TestFileTypeW tests for root user
Messages (2)
msg147602 - (view) Author: Arfrever Frehtes Taifersar Arahesis (Arfrever) * (Python triager) Date: 2011-11-14 15:20
$ python3.3 -B -m test.test_argparse
...
======================================================================
FAIL: test_failures_many_groups_listargs (__main__.TestFileTypeW)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/usr/lib64/python3.3/test/test_argparse.py", line 216, in wrapper
    test_func(self)
  File "/usr/lib64/python3.3/test/test_argparse.py", line 235, in test_failures
    raises(ArgumentParserError, parser.parse_args, args)
AssertionError: ArgumentParserError not raised by parse_args

======================================================================
FAIL: test_failures_many_groups_sysargs (__main__.TestFileTypeW)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/usr/lib64/python3.3/test/test_argparse.py", line 216, in wrapper
    test_func(self)
  File "/usr/lib64/python3.3/test/test_argparse.py", line 235, in test_failures
    raises(ArgumentParserError, parser.parse_args, args)
AssertionError: ArgumentParserError not raised by parse_args

======================================================================
FAIL: test_failures_no_groups_listargs (__main__.TestFileTypeW)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/usr/lib64/python3.3/test/test_argparse.py", line 216, in wrapper
    test_func(self)
  File "/usr/lib64/python3.3/test/test_argparse.py", line 235, in test_failures
    raises(ArgumentParserError, parser.parse_args, args)
AssertionError: ArgumentParserError not raised by parse_args

======================================================================
FAIL: test_failures_no_groups_sysargs (__main__.TestFileTypeW)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/usr/lib64/python3.3/test/test_argparse.py", line 216, in wrapper
    test_func(self)
  File "/usr/lib64/python3.3/test/test_argparse.py", line 235, in test_failures
    raises(ArgumentParserError, parser.parse_args, args)
AssertionError: ArgumentParserError not raised by parse_args

======================================================================
FAIL: test_failures_one_group_listargs (__main__.TestFileTypeW)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/usr/lib64/python3.3/test/test_argparse.py", line 216, in wrapper
    test_func(self)
  File "/usr/lib64/python3.3/test/test_argparse.py", line 235, in test_failures
    raises(ArgumentParserError, parser.parse_args, args)
AssertionError: ArgumentParserError not raised by parse_args

======================================================================
FAIL: test_failures_one_group_sysargs (__main__.TestFileTypeW)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/usr/lib64/python3.3/test/test_argparse.py", line 216, in wrapper
    test_func(self)
  File "/usr/lib64/python3.3/test/test_argparse.py", line 235, in test_failures
    raises(ArgumentParserError, parser.parse_args, args)
AssertionError: ArgumentParserError not raised by parse_args

----------------------------------------------------------------------
Ran 1611 tests in 8.405s

FAILED (failures=6)
Traceback (most recent call last):
  File "/usr/lib64/python3.3/runpy.py", line 160, in _run_module_as_main
    "__main__", fname, loader, pkg_name)
  File "/usr/lib64/python3.3/runpy.py", line 73, in _run_code
    exec(code, run_globals)
  File "/usr/lib64/python3.3/test/test_argparse.py", line 4773, in <module>
    test_main()
  File "/usr/lib64/python3.3/test/test_argparse.py", line 4765, in test_main
    support.run_unittest(__name__)
  File "/usr/lib64/python3.3/test/support.py", line 1402, in run_unittest
    _run_suite(suite)
  File "/usr/lib64/python3.3/test/support.py", line 1377, in _run_suite
    raise TestFailed(err)
test.support.TestFailed: multiple errors occurred
msg148013 - (view) Author: Roundup Robot (python-dev) (Python triager) Date: 2011-11-20 22:09
New changeset ba3da86d1c5d by Victor Stinner in branch '3.2':
Close #13401: Skip TestFileTypeW of test_argparse if the current user is root
http://hg.python.org/cpython/rev/ba3da86d1c5d

New changeset 50e788691eda by Victor Stinner in branch 'default':
(Merge 3.2) Close #13401: Skip TestFileTypeW of test_argparse if the current user is root
http://hg.python.org/cpython/rev/50e788691eda

New changeset 6e1e1118adca by Victor Stinner in branch '2.7':
Close #13401: Skip TestFileTypeW of test_argparse if the current user is root
http://hg.python.org/cpython/rev/6e1e1118adca
History
Date User Action Args
2011-11-20 22:09:52python-devsetstatus: open -> closed

nosy: + python-dev
messages: + msg148013

resolution: fixed
stage: patch review -> resolved
2011-11-14 23:01:33pitrousetstage: patch review
2011-11-14 16:10:23Arfreversetfiles: + python-test_argparse.patch
keywords: + patch
2011-11-14 15:59:08Neurogeeksetnosy: + Neurogeek
2011-11-14 15:20:09Arfrevercreate