summaryrefslogtreecommitdiffstats
path: root/tests/ttk
diff options
context:
space:
mode:
Diffstat (limited to 'tests/ttk')
-rw-r--r--tests/ttk/checkbutton.test16
-rw-r--r--tests/ttk/combobox.test9
-rw-r--r--tests/ttk/treeview.test4
-rw-r--r--tests/ttk/ttk.test14
4 files changed, 11 insertions, 32 deletions
diff --git a/tests/ttk/checkbutton.test b/tests/ttk/checkbutton.test
index 6b79287..e18ff32 100644
--- a/tests/ttk/checkbutton.test
+++ b/tests/ttk/checkbutton.test
@@ -45,20 +45,4 @@ 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
diff --git a/tests/ttk/combobox.test b/tests/ttk/combobox.test
index 7ea0c5c..43f3cf1 100644
--- a/tests/ttk/combobox.test
+++ b/tests/ttk/combobox.test
@@ -45,15 +45,6 @@ test combobox-2.4 "current -- value not in list" -body {
test combobox-2.end "Cleanup" -body { destroy .cb }
-test combobox-3 "Read postoffset value dynamically from current style" -body {
- ttk::combobox .cb -values [list a b c] -style "DerivedStyle.TCombobox"
- pack .cb -expand true -fill both
- ttk::style configure DerivedStyle.TCombobox -postoffset [list 25 0 0 0]
- ttk::combobox::Post .cb
- expr {[winfo rootx .cb.popdown] - [winfo rootx .cb]}
-} -result 25 -cleanup {
- destroy .cb
-}
test combobox-1890211 "ComboboxSelected event after listbox unposted" -body {
# whitebox test...
diff --git a/tests/ttk/treeview.test b/tests/ttk/treeview.test
index aa7e64a..d8bc65d 100644
--- a/tests/ttk/treeview.test
+++ b/tests/ttk/treeview.test
@@ -405,7 +405,7 @@ test treeview-7.1 "move" -body {
test treeview-7.2 "illegal move" -body {
.tv move d d2 end
-} -returnCodes 1 -result "Cannot insert d as descendant of d2"
+} -returnCodes 1 -result "Cannot insert d as a descendant of d2"
test treeview-7.3 "illegal move has no effect" -body {
consistencyCheck .tv
@@ -426,7 +426,7 @@ test treeview-7.5 "replace children - precondition" -body {
test treeview-7.6 "Replace children - illegal move" -body {
.tv children newnode.n1 [list newnode.n1 newnode.n2 newnode.n3]
-} -returnCodes 1 -result "Cannot insert newnode.n1 as descendant of newnode.n1"
+} -returnCodes 1 -result "Cannot insert newnode.n1 as a descendant of newnode.n1"
consistencyCheck .tv
diff --git a/tests/ttk/ttk.test b/tests/ttk/ttk.test
index e58b021..def709e 100644
--- a/tests/ttk/ttk.test
+++ b/tests/ttk/ttk.test
@@ -48,7 +48,7 @@ test ttk-6.4 "Destroy widget in configure" -setup {
pack [ttk::checkbutton .b]
set rc [catch { .b configure -variable OUCH } msg]
list $rc $msg [winfo exists .b] [info commands .b]
-} -result [list 1 "widget has been destroyed" 0 {}]
+} -result [list 1 "Widget has been destroyed" 0 {}]
test ttk-6.5 "Clean up -textvariable traces" -body {
foreach class {ttk::button ttk::checkbutton ttk::radiobutton} {
@@ -121,7 +121,7 @@ test ttk-construction-failure-2 "Destroy widget in constructor" -setup {
[winfo exists .b] \
[info commands .b] \
;
-} -result [list 1 "widget has been destroyed" 0 {}]
+} -result [list 1 "Widget has been destroyed" 0 {}]
test ttk-selfdestruct-ok-1 "Intentional self-destruction" -body {
# see #2298720
@@ -222,11 +222,15 @@ test ttk-2.8 "bug 3223850: button state disabled during click" -setup {
foreach wc $widgetClasses {
test ttk-coreoptions-$wc "$wc has all core options" -body {
ttk::$wc .w
- foreach option {-class -style -cursor -takefocus} {
+ foreach option {
+ -class
+ -style
+ -cursor
+ -takefocus
+ } {
.w cget $option
}
- } -cleanup {
- catch {destroy .w}
+ destroy .w
}
}