Issue 19085: Add tkinter basic options tests (original) (raw)

With Aqua Cocoa Tcl/Tk 8.5.14 or 8.6.0 (using ActiveState's 8.5.14 or 8.6.0) on OS X 10.8.5, running test_ttk_guionly:

====================================================================== ERROR: test_class (tkinter.test.test_ttk.test_widgets.ScrollbarTest)

Traceback (most recent call last): File "/py/dev/3x/root/fwd/Library/Frameworks/pytest_10.8.framework/Versions/3.4/lib/python3.4/tkinter/test/test_ttk/test_widgets.py", line 22, in test_class self.assertEqual(widget['class'], '') File "/py/dev/3x/root/fwd/Library/Frameworks/pytest_10.8.framework/Versions/3.4/lib/python3.4/tkinter/init.py", line 1267, in cget return self.tk.call(self._w, 'cget', '-' + key) _tkinter.TclError: unknown option "-class"

====================================================================== ERROR: test_style (tkinter.test.test_ttk.test_widgets.ScrollbarTest)

Traceback (most recent call last): File "/py/dev/3x/root/fwd/Library/Frameworks/pytest_10.8.framework/Versions/3.4/lib/python3.4/tkinter/test/test_ttk/test_widgets.py", line 44, in test_style self.assertEqual(widget['style'], '') File "/py/dev/3x/root/fwd/Library/Frameworks/pytest_10.8.framework/Versions/3.4/lib/python3.4/tkinter/init.py", line 1267, in cget return self.tk.call(self._w, 'cget', '-' + key) _tkinter.TclError: unknown option "-style"

====================================================================== FAIL: test_orient (tkinter.test.test_ttk.test_widgets.ScrollbarTest)

Traceback (most recent call last): File "/py/dev/3x/root/fwd/Library/Frameworks/pytest_10.8.framework/Versions/3.4/lib/python3.4/tkinter/test/support.py", line 426, in test_orient self.checkEnumParam(widget, 'orient', 'horizontal', 'vertical') File "/py/dev/3x/root/fwd/Library/Frameworks/pytest_10.8.framework/Versions/3.4/lib/python3.4/tkinter/test/support.py", line 244, in checkEnumParam errmsg='ambiguous' + errmsg2) File "/py/dev/3x/root/fwd/Library/Frameworks/pytest_10.8.framework/Versions/3.4/lib/python3.4/tkinter/test/support.py", line 174, in checkInvalidParam widget[name] = value AssertionError: TclError not raised


Ran 233 tests in 2.823s

FAILED (failures=1, errors=2, skipped=1) test test_ttk_guionly failed 1 test failed: test_ttk_guionly


With Aqua Carbon Tcl/Tk 8.4.19 (using ActiveState's 8.4.19) on OS X 10.8.5, running test_ttk_guionly (in 32-bit mode):

===================================================================== ERROR: test_class (tkinter.test.test_ttk.test_widgets.ScrollbarTest)

Traceback (most recent call last): File "/py/dev/3x/root/fwd/Library/Frameworks/pytest_10.8.framework/Versions/3.4/lib/python3.4/tkinter/test/test_ttk/test_widgets.py", line 22, in test_class self.assertEqual(widget['class'], '') File "/py/dev/3x/root/fwd/Library/Frameworks/pytest_10.8.framework/Versions/3.4/lib/python3.4/tkinter/init.py", line 1267, in cget return self.tk.call(self._w, 'cget', '-' + key) _tkinter.TclError: unknown option "-class"

====================================================================== ERROR: test_style (tkinter.test.test_ttk.test_widgets.ScrollbarTest)

Traceback (most recent call last): File "/py/dev/3x/root/fwd/Library/Frameworks/pytest_10.8.framework/Versions/3.4/lib/python3.4/tkinter/test/test_ttk/test_widgets.py", line 44, in test_style self.assertEqual(widget['style'], '') File "/py/dev/3x/root/fwd/Library/Frameworks/pytest_10.8.framework/Versions/3.4/lib/python3.4/tkinter/init.py", line 1267, in cget return self.tk.call(self._w, 'cget', '-' + key) _tkinter.TclError: unknown option "-style"

====================================================================== FAIL: test_values (tkinter.test.test_ttk.test_widgets.ComboboxTest)

Traceback (most recent call last): File "/py/dev/3x/root/fwd/Library/Frameworks/pytest_10.8.framework/Versions/3.4/lib/python3.4/tkinter/test/test_ttk/test_widgets.py", line 351, in test_values self.assertEqual(self.combo['values'], '') AssertionError: () != ''

====================================================================== FAIL: test_borderwidth (tkinter.test.test_ttk.test_widgets.FrameTest)

Traceback (most recent call last): File "/py/dev/3x/root/fwd/Library/Frameworks/pytest_10.8.framework/Versions/3.4/lib/python3.4/tkinter/test/support.py", line 336, in test_borderwidth 0, 1.3, 2.6, 6, -2, '10p') File "/py/dev/3x/root/fwd/Library/Frameworks/pytest_10.8.framework/Versions/3.4/lib/python3.4/tkinter/test/support.py", line 260, in checkPixelsParam conv=conv, **kwargs) File "/py/dev/3x/root/fwd/Library/Frameworks/pytest_10.8.framework/Versions/3.4/lib/python3.4/tkinter/test/support.py", line 161, in checkParam self.assertEqual2(widget[name], expected, eq=eq) File "/py/dev/3x/root/fwd/Library/Frameworks/pytest_10.8.framework/Versions/3.4/lib/python3.4/tkinter/test/support.py", line 145, in assertEqual2 self.assertEqual(actual, expected, msg) AssertionError: <pixel object: '0'> != 0

