-
-
Notifications
You must be signed in to change notification settings - Fork 32.4k
bpo-24813: IDLE: Add icon to help_about #2335
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
Changes from 1 commit
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
- Loading branch information
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,10 +5,12 @@ | |
from test.support import requires, findfile | ||
from tkinter import Tk, TclError | ||
import unittest | ||
from unittest import mock | ||
from idlelib.idle_test.mock_idle import Func | ||
from idlelib.idle_test.mock_tk import Mbox_func | ||
from idlelib.help_about import AboutDialog as About | ||
from idlelib import textview | ||
import os.path | ||
|
||
class LiveDialogTest(unittest.TestCase): | ||
"""Simulate user clicking buttons other than [Close]. | ||
|
@@ -33,6 +35,12 @@ def test_dialog_title(self): | |
"""Test about dialog title""" | ||
self.assertEqual(self.dialog.title(), 'About IDLE') | ||
|
||
def test_dialog_logo(self): | ||
"""Test about dialog logo.""" | ||
path, file = os.path.split(self.dialog.icon_image['file']) | ||
fn, ext = os.path.splitext(file) | ||
self.assertEqual(fn, 'idle_48') | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This is the best I can think of too. The real test is running help_about for the htest. I did that to experiment with different backgrounds. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Thanks. I wasn't sure if I should mock the PhotoImage just to show that the widget is created. |
||
|
||
def test_printer_buttons(self): | ||
"""Test buttons whose commands use printer function.""" | ||
dialog = self.dialog | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I suspect 'iconfn' abbreviates 'icon file name'. Too obscure; I'd prefer 'icon' here and below.