Bug 625395
| Summary: | include the tests/data directory in the python-test rpm | |||
|---|---|---|---|---|
| Product: | Red Hat Enterprise Linux 6 | Reporter: | Petr Šplíchal <psplicha> | |
| Component: | python | Assignee: | Dave Malcolm <dmalcolm> | |
| Status: | CLOSED ERRATA | QA Contact: | Petr Šplíchal <psplicha> | |
| Severity: | medium | Docs Contact: | ||
| Priority: | low | |||
| Version: | 6.0 | CC: | ohudlick, syeghiay | |
| Target Milestone: | rc | |||
| Target Release: | --- | |||
| Hardware: | All | |||
| OS: | Linux | |||
| Whiteboard: | ||||
| Fixed In Version: | python-2.6.6-13.el6 | Doc Type: | Bug Fix | |
| Doc Text: |
The python-tests subpackage was missing some test files and directories used by the selftests for lib2to3. This update adds the missing content to the subpackage.
|
Story Points: | --- | |
| Clone Of: | ||||
| : | 850056 (view as bug list) | Environment: | ||
| Last Closed: | 2011-05-19 11:36:49 UTC | Type: | --- | |
| Regression: | --- | Mount Type: | --- | |
| Documentation: | --- | CRM: | ||
| Verified Versions: | Category: | --- | ||
| oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | ||
| Cloudforms Team: | --- | Target Upstream Version: | ||
| Embargoed: | ||||
| Bug Depends On: | ||||
| Bug Blocks: | 850056 | |||
I've noticed the lib2to3 tests are included in the python core package. All the other tests belong to python-test rpm. Dave, is that an intentional exception? # rpm -ql python.x86_64 | grep test /usr/lib64/python2.6/doctest.py /usr/lib64/python2.6/doctest.pyc /usr/lib64/python2.6/doctest.pyo /usr/lib64/python2.6/lib2to3/tests /usr/lib64/python2.6/lib2to3/tests/__init__.py /usr/lib64/python2.6/lib2to3/tests/__init__.pyc /usr/lib64/python2.6/lib2to3/tests/__init__.pyo /usr/lib64/python2.6/lib2to3/tests/data /usr/lib64/python2.6/lib2to3/tests/data/README /usr/lib64/python2.6/lib2to3/tests/data/bom.py ... /usr/lib64/python2.6/lib2to3/tests/test_refactor.pyo /usr/lib64/python2.6/lib2to3/tests/test_util.py /usr/lib64/python2.6/lib2to3/tests/test_util.pyc /usr/lib64/python2.6/lib2to3/tests/test_util.pyo /usr/lib64/python2.6/test /usr/lib64/python2.6/test/__init__.py /usr/lib64/python2.6/test/__init__.pyc /usr/lib64/python2.6/test/__init__.pyo /usr/lib64/python2.6/test/test_support.py /usr/lib64/python2.6/test/test_support.pyc /usr/lib64/python2.6/test/test_support.pyo /usr/lib64/python2.6/unittest.py /usr/lib64/python2.6/unittest.pyc /usr/lib64/python2.6/unittest.pyo
Technical note added. If any revisions are required, please edit the "Technical Notes" field
accordingly. All revisions will be proofread by the Engineering Content Services team.
New Contents:
The python-tests subpackage was missing some test files and directories used by the selftests for lib2to3. This update adds the missing content to the subpackage.
An advisory has been issued which should help the problem described in this bug report. This report is therefore being closed with a resolution of ERRATA. For more information on therefore solution and/or where to find the updated files, please follow the link below. You may reopen this bug report if the solution does not work for you. http://rhn.redhat.com/errata/RHSA-2011-0554.html An advisory has been issued which should help the problem described in this bug report. This report is therefore being closed with a resolution of ERRATA. For more information on therefore solution and/or where to find the updated files, please follow the link below. You may reopen this bug report if the solution does not work for you. http://rhn.redhat.com/errata/RHSA-2011-0554.html |
Description of problem: Please include the tests/data directory in the python-test package as it contains files necessary for running some of the unit tests. Version-Release number of selected component (if applicable): python-2.6.5-3.el6.x86_64 Steps to Reproduce: # ./regrtest.py test_lib2to3.py test_lib2to3 test_lib2to3 skipped -- No module named myfixes 1 test skipped: test_lib2to3 1 skip unexpected on linux2: test_lib2to3 David Malcom's comment from BZ#583931 https://bugzilla.redhat.com/show_bug.cgi?id=583931#c29 test_lib2to3.py:(see comment #19) The tarball has a "Python-2.6.5/Lib/lib2to3/tests/data" subdirectory: $ find Python-2.6.5/Lib/lib2to3/tests/data Python-2.6.5/Lib/lib2to3/tests/data Python-2.6.5/Lib/lib2to3/tests/data/different_encoding.py Python-2.6.5/Lib/lib2to3/tests/data/bom.py Python-2.6.5/Lib/lib2to3/tests/data/README Python-2.6.5/Lib/lib2to3/tests/data/py3_test_grammar.py Python-2.6.5/Lib/lib2to3/tests/data/crlf.py Python-2.6.5/Lib/lib2to3/tests/data/py2_test_grammar.py Python-2.6.5/Lib/lib2to3/tests/data/fixers Python-2.6.5/Lib/lib2to3/tests/data/fixers/parrot_example.py Python-2.6.5/Lib/lib2to3/tests/data/fixers/myfixes Python-2.6.5/Lib/lib2to3/tests/data/fixers/myfixes/fix_explicit.py Python-2.6.5/Lib/lib2to3/tests/data/fixers/myfixes/__init__.py Python-2.6.5/Lib/lib2to3/tests/data/fixers/myfixes/fix_preorder.py Python-2.6.5/Lib/lib2to3/tests/data/fixers/myfixes/fix_first.py Python-2.6.5/Lib/lib2to3/tests/data/fixers/myfixes/fix_last.py Python-2.6.5/Lib/lib2to3/tests/data/fixers/myfixes/fix_parrot.py Python-2.6.5/Lib/lib2to3/tests/data/fixers/bad_order.py Python-2.6.5/Lib/lib2to3/tests/data/fixers/no_fixer_cls.py Python-2.6.5/Lib/lib2to3/tests/data/infinite_recursion.py but this directory doesn't seem to be in our rpms From the Python-2.6.5/Lib/lib2to3/tests/data/README: In this directory: - py2_test_grammar.py -- test file that exercises most/all of Python 2.x's grammar. - py3_test_grammar.py -- test file that exercises most/all of Python 3.x's grammar. - infinite_recursion.py -- test file that causes lib2to3's faster recursive pattern matching scheme to fail, but passes when lib2to3 falls back to iterative pattern matching. - fixes/ -- for use by test_refactor.py All of the other files within "Python-2.6.5/Lib/lib2to3/tests" appear to have made it into our "python" (not "python-test") package within %{_libdir}/python2.6/lib2to3/tests ; there are no other directories. Looking at the build log, within the %install I see the invocation of "make install" leads to: Creating directory /usr/lib64/python2.6/lib2to3 Creating directory /usr/lib64/python2.6/lib2to3/fixes Creating directory /usr/lib64/python2.6/lib2to3/pgen2 Creating directory /usr/lib64/python2.6/lib2to3/tests and later: /usr/bin/install -c -m 644 ./Lib/lib2to3/tests/__init__.py /usr/lib64/python2.6/lib2to3/tests /usr/bin/install -c ./Lib/lib2to3/tests/pytree_idempotency.py /usr/lib64/python2.6/lib2to3/tests /usr/bin/install -c -m 644 ./Lib/lib2to3/tests/support.py /usr/lib64/python2.6/lib2to3/tests /usr/bin/install -c -m 644 ./Lib/lib2to3/tests/test_all_fixers.py /usr/lib64/python2.6/lib2to3/tests /usr/bin/install -c -m 644 ./Lib/lib2to3/tests/test_fixers.py /usr/lib64/python2.6/lib2to3/tests /usr/bin/install -c -m 644 ./Lib/lib2to3/tests/test_main.py /usr/lib64/python2.6/lib2to3/tests /usr/bin/install -c -m 644 ./Lib/lib2to3/tests/test_parser.py /usr/lib64/python2.6/lib2to3/tests /usr/bin/install -c -m 644 ./Lib/lib2to3/tests/test_pytree.py /usr/lib64/python2.6/lib2to3/tests /usr/bin/install -c -m 644 ./Lib/lib2to3/tests/test_refactor.py /usr/lib64/python2.6/lib2to3/tests /usr/bin/install -c -m 644 ./Lib/lib2to3/tests/test_util.py /usr/lib64/python2.6/lib2to3/tests but nothing relating to /usr/lib64/python2.6/lib2to3/tests/data Upstream Makefile.pre.in has "LIBSUBDIRS=" listing various directories including "lib2to3 lib2to3/fixes lib2to3/pgen2 lib2to3/tests"; latest upstream SVN for 2.7 has added: "lib2to3/tests/data lib2to3/tests/data/fixers lib2to3/tests/data/fixers/myfixes" This was fixed upstream (buggily) in: http://svn.python.org/view/python/trunk/Makefile.pre.in?r1=71395&r2=71394 and the fix was fixed in these commits: http://svn.python.org/view/python/trunk/Makefile.pre.in?r1=71395&r2=71396 http://svn.python.org/view/python/trunk/Makefile.pre.in?r1=71494&r2=71740