Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Clean up tests that return a value that isn't None #89143

Closed
akulakov opened this issue Aug 22, 2021 · 4 comments
Closed

Clean up tests that return a value that isn't None #89143

akulakov opened this issue Aug 22, 2021 · 4 comments
Labels
tests Tests in the Lib/test dir type-feature A feature request or enhancement

Comments

@akulakov
Copy link
Contributor

BPO 44980
Nosy @ambv, @miss-islington, @Fidget-Spinner, @akulakov
PRs
  • bpo-44980: fix test_constructor to return None value #27898
  • [3.10] bpo-44980: fix test_constructor to return None value (GH-27898) #27913
  • [3.9] bpo-44980: fix test_constructor to return None value (GH-27898) #27914
  • 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 = None
    closed_at = <Date 2021-09-03.00:20:31.405>
    created_at = <Date 2021-08-22.18:07:45.427>
    labels = ['type-feature', 'tests']
    title = "Clean up tests that return a value that isn't None"
    updated_at = <Date 2021-09-03.00:20:31.397>
    user = 'https://github.com/akulakov'

    bugs.python.org fields:

    activity = <Date 2021-09-03.00:20:31.397>
    actor = 'andrei.avk'
    assignee = 'none'
    closed = True
    closed_date = <Date 2021-09-03.00:20:31.405>
    closer = 'andrei.avk'
    components = ['Tests']
    creation = <Date 2021-08-22.18:07:45.427>
    creator = 'andrei.avk'
    dependencies = []
    files = []
    hgrepos = []
    issue_num = 44980
    keywords = ['patch']
    message_count = 4.0
    messages = ['400083', '400163', '400167', '400168']
    nosy_count = 4.0
    nosy_names = ['lukasz.langa', 'miss-islington', 'kj', 'andrei.avk']
    pr_nums = ['27898', '27913', '27914']
    priority = 'normal'
    resolution = 'fixed'
    stage = 'resolved'
    status = 'closed'
    superseder = None
    type = 'enhancement'
    url = 'https://bugs.python.org/issue44980'
    versions = []

    @akulakov
    Copy link
    Contributor Author

    In bpo-41322 the behavior of returning a value!=None from test methods was deprecated, there are currently a few tests in Python that do that; it would be good to fix them to be consistent with our deprecation requirement and to avoid deprecation warnings in test runs; it may also possibly surface unexpected issues when reviewing these tests.

    • there are two distutils tests - test_quiet and test_no_optimize_flag -- probably not worth it to investigate them as distutils is set for removal in 3.12

    • test_null_strings in CAPI

    • test_constructor in test_code

    I'll try to fix the two tests above today.

    @akulakov akulakov added tests Tests in the Lib/test dir labels Aug 22, 2021
    @ambv ambv changed the title Clean up a few tests that return a value!=None Clean up tests that return a value that isn't None Aug 22, 2021
    @ambv ambv changed the title Clean up a few tests that return a value!=None Clean up tests that return a value that isn't None Aug 22, 2021
    @ambv
    Copy link
    Contributor

    ambv commented Aug 23, 2021

    New changeset 27b761a by andrei kulakov in branch 'main':
    bpo-44980: fix test_constructor to return None value (GH-27898)
    27b761a

    @ambv
    Copy link
    Contributor

    ambv commented Aug 23, 2021

    New changeset de49eac by Miss Islington (bot) in branch '3.9':
    bpo-44980: fix test_constructor to return None value (GH-27898) (GH-27914)
    de49eac

    @miss-islington
    Copy link
    Contributor

    New changeset 1095535 by Miss Islington (bot) in branch '3.10':
    bpo-44980: fix test_constructor to return None value (GH-27898)
    1095535

    @akulakov akulakov closed this as completed Sep 3, 2021
    @akulakov akulakov added the type-feature A feature request or enhancement label Sep 3, 2021
    @akulakov akulakov closed this as completed Sep 3, 2021
    @akulakov akulakov added the type-feature A feature request or enhancement label Sep 3, 2021
    @ezio-melotti ezio-melotti transferred this issue from another repository Apr 10, 2022
    Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
    Labels
    tests Tests in the Lib/test dir type-feature A feature request or enhancement
    Projects
    None yet
    Development

    No branches or pull requests

    3 participants