====================================================================== FAIL: test_height (tkinter.test.test_ttk.test_widgets.FrameTest)

Traceback (most recent call last): File "/py/dev/3x/root/fwd/Library/Frameworks/pytest_10.8.framework/Versions/3.4/lib/python3.4/tkinter/test/support.py", line 556, in test_height self.checkPixelsParam(widget, 'height', 100, 101.2, 102.6, -100, 0, '3c') File "/py/dev/3x/root/fwd/Library/Frameworks/pytest_10.8.framework/Versions/3.4/lib/python3.4/tkinter/test/support.py", line 260, in checkPixelsParam conv=conv, **kwargs) File "/py/dev/3x/root/fwd/Library/Frameworks/pytest_10.8.framework/Versions/3.4/lib/python3.4/tkinter/test/support.py", line 161, in checkParam self.assertEqual2(widget[name], expected, eq=eq) File "/py/dev/3x/root/fwd/Library/Frameworks/pytest_10.8.framework/Versions/3.4/lib/python3.4/tkinter/test/support.py", line 145, in assertEqual2 self.assertEqual(actual, expected, msg) AssertionError: <pixel object: '100'> != 100

====================================================================== FAIL: test_width (tkinter.test.test_ttk.test_widgets.FrameTest)

Traceback (most recent call last): File "/py/dev/3x/root/fwd/Library/Frameworks/pytest_10.8.framework/Versions/3.4/lib/python3.4/tkinter/test/support.py", line 560, in test_width self.checkPixelsParam(widget, 'width', 402, 403.4, 404.6, -402, 0, '5i') File "/py/dev/3x/root/fwd/Library/Frameworks/pytest_10.8.framework/Versions/3.4/lib/python3.4/tkinter/test/support.py", line 260, in checkPixelsParam conv=conv, **kwargs) File "/py/dev/3x/root/fwd/Library/Frameworks/pytest_10.8.framework/Versions/3.4/lib/python3.4/tkinter/test/support.py", line 161, in checkParam self.assertEqual2(widget[name], expected, eq=eq) File "/py/dev/3x/root/fwd/Library/Frameworks/pytest_10.8.framework/Versions/3.4/lib/python3.4/tkinter/test/support.py", line 145, in assertEqual2 self.assertEqual(actual, expected, msg) AssertionError: <pixel object: '402'> != 402

====================================================================== FAIL: test_borderwidth (tkinter.test.test_ttk.test_widgets.LabelFrameTest)

Traceback (most recent call last): File "/py/dev/3x/root/fwd/Library/Frameworks/pytest_10.8.framework/Versions/3.4/lib/python3.4/tkinter/test/support.py", line 336, in test_borderwidth 0, 1.3, 2.6, 6, -2, '10p') File "/py/dev/3x/root/fwd/Library/Frameworks/pytest_10.8.framework/Versions/3.4/lib/python3.4/tkinter/test/support.py", line 260, in checkPixelsParam conv=conv, **kwargs) File "/py/dev/3x/root/fwd/Library/Frameworks/pytest_10.8.framework/Versions/3.4/lib/python3.4/tkinter/test/support.py", line 161, in checkParam self.assertEqual2(widget[name], expected, eq=eq) File "/py/dev/3x/root/fwd/Library/Frameworks/pytest_10.8.framework/Versions/3.4/lib/python3.4/tkinter/test/support.py", line 145, in assertEqual2 self.assertEqual(actual, expected, msg) AssertionError: <pixel object: '0'> != 0

====================================================================== FAIL: test_height (tkinter.test.test_ttk.test_widgets.LabelFrameTest)

Traceback (most recent call last): File "/py/dev/3x/root/fwd/Library/Frameworks/pytest_10.8.framework/Versions/3.4/lib/python3.4/tkinter/test/support.py", line 556, in test_height self.checkPixelsParam(widget, 'height', 100, 101.2, 102.6, -100, 0, '3c') File "/py/dev/3x/root/fwd/Library/Frameworks/pytest_10.8.framework/Versions/3.4/lib/python3.4/tkinter/test/support.py", line 260, in checkPixelsParam conv=conv, **kwargs) File "/py/dev/3x/root/fwd/Library/Frameworks/pytest_10.8.framework/Versions/3.4/lib/python3.4/tkinter/test/support.py", line 161, in checkParam self.assertEqual2(widget[name], expected, eq=eq) File "/py/dev/3x/root/fwd/Library/Frameworks/pytest_10.8.framework/Versions/3.4/lib/python3.4/tkinter/test/support.py", line 145, in assertEqual2 self.assertEqual(actual, expected, msg) AssertionError: <pixel object: '100'> != 100

====================================================================== FAIL: test_width (tkinter.test.test_ttk.test_widgets.LabelFrameTest)

Traceback (most recent call last): File "/py/dev/3x/root/fwd/Library/Frameworks/pytest_10.8.framework/Versions/3.4/lib/python3.4/tkinter/test/support.py", line 560, in test_width self.checkPixelsParam(widget, 'width', 402, 403.4, 404.6, -402, 0, '5i') File "/py/dev/3x/root/fwd/Library/Frameworks/pytest_10.8.framework/Versions/3.4/lib/python3.4/tkinter/test/support.py", line 260, in checkPixelsParam conv=conv, **kwargs) File "/py/dev/3x/root/fwd/Library/Frameworks/pytest_10.8.framework/Versions/3.4/lib/python3.4/tkinter/test/support.py", line 161, in checkParam self.assertEqual2(widget[name], expected, eq=eq) File "/py/dev/3x/root/fwd/Library/Frameworks/pytest_10.8.framework/Versions/3.4/lib/python3.4/tkinter/test/support.py", line 145, in assertEqual2 self.assertEqual(actual, expected, msg) AssertionError: <pixel object: '402'> != 402

====================================================================== FAIL: test_wraplength (tkinter.test.test_ttk.test_widgets.LabelTest)

Traceback (most recent call last): File "/py/dev/3x/root/fwd/Library/Frameworks/pytest_10.8.framework/Versions/3.4/lib/python3.4/tkinter/test/support.py", line 493, in test_wraplength self.checkParams(widget, 'wraplength', 100) File "/py/dev/3x/root/fwd/Library/Frameworks/pytest_10.8.framework/Versions/3.4/lib/python3.4/tkinter/test/support.py", line 186, in checkParams self.checkParam(widget, name, value, **kwargs) File "/py/dev/3x/root/fwd/Library/Frameworks/pytest_10.8.framework/Versions/3.4/lib/python3.4/tkinter/test/support.py", line 161, in checkParam self.assertEqual2(widget[name], expected, eq=eq) File "/py/dev/3x/root/fwd/Library/Frameworks/pytest_10.8.framework/Versions/3.4/lib/python3.4/tkinter/test/support.py", line 145, in assertEqual2 self.assertEqual(actual, expected, msg) AssertionError: <pixel object: '100'> != 100

====================================================================== FAIL: test_length (tkinter.test.test_ttk.test_widgets.ProgressbarTest)

Traceback (most recent call last): File "/py/dev/3x/root/fwd/Library/Frameworks/pytest_10.8.framework/Versions/3.4/lib/python3.4/tkinter/test/test_ttk/test_widgets.py", line 876, in test_length self.checkPixelsParam(widget, 'length', 100.1, 56.7, '2i') File "/py/dev/3x/root/fwd/Library/Frameworks/pytest_10.8.framework/Versions/3.4/lib/python3.4/tkinter/test/support.py", line 260, in checkPixelsParam conv=conv, **kwargs) File "/py/dev/3x/root/fwd/Library/Frameworks/pytest_10.8.framework/Versions/3.4/lib/python3.4/tkinter/test/support.py", line 161, in checkParam self.assertEqual2(widget[name], expected, eq=eq) File "/py/dev/3x/root/fwd/Library/Frameworks/pytest_10.8.framework/Versions/3.4/lib/python3.4/tkinter/test/support.py", line 145, in assertEqual2 self.assertEqual(actual, expected, msg) AssertionError: <pixel object: '100.1'> != 100.1

====================================================================== FAIL: test_length (tkinter.test.test_ttk.test_widgets.ScaleTest)

Traceback (most recent call last): File "/py/dev/3x/root/fwd/Library/Frameworks/pytest_10.8.framework/Versions/3.4/lib/python3.4/tkinter/test/test_ttk/test_widgets.py", line 787, in test_length self.checkPixelsParam(widget, 'length', 130, 131.2, 135.6, '5i') File "/py/dev/3x/root/fwd/Library/Frameworks/pytest_10.8.framework/Versions/3.4/lib/python3.4/tkinter/test/support.py", line 260, in checkPixelsParam conv=conv, **kwargs) File "/py/dev/3x/root/fwd/Library/Frameworks/pytest_10.8.framework/Versions/3.4/lib/python3.4/tkinter/test/support.py", line 161, in checkParam self.assertEqual2(widget[name], expected, eq=eq) File "/py/dev/3x/root/fwd/Library/Frameworks/pytest_10.8.framework/Versions/3.4/lib/python3.4/tkinter/test/support.py", line 145, in assertEqual2 self.assertEqual(actual, expected, msg) AssertionError: <pixel object: '130'> != 130

====================================================================== FAIL: test_orient (tkinter.test.test_ttk.test_widgets.ScrollbarTest)

Traceback (most recent call last): File "/py/dev/3x/root/fwd/Library/Frameworks/pytest_10.8.framework/Versions/3.4/lib/python3.4/tkinter/test/support.py", line 426, in test_orient self.checkEnumParam(widget, 'orient', 'horizontal', 'vertical') File "/py/dev/3x/root/fwd/Library/Frameworks/pytest_10.8.framework/Versions/3.4/lib/python3.4/tkinter/test/support.py", line 244, in checkEnumParam errmsg='ambiguous' + errmsg2) File "/py/dev/3x/root/fwd/Library/Frameworks/pytest_10.8.framework/Versions/3.4/lib/python3.4/tkinter/test/support.py", line 174, in checkInvalidParam widget[name] = value AssertionError: TclError not raised

====================================================================== FAIL: test_height (tkinter.test.test_ttk.test_widgets.TreeviewTest)

Traceback (most recent call last): File "/py/dev/3x/root/fwd/Library/Frameworks/pytest_10.8.framework/Versions/3.4/lib/python3.4/tkinter/test/support.py", line 556, in test_height self.checkPixelsParam(widget, 'height', 100, 101.2, 102.6, -100, 0, '3c') File "/py/dev/3x/root/fwd/Library/Frameworks/pytest_10.8.framework/Versions/3.4/lib/python3.4/tkinter/test/support.py", line 260, in checkPixelsParam conv=conv, **kwargs) File "/py/dev/3x/root/fwd/Library/Frameworks/pytest_10.8.framework/Versions/3.4/lib/python3.4/tkinter/test/support.py", line 161, in checkParam self.assertEqual2(widget[name], expected, eq=eq) File "/py/dev/3x/root/fwd/Library/Frameworks/pytest_10.8.framework/Versions/3.4/lib/python3.4/tkinter/test/support.py", line 145, in assertEqual2 self.assertEqual(actual, expected, msg) AssertionError: <pixel object: '101.2'> != 101.2


Ran 233 tests in 3.203s

FAILED (failures=12, errors=2, skipped=1) test test_ttk_guionly failed