Skip to content

Report more silently skipped tests as skipped #63771

Closed

Description

@zware
BPO 19572
Nosy @terryjreedy, @pitrou, @vstinner, @ned-deily, @ezio-melotti, @voidspace, @zware, @serhiy-storchaka, @vajrasky
Files
  • skiptest_not_return_or_pass.diff
  • skiptest_not_return_or_pass.v2.diff: A couple additional skips
  • skiptest_not_return_or_pass.v3.diff: Version 3
  • skiptest_not_return_or_pass.v4-3.3.diff
  • skiptest_not_return_or_pass.v4-2.7.diff
  • skiptest_not_return_or_pass.v5-2.7.diff: 2.7, version 5
  • skiptest_not_return_or_pass.v6-2.7.diff: Version 6, the real version 5!
  • Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.

    Show more details

    GitHub fields:

    assignee = 'https://github.com/zware'
    closed_at = <Date 2013-12-10.20:11:00.043>
    created_at = <Date 2013-11-13.17:18:58.144>
    labels = ['type-feature', 'tests']
    title = 'Report more silently skipped tests as skipped'
    updated_at = <Date 2013-12-12.16:33:38.122>
    user = 'https://github.com/zware'

    bugs.python.org fields:

    activity = <Date 2013-12-12.16:33:38.122>
    actor = 'python-dev'
    assignee = 'zach.ware'
    closed = True
    closed_date = <Date 2013-12-10.20:11:00.043>
    closer = 'zach.ware'
    components = ['Tests']
    creation = <Date 2013-11-13.17:18:58.144>
    creator = 'zach.ware'
    dependencies = []
    files = ['32599', '32601', '32625', '32728', '32761', '33080', '33082']
    hgrepos = []
    issue_num = 19572
    keywords = ['patch']
    message_count = 23.0
    messages = ['202762', '202769', '202774', '202793', '202795', '202906', '203076', '203080', '203334', '203494', '203526', '203647', '205522', '205523', '205533', '205836', '205838', '205839', '205844', '205849', '205851', '205863', '205959']
    nosy_count = 10.0
    nosy_names = ['terry.reedy', 'pitrou', 'vstinner', 'ned.deily', 'ezio.melotti', 'michael.foord', 'python-dev', 'zach.ware', 'serhiy.storchaka', 'vajrasky']
    pr_nums = []
    priority = 'normal'
    resolution = 'fixed'
    stage = 'resolved'
    status = 'closed'
    superseder = None
    type = 'enhancement'
    url = 'https://bugs.python.org/issue19572'
    versions = ['Python 2.7']

    Activity

    1. zware commented on Nov 13, 2013

      @zware
      MemberAuthor

      (Nosy list copied from bpo-18702)

      Grepping for "^\s+return$" and "^\s+pass$" in Lib/test turned up several more tests that are silently skipped (along with many legitimate uses of each). The attached patch turns each into a skip in a few various ways, including splitting a test into two tests in a couple of cases.

      I'll make a few comments on Rietveld myself to point out places where I would really like some extra scrutiny.

    2. added
      tests
      type-feature
      on Nov 13, 2013
    3. serhiy-storchaka commented on Nov 13, 2013

      @serhiy-storchaka
      Member

      See also bpo-19492 and bpo-19493.

    4. zware commented on Nov 13, 2013

      @zware
      MemberAuthor

      Starting a review of bpo-19492, I realized my original regexs didn't take comments into account. Grepping "^\s+return\s*(#.*)?$" instead turned up a couple more skips, including some in test_tempfile that said "return # ugh, can't use SkipTest", relics of the days before unittest.SkipTest.

    5. serhiy-storchaka commented on Nov 13, 2013

      @serhiy-storchaka
      Member

      I added some comments on Rietveld to the first patch. In general it LGTM. I will made a review for additional skips tomorrow.

      I suggest extract importlib related changes in separated issue. Bratt Cannon should review them.

    6. serhiy-storchaka commented on Nov 13, 2013

      @serhiy-storchaka
      Member

      I will made a review for additional skips tomorrow.

      Additional skips LGTM.

    7. zware commented on Nov 14, 2013

      @zware
      MemberAuthor

      Here's a new patch to address the reviews from Serhiy and Ezio (thanks to you both!).

    8. ezio-melotti commented on Nov 16, 2013

      @ezio-melotti
      Member
      I get a failure on Linux with test_posix:
      $ ./python -m test test_posix
      [1/1] test_posix
      test test_posix failed -- Traceback (most recent call last):
        File "/home/wolf/dev/py/py3k/Lib/test/test_posix.py", line 713, in test_getcwd_long_pathnames
          _create_and_do_getcwd(dirname)
        File "/home/wolf/dev/py/py3k/Lib/test/test_posix.py", line 708, in _create_and_do_getcwd
          _create_and_do_getcwd(dirname, current_path_length + len(dirname) + 1)
        File "/home/wolf/dev/py/py3k/Lib/test/test_posix.py", line 708, in _create_and_do_getcwd
          _create_and_do_getcwd(dirname, current_path_length + len(dirname) + 1)
        File "/home/wolf/dev/py/py3k/Lib/test/test_posix.py", line 708, in _create_and_do_getcwd
          _create_and_do_getcwd(dirname, current_path_length + len(dirname) + 1)
        File "/home/wolf/dev/py/py3k/Lib/test/test_posix.py", line 708, in _create_and_do_getcwd
          _create_and_do_getcwd(dirname, current_path_length + len(dirname) + 1)
        File "/home/wolf/dev/py/py3k/Lib/test/test_posix.py", line 708, in _create_and_do_getcwd
          _create_and_do_getcwd(dirname, current_path_length + len(dirname) + 1)
        File "/home/wolf/dev/py/py3k/Lib/test/test_posix.py", line 708, in _create_and_do_getcwd
          _create_and_do_getcwd(dirname, current_path_length + len(dirname) + 1)
        File "/home/wolf/dev/py/py3k/Lib/test/test_posix.py", line 708, in _create_and_do_getcwd
          _create_and_do_getcwd(dirname, current_path_length + len(dirname) + 1)
        File "/home/wolf/dev/py/py3k/Lib/test/test_posix.py", line 708, in _create_and_do_getcwd
          _create_and_do_getcwd(dirname, current_path_length + len(dirname) + 1)
        File "/home/wolf/dev/py/py3k/Lib/test/test_posix.py", line 708, in _create_and_do_getcwd
          _create_and_do_getcwd(dirname, current_path_length + len(dirname) + 1)
        File "/home/wolf/dev/py/py3k/Lib/test/test_posix.py", line 708, in _create_and_do_getcwd
          _create_and_do_getcwd(dirname, current_path_length + len(dirname) + 1)
        File "/home/wolf/dev/py/py3k/Lib/test/test_posix.py", line 708, in _create_and_do_getcwd
          _create_and_do_getcwd(dirname, current_path_length + len(dirname) + 1)
        File "/home/wolf/dev/py/py3k/Lib/test/test_posix.py", line 708, in _create_and_do_getcwd
          _create_and_do_getcwd(dirname, current_path_length + len(dirname) + 1)
        File "/home/wolf/dev/py/py3k/Lib/test/test_posix.py", line 708, in _create_and_do_getcwd
          _create_and_do_getcwd(dirname, current_path_length + len(dirname) + 1)
        File "/home/wolf/dev/py/py3k/Lib/test/test_posix.py", line 708, in _create_and_do_getcwd
          _create_and_do_getcwd(dirname, current_path_length + len(dirname) + 1)
        File "/home/wolf/dev/py/py3k/Lib/test/test_posix.py", line 708, in _create_and_do_getcwd
          _create_and_do_getcwd(dirname, current_path_length + len(dirname) + 1)
        File "/home/wolf/dev/py/py3k/Lib/test/test_posix.py", line 708, in _create_and_do_getcwd
          _create_and_do_getcwd(dirname, current_path_length + len(dirname) + 1)
        File "/home/wolf/dev/py/py3k/Lib/test/test_posix.py", line 706, in _create_and_do_getcwd
          os.getcwd()
      OSError: [Errno 34] Numerical result out of range

      1 test failed:
      test_posix

    9. serhiy-storchaka commented on Nov 16, 2013

      @serhiy-storchaka
      Member

      Except pickletester and test_posix third patch LGTM. test_posix is worth separate issue. test_reduce and test_getinitargs in pickletester are always empty and can be just removed (if you don't want implement them).

    10. zware commented on Nov 19, 2013

      @zware
      MemberAuthor

      I'll open new issues for test_posix and pickletester and commit the rest of the patch as soon as I can get it backported. Thanks for the reviews!

    11. zware commented on Nov 20, 2013

      @zware
      MemberAuthor

      pickletester issue opened at bpo-19648. The test_posix issue already has an open issue at bpo-9246.

    12. serhiy-storchaka commented on Nov 20, 2013

      @serhiy-storchaka
      Member

      skiptest_not_return_or_pass.v4-3.3.diff LGTM.

    13. zware commented on Nov 21, 2013

      @zware
      MemberAuthor

      The 2.7 patch has a lot of extra changes in it, extra review is probably in order for it.

    14. python-dev commented on Dec 8, 2013

      python-devmannequin
      Mannequin

      New changeset 3283fb24106d by Zachary Ware in branch '3.3':
      bpo-19572: More silently skipped tests explicitly skipped.
      http://hg.python.org/cpython/rev/3283fb24106d

      New changeset 03afd2d7d395 by Zachary Ware in branch 'default':
      bpo-19572: More silently skipped tests explicitly skipped.
      http://hg.python.org/cpython/rev/03afd2d7d395

    15. zware commented on Dec 8, 2013

      @zware
      MemberAuthor

      Committed on 3.3 and default; I'd still like some extra eyes on the 2.7 patch before I commit it.

    16. self-assigned this
      on Dec 8, 2013
    17. serhiy-storchaka commented on Dec 8, 2013

      @serhiy-storchaka
      Member

      I have added few comments on Rietveld.

    18. zware commented on Dec 10, 2013

      @zware
      MemberAuthor

      Here's a new 2.7 patch. It addresses Serhiy's review comments and doesn't change test_xpickle, which I will be opening a new issue for.

    19. zware commented on Dec 10, 2013

      @zware
      MemberAuthor

      I missed the comments on test_bsddb; I'll either post a new patch here or open a new issue depending on how big that diff becomes.

    20. zware commented on Dec 10, 2013

      @zware
      MemberAuthor

      This patch includes Serhiy's suggestions. Oops!

    21. serhiy-storchaka commented on Dec 10, 2013

      @serhiy-storchaka
      Member
      $ ./python -3 -m test.regrtest test_builtin
      test_builtin
      test test_builtin crashed -- <type 'exceptions.AssertionError'>: filter ('.+ is renamed to imp.reload', DeprecationWarning) did not catch any warning
      1 test failed:
          test_builtin

      Rest of the skiptest_not_return_or_pass.v6-2.7.diff patch LGTM.

    22. python-dev commented on Dec 10, 2013

      python-devmannequin
      Mannequin

      New changeset 423e09aedf79 by Zachary Ware in branch '2.7':
      Issue bpo-19572: More silently skipped tests explicitly skipped.
      http://hg.python.org/cpython/rev/423e09aedf79

    23. zware commented on Dec 10, 2013

      @zware
      MemberAuthor

      Fixed that last comment in the commit. Thank you for all the reviews, Serhiy!

    24. python-dev commented on Dec 10, 2013

      python-devmannequin
      Mannequin

      New changeset ca9bca7aecda by Zachary Ware in branch '2.7':
      Issue bpo-19572: Replace a return that shouldn't have been removed from test_os.
      http://hg.python.org/cpython/rev/ca9bca7aecda

    25. python-dev commented on Dec 12, 2013

      python-devmannequin
      Mannequin

      New changeset 1ad2ff119356 by Zachary Ware in branch '3.3':
      Avoid UnicodeEncodeError by only printing ASCII.
      http://hg.python.org/cpython/rev/1ad2ff119356

    26. transferred this issue fromon Apr 10, 2022
    Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

    Metadata

    Metadata

    Assignees

    Labels

    teststype-feature

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions