summaryrefslogtreecommitdiffstats
path: root/tests/busy.test
diff options
context:
space:
mode:
authorpatthoyts <patthoyts@users.sourceforge.net>2008-11-03 11:54:25 (GMT)
committerpatthoyts <patthoyts@users.sourceforge.net>2008-11-03 11:54:25 (GMT)
commitcd474b4ece2ad8856cb4ee6069a1ab529d9c5e9f (patch)
tree14292f05436a5ebc7a578e9155b3465c1952ab9e /tests/busy.test
parent8cf11854f1c55ec1026a5bddb868f6072dbf1a45 (diff)
downloadtk-cd474b4ece2ad8856cb4ee6069a1ab529d9c5e9f.zip
tk-cd474b4ece2ad8856cb4ee6069a1ab529d9c5e9f.tar.gz
tk-cd474b4ece2ad8856cb4ee6069a1ab529d9c5e9f.tar.bz2
busy tests: the default wait cursor on windows is wait not watch, so added suitable constraints and cloned some tests
Diffstat (limited to 'tests/busy.test')
-rw-r--r--tests/busy.test69
1 files changed, 62 insertions, 7 deletions
diff --git a/tests/busy.test b/tests/busy.test
index a35fb60..a402fff 100644
--- a/tests/busy.test
+++ b/tests/busy.test
@@ -6,7 +6,7 @@
#
# Copyright (c) 1998-2000 by Jos Decoster. All rights reserved.
#
-# RCS: @(#) $Id: busy.test,v 1.1 2008/10/18 14:22:22 dkf Exp $
+# RCS: @(#) $Id: busy.test,v 1.2 2008/11/03 11:54:25 patthoyts Exp $
package require tcltest 2.1
tcltest::configure {*}$argv
@@ -177,9 +177,11 @@ test busy-3.7 {tk busy cget unix} -setup {
test busy-4.1 {tk busy configure no window} -returnCodes error -body {
tk busy configure
} -result {wrong # args: should be "tk busy configure window ?option? ?value ...?"}
+
test busy-4.2 {tk busy configure invalid window} -body {
tk busy configure .f
} -returnCodes error -result {bad window path name ".f"}
+
test busy-4.3 {tk busy configure non-busy window} -setup {
pack [frame .f]
} -body {
@@ -187,7 +189,8 @@ test busy-4.3 {tk busy configure non-busy window} -setup {
} -cleanup {
destroy .f
} -returnCodes error -result {can't find busy window ".f"}
-test busy-4.4 {tk busy configure} -setup {
+
+test busy-4.4 {tk busy configure} -constraints {nonwin} -setup {
pack [frame .f]
tk busy hold .f
update
@@ -197,7 +200,19 @@ test busy-4.4 {tk busy configure} -setup {
tk busy forget .f
destroy .f
} -result {{-cursor cursor Cursor watch watch}}
-test busy-4.5 {tk busy configure} -setup {
+
+test busy-4.4-win {tk busy configure} -constraints {win} -setup {
+ pack [frame .f]
+ tk busy hold .f
+ update
+} -body {
+ tk busy configure .f
+} -cleanup {
+ tk busy forget .f
+ destroy .f
+} -result {{-cursor cursor Cursor wait wait}}
+
+test busy-4.5 {tk busy configure} -constraints {nonwin tempNotMac} -setup {
pack [frame .f]
tk busy hold .f -cursor hand2
update
@@ -206,7 +221,19 @@ test busy-4.5 {tk busy configure} -setup {
} -cleanup {
tk busy forget .f
destroy .f
-} -result {{-cursor cursor Cursor watch hand2}} -constraints tempNotMac
+} -result {{-cursor cursor Cursor watch hand2}}
+
+test busy-4.5-win {tk busy configure} -constraints win -setup {
+ pack [frame .f]
+ tk busy hold .f -cursor hand2
+ update
+} -body {
+ tk busy configure .f
+} -cleanup {
+ tk busy forget .f
+ destroy .f
+} -result {{-cursor cursor Cursor wait hand2}}
+
test busy-4.6 {tk busy configure invalid option} -setup {
pack [frame .f]
tk busy hold .f
@@ -217,7 +244,8 @@ test busy-4.6 {tk busy configure invalid option} -setup {
tk busy forget .f
destroy .f
} -returnCodes error -result {unknown option "-invalidOption"}
-test busy-4.7 {tk busy configure valid option} -setup {
+
+test busy-4.7 {tk busy configure valid option} -constraints {nonwin} -setup {
pack [frame .f]
tk busy hold .f
update
@@ -227,7 +255,21 @@ test busy-4.7 {tk busy configure valid option} -setup {
tk busy forget .f
destroy .f
} -result {-cursor cursor Cursor watch watch}
-test busy-4.8 {tk busy configure valid option} -setup {
+
+test busy-4.7-win {tk busy configure valid option} -constraints {win} -setup {
+ pack [frame .f]
+ tk busy hold .f
+ update
+} -body {
+ tk busy configure .f -cursor
+} -cleanup {
+ tk busy forget .f
+ destroy .f
+} -result {-cursor cursor Cursor wait wait}
+
+test busy-4.8 {tk busy configure valid option} -constraints {
+ nonwin tempNotMac
+} -setup {
pack [frame .f]
tk busy hold .f -cursor circle
update
@@ -236,7 +278,19 @@ test busy-4.8 {tk busy configure valid option} -setup {
} -cleanup {
tk busy forget .f
destroy .f
-} -result {-cursor cursor Cursor watch circle} -constraints tempNotMac
+} -result {-cursor cursor Cursor watch circle}
+
+test busy-4.8-win {tk busy configure valid option} -constraints win -setup {
+ pack [frame .f]
+ tk busy hold .f -cursor circle
+ update
+} -body {
+ tk busy configure .f -cursor
+} -cleanup {
+ tk busy forget .f
+ destroy .f
+} -result {-cursor cursor Cursor wait circle}
+
test busy-4.9 {tk busy configure valid option with value} -setup {
pack [frame .f]
tk busy hold .f
@@ -248,6 +302,7 @@ test busy-4.9 {tk busy configure valid option with value} -setup {
tk busy forget .f
destroy .f
} -result {pencil} -constraints tempNotMac
+
test busy-4.10 {tk busy configure valid option with invalid value} -setup {
pack [frame .f]
tk busy hold .f