summaryrefslogtreecommitdiffstats
path: root/tests/focus.test
diff options
context:
space:
mode:
Diffstat (limited to 'tests/focus.test')
-rw-r--r--tests/focus.test15
1 files changed, 9 insertions, 6 deletions
diff --git a/tests/focus.test b/tests/focus.test
index 7da289d..626576d 100644
--- a/tests/focus.test
+++ b/tests/focus.test
@@ -2,8 +2,8 @@
# other procedures in the file tkFocus.c. It is organized in the
# standard fashion for Tcl tests.
#
-# Copyright (c) 1994-1996 Sun Microsystems, Inc.
-# Copyright (c) 1998-1999 by Scriptics Corporation.
+# Copyright © 1994-1996 Sun Microsystems, Inc.
+# Copyright © 1998-1999 by Scriptics Corporation.
# All rights reserved.
package require tcltest 2.2
@@ -11,6 +11,9 @@ eval tcltest::configure $argv
tcltest::loadTestedCommands
namespace import -force tcltest::test
+testConstraint failsOnUbuntu [expr {![info exists ::env(TRAVIS_OS_NAME)] || ![string match linux $::env(TRAVIS_OS_NAME)]}]
+testConstraint failsOnXQuarz [expr {$tcl_platform(os) ne "Darwin" || [tk windowingsystem] ne "x11" }]
+
proc focusSetup {} {
destroy .t
toplevel .t
@@ -308,7 +311,7 @@ in .t.b1 NotifyNonlinear
} .t.b1}
test focus-2.6 {TkFocusFilterEvent procedure, FocusIn events} -constraints {
- unix testwrapper
+ unix testwrapper failsOnUbuntu failsOnXQuarz
} -body {
focus .t.b1
focus .
@@ -320,7 +323,7 @@ test focus-2.6 {TkFocusFilterEvent procedure, FocusIn events} -constraints {
list $x $focusInfo
} -result {.t.b1 {press .t.b1 x}}
test focus-2.7 {TkFocusFilterEvent procedure, FocusOut events} -constraints {
- unix testwrapper
+ unix testwrapper failsOnUbuntu failsOnXQuarz
} -body {
set result {}
foreach detail {NotifyAncestor NotifyInferior NotifyNonlinear
@@ -341,7 +344,7 @@ test focus-2.8 {TkFocusFilterEvent procedure, FocusOut events} -constraints {
focus
} -result {.t.b1}
test focus-2.9 {TkFocusFilterEvent procedure, FocusOut events} -constraints {
- unix testwrapper
+ unix testwrapper failsOnUbuntu failsOnXQuarz
} -body {
focus .t.b1
event gen [testwrapper .] <FocusOut> -detail NotifyAncestor
@@ -599,7 +602,7 @@ cleanupbg
# Test 5.1 fails (before and after update)
test focus-5.1 {ChangeXFocus procedure, don't take focus unless have it} -constraints {
- unix testwrapper secureserver
+ unix testwrapper secureserver failsOnUbuntu failsOnXQuarz
} -body {
setupbg
focusSetup