summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorfvogel <fvogelnew1@free.fr>2016-05-22 20:55:05 (GMT)
committerfvogel <fvogelnew1@free.fr>2016-05-22 20:55:05 (GMT)
commita129a2159a084a7ead331d54273f5cf2a3a7a961 (patch)
tree8f45747111a0be81d61caec3707a94f5eaf3d8a3
parentc130191cfa0f21c3ab4ac1092745bc5c06a42e7a (diff)
downloadtk-a129a2159a084a7ead331d54273f5cf2a3a7a961.zip
tk-a129a2159a084a7ead331d54273f5cf2a3a7a961.tar.gz
tk-a129a2159a084a7ead331d54273f5cf2a3a7a961.tar.bz2
Added test checkbutton-1.7 to guard against regressions regarding [109865fa01]bug_109865fa01
-rw-r--r--tests/ttk/checkbutton.test16
1 files changed, 16 insertions, 0 deletions
diff --git a/tests/ttk/checkbutton.test b/tests/ttk/checkbutton.test
index e18ff32..6b79287 100644
--- a/tests/ttk/checkbutton.test
+++ b/tests/ttk/checkbutton.test
@@ -45,4 +45,20 @@ test checkbutton-1.6 "Checkbutton default variable" -body {
lappend result [info exists .cb] [set .cb] [.cb state]
} -result [list .cb 0 alternate 1 on selected 1 off {}]
+# Bug [109865fa01]
+test checkbutton-1.7 "Button destroyed by click" -body {
+ proc destroy_button {} {
+ destroy .top
+ }
+ toplevel .top
+ ttk::menubutton .top.mb -text Button -style TLabel
+ bind .top.mb <ButtonRelease-1> destroy_button
+ pack .top.mb
+ focus -force .top.mb
+ update
+ event generate .top.mb <1>
+ event generate .top.mb <ButtonRelease-1>
+ update ; # shall not trigger error invalid command name ".top.b"
+} -result {}
+
tcltest::cleanupTests