Skip to content

IDLE configdialog tests: don't modify tkinter.messagebox. #75468

Closed

Description

@terryjreedy
BPO 31287
Nosy @terryjreedy
PRs
  • bpo-31287: IDLE - do not alter tkinter.messagebox in tests. #3220
  • [3.6] bpo-31287: IDLE - do not alter tkinter.messagebox in configdial… #3221
  • bpo-30617: IDLE: docstrings and unittest for outwin.py #2046
  • bpo-31502: IDLE Configdialog again deletes custom themes and keysets. #3634
  • [3.6] bpo-31502: IDLE Configdialog again deletes custom themes and keysets. (GH-3634) #3636
  • 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/terryjreedy'
    closed_at = <Date 2017-08-27.22:10:50.384>
    created_at = <Date 2017-08-27.19:24:37.013>
    labels = ['expert-IDLE', 'type-bug', '3.7']
    title = "IDLE configdialog tests: don't modify tkinter.messagebox."
    updated_at = <Date 2017-09-18.00:39:26.019>
    user = 'https://github.com/terryjreedy'

    bugs.python.org fields:

    activity = <Date 2017-09-18.00:39:26.019>
    actor = 'terry.reedy'
    assignee = 'terry.reedy'
    closed = True
    closed_date = <Date 2017-08-27.22:10:50.384>
    closer = 'terry.reedy'
    components = ['IDLE']
    creation = <Date 2017-08-27.19:24:37.013>
    creator = 'terry.reedy'
    dependencies = []
    files = []
    hgrepos = []
    issue_num = 31287
    keywords = []
    message_count = 6.0
    messages = ['300921', '300924', '300927', '300928', '302395', '302399']
    nosy_count = 1.0
    nosy_names = ['terry.reedy']
    pr_nums = ['3220', '3221', '2046', '3634', '3636']
    priority = 'normal'
    resolution = 'fixed'
    stage = 'resolved'
    status = 'closed'
    superseder = None
    type = 'behavior'
    url = 'https://bugs.python.org/issue31287'
    versions = ['Python 3.6', 'Python 3.7']

    Activity

    1. terryjreedy commented on Aug 27, 2017

      @terryjreedy
      MemberAuthor

      test_configdialog twice patches tkinter.messagebox to mock askyesno without restoring it properly. As a consequence, the outwin test in bpo-30617 failed because the messagebox module in editor lacked askyesno.

      First patch: fix configdialog and test_configdialog. Similar to what is done elsewhere, make askyesno an instance method so that it is masked by an instance attribute mock and unmasked by deleting the instance function. In the process, revise the messabebox import,

      Follow-on patch(es): check exiting tests and apply the same idea everywhere. In the process, end use of 'tkMessageBox'.

    2. self-assigned this
      on Aug 27, 2017
    3. terryjreedy commented on Aug 27, 2017

      @terryjreedy
      MemberAuthor

      Additional patch or patches will be on generalized issue bpo-31288.

    4. changed the title [-]IDLE tests: don't modify tkinter.messagebox.[/-] [+]IDLE configdialog tests: don't modify tkinter.messagebox.[/+] on Aug 27, 2017
    5. terryjreedy commented on Aug 27, 2017

      @terryjreedy
      MemberAuthor

      New changeset 3457f42 by Terry Jan Reedy in branch 'master':
      bpo-31287: IDLE - do not alter tkinter.messagebox in configdialog tests. (bpo-3220)
      3457f42

    6. terryjreedy commented on Aug 27, 2017

      @terryjreedy
      MemberAuthor

      New changeset 7e24890 by Terry Jan Reedy in branch '3.6':
      [3.6] bpo-31287: IDLE - do not alter tkinter.messagebox in configdialog tests. (GH-3220) (bpo-3221)
      7e24890

    7. terryjreedy commented on Sep 18, 2017

      @terryjreedy
      MemberAuthor

      New changeset 0efc7c6 by Terry Jan Reedy in branch 'master':
      bpo-31502: IDLE Configdialog again deletes custom themes and keysets. (bpo-3634)
      0efc7c6

    8. terryjreedy commented on Sep 18, 2017

      @terryjreedy
      MemberAuthor

      New changeset 6b4d8ba by Terry Jan Reedy (Miss Islington (bot)) in branch '3.6':
      [3.6] bpo-31502: IDLE Configdialog again deletes custom themes and keysets. (GH-3634) (bpo-3636)
      6b4d8ba

    9. 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

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions