summaryrefslogtreecommitdiffstats
path: root/tests/select.test
diff options
context:
space:
mode:
Diffstat (limited to 'tests/select.test')
-rw-r--r--tests/select.test197
1 files changed, 85 insertions, 112 deletions
diff --git a/tests/select.test b/tests/select.test
index 602d88d..8cbfd39 100644
--- a/tests/select.test
+++ b/tests/select.test
@@ -12,13 +12,10 @@
#
package require tcltest 2.1
-namespace import -force tcltest::configure
-namespace import -force tcltest::testsDirectory
-configure -testdir [file join [pwd] [file dirname [info script]]]
-configure -loadfile [file join [testsDirectory] constraints.tcl]
+eval tcltest::configure $argv
tcltest::loadTestedCommands
-namespace import -force tcltest::interpreter
+namespace import -force ::tk::test:loadTkCommand
global longValue selValue selInfo
@@ -130,13 +127,13 @@ test select-1.3 {Tk_CreateSelHandler procedure} {
set selInfo ""
list [selection get TEST] $selInfo
} {{Test value} {TEST 0 4000}}
-test select-1.4.1 {Tk_CreateSelHandler procedure} {unixOnly} {
+test select-1.4.1 {Tk_CreateSelHandler procedure} unix {
setup
selection handle .f1 {handler TEST} TEST
selection handle .f1 {handler STRING}
lsort [selection get TARGETS]
} {MULTIPLE STRING TARGETS TEST TIMESTAMP TK_APPLICATION TK_WINDOW UTF8_STRING}
-test select-1.4.2 {Tk_CreateSelHandler procedure} {macOrPc} {
+test select-1.4.2 {Tk_CreateSelHandler procedure} win {
setup
selection handle .f1 {handler TEST} TEST
selection handle .f1 {handler STRING}
@@ -151,7 +148,7 @@ test select-1.5 {Tk_CreateSelHandler procedure} {
set selInfo ""
list [selection get] $selInfo
} {{} {STRING 0 4000}}
-test select-1.6.1 {Tk_CreateSelHandler procedure} {unixOnly} {
+test select-1.6.1 {Tk_CreateSelHandler procedure} unix {
global selValue selInfo
setup
selection handle .f1 {handler TEST} TEST
@@ -164,7 +161,7 @@ test select-1.6.1 {Tk_CreateSelHandler procedure} {unixOnly} {
selection get -type TEST
list [set selInfo] [lsort [selection get TARGETS]]
} {{STRING 0 4000 TEST 0 4000 TEST2 0 4000} {MULTIPLE STRING TARGETS TEST TIMESTAMP TK_APPLICATION TK_WINDOW UTF8_STRING}}
-test select-1.6.2 {Tk_CreateSelHandler procedure} {macOrPc} {
+test select-1.6.2 {Tk_CreateSelHandler procedure} win {
global selValue selInfo
setup
selection handle .f1 {handler TEST} TEST
@@ -177,21 +174,21 @@ test select-1.6.2 {Tk_CreateSelHandler procedure} {macOrPc} {
selection get -type TEST
list [set selInfo] [lsort [selection get TARGETS]]
} {{STRING 0 4000 TEST 0 4000 TEST2 0 4000} {MULTIPLE STRING TARGETS TEST TIMESTAMP TK_APPLICATION TK_WINDOW}}
-test select-1.7.1 {Tk_CreateSelHandler procedure} {unixOnly} {
+test select-1.7.1 {Tk_CreateSelHandler procedure} unix {
setup
selection own -selection CLIPBOARD .f1
selection handle -selection CLIPBOARD .f1 {handler TEST} TEST
selection handle -selection PRIMARY .f1 {handler TEST2} STRING
list [lsort [selection get -selection PRIMARY TARGETS]] \
- [lsort [selection get -selection CLIPBOARD TARGETS]]
+ [lsort [selection get -selection CLIPBOARD TARGETS]]
} {{MULTIPLE STRING TARGETS TIMESTAMP TK_APPLICATION TK_WINDOW UTF8_STRING} {MULTIPLE TARGETS TEST TIMESTAMP TK_APPLICATION TK_WINDOW}}
-test select-1.7.2 {Tk_CreateSelHandler procedure} {macOrPc} {
+test select-1.7.2 {Tk_CreateSelHandler procedure} win {
setup
selection own -selection CLIPBOARD .f1
selection handle -selection CLIPBOARD .f1 {handler TEST} TEST
selection handle -selection PRIMARY .f1 {handler TEST2} STRING
list [lsort [selection get -selection PRIMARY TARGETS]] \
- [lsort [selection get -selection CLIPBOARD TARGETS]]
+ [lsort [selection get -selection CLIPBOARD TARGETS]]
} {{MULTIPLE STRING TARGETS TIMESTAMP TK_APPLICATION TK_WINDOW} {MULTIPLE TARGETS TEST TIMESTAMP TK_APPLICATION TK_WINDOW}}
test select-1.8 {Tk_CreateSelHandler procedure} {
setup
@@ -201,56 +198,56 @@ test select-1.8 {Tk_CreateSelHandler procedure} {
##############################################################################
-test select-2.1 {Tk_DeleteSelHandler procedure} {unixOnly} {
+test select-2.1 {Tk_DeleteSelHandler procedure} unix {
setup
- selection handle .f1 {handler STRING}
- selection handle -type TEST .f1 {handler TEST}
- selection handle -type USER .f1 {handler USER}
+ selection handle .f1 {handler STRING}
+ selection handle -type TEST .f1 {handler TEST}
+ selection handle -type USER .f1 {handler USER}
set result [list [lsort [selection get TARGETS]]]
selection handle -type TEST .f1 {}
lappend result [lsort [selection get TARGETS]]
} {{MULTIPLE STRING TARGETS TEST TIMESTAMP TK_APPLICATION TK_WINDOW USER UTF8_STRING} {MULTIPLE STRING TARGETS TIMESTAMP TK_APPLICATION TK_WINDOW USER UTF8_STRING}}
-test select-2.2 {Tk_DeleteSelHandler procedure} {unixOnly} {
+test select-2.2 {Tk_DeleteSelHandler procedure} unix {
setup
- selection handle .f1 {handler STRING}
- selection handle -type TEST .f1 {handler TEST}
- selection handle -type USER .f1 {handler USER}
+ selection handle .f1 {handler STRING}
+ selection handle -type TEST .f1 {handler TEST}
+ selection handle -type USER .f1 {handler USER}
set result [list [lsort [selection get TARGETS]]]
selection handle -type USER .f1 {}
lappend result [lsort [selection get TARGETS]]
} {{MULTIPLE STRING TARGETS TEST TIMESTAMP TK_APPLICATION TK_WINDOW USER UTF8_STRING} {MULTIPLE STRING TARGETS TEST TIMESTAMP TK_APPLICATION TK_WINDOW UTF8_STRING}}
-test select-2.3 {Tk_DeleteSelHandler procedure} {unixOnly} {
+test select-2.3 {Tk_DeleteSelHandler procedure} unix {
setup
selection own -selection CLIPBOARD .f1
- selection handle -selection PRIMARY .f1 {handler STRING}
- selection handle -selection CLIPBOARD .f1 {handler STRING}
+ selection handle -selection PRIMARY .f1 {handler STRING}
+ selection handle -selection CLIPBOARD .f1 {handler STRING}
selection handle -selection CLIPBOARD .f1 {}
list [lsort [selection get TARGETS]] \
[lsort [selection get -selection CLIPBOARD TARGETS]]
} {{MULTIPLE STRING TARGETS TIMESTAMP TK_APPLICATION TK_WINDOW UTF8_STRING} {MULTIPLE TARGETS TIMESTAMP TK_APPLICATION TK_WINDOW}}
-test select-2.4 {Tk_DeleteSelHandler procedure} {macOrPc} {
+test select-2.4 {Tk_DeleteSelHandler procedure} win {
setup
- selection handle .f1 {handler STRING}
- selection handle -type TEST .f1 {handler TEST}
- selection handle -type USER .f1 {handler USER}
+ selection handle .f1 {handler STRING}
+ selection handle -type TEST .f1 {handler TEST}
+ selection handle -type USER .f1 {handler USER}
set result [list [lsort [selection get TARGETS]]]
selection handle -type TEST .f1 {}
lappend result [lsort [selection get TARGETS]]
} {{MULTIPLE STRING TARGETS TEST TIMESTAMP TK_APPLICATION TK_WINDOW USER} {MULTIPLE STRING TARGETS TIMESTAMP TK_APPLICATION TK_WINDOW USER}}
-test select-2.5 {Tk_DeleteSelHandler procedure} {macOrPc} {
+test select-2.5 {Tk_DeleteSelHandler procedure} win {
setup
- selection handle .f1 {handler STRING}
- selection handle -type TEST .f1 {handler TEST}
- selection handle -type USER .f1 {handler USER}
+ selection handle .f1 {handler STRING}
+ selection handle -type TEST .f1 {handler TEST}
+ selection handle -type USER .f1 {handler USER}
set result [list [lsort [selection get TARGETS]]]
selection handle -type USER .f1 {}
lappend result [lsort [selection get TARGETS]]
} {{MULTIPLE STRING TARGETS TEST TIMESTAMP TK_APPLICATION TK_WINDOW USER} {MULTIPLE STRING TARGETS TEST TIMESTAMP TK_APPLICATION TK_WINDOW}}
-test select-2.6 {Tk_DeleteSelHandler procedure} {macOrPc} {
+test select-2.6 {Tk_DeleteSelHandler procedure} win {
setup
selection own -selection CLIPBOARD .f1
- selection handle -selection PRIMARY .f1 {handler STRING}
- selection handle -selection CLIPBOARD .f1 {handler STRING}
+ selection handle -selection PRIMARY .f1 {handler STRING}
+ selection handle -selection CLIPBOARD .f1 {handler STRING}
selection handle -selection CLIPBOARD .f1 {}
list [lsort [selection get TARGETS]] \
[lsort [selection get -selection CLIPBOARD TARGETS]]
@@ -259,7 +256,7 @@ test select-2.7 {Tk_DeleteSelHandler procedure} {
setup
selection handle .f1 {handler STRING}
list [selection handle .f1 {}] [selection handle .f1 {}]
-} {{} {}}
+} {{} {}}
##############################################################################
@@ -306,7 +303,7 @@ test select-3.6 {Tk_OwnSelection procedure} {
selection clear .f1
lappend result $lostSel
} {owned lost2}
-test select-3.7 {Tk_OwnSelection procedure} {unixOnly} {
+test select-3.7 {Tk_OwnSelection procedure} unix {
global lostSel
setup
setupbg
@@ -332,7 +329,6 @@ test select-3.9 {Tk_OwnSelection procedure} {
selection own -selection CLIPBOARD -command { destroy .f2 } .f1
selection own -selection CLIPBOARD .f2
} {}
-
# multiple display tests
test select-3.10 {Tk_OwnSelection procedure} {altDisplay} {
setup .f1
@@ -370,7 +366,7 @@ test select-4.3 {Tk_ClearSelection procedure} {
setup
list [selection clear .f1] [selection clear .f1]
} {{} {}}
-test select-4.4 {Tk_ClearSelection procedure} {unixOnly} {
+test select-4.4 {Tk_ClearSelection procedure} unix {
global lostSel
setup
setupbg
@@ -383,7 +379,6 @@ test select-4.4 {Tk_ClearSelection procedure} {unixOnly} {
cleanupbg
lappend result [selection own]
} {{} {}}
-
# multiple display tests
test select-4.5 {Tk_ClearSelection procedure} {altDisplay} {
global lostSel lostSel2
@@ -398,7 +393,7 @@ test select-4.5 {Tk_ClearSelection procedure} {altDisplay} {
update
list $lostSel $lostSel2
} {owned lost2}
-test select-4.6 {Tk_ClearSelection procedure} {unixOnly altDisplay} {
+test select-4.6 {Tk_ClearSelection procedure} {unix altDisplay} {
setup .f1
setup .f2 $env(TK_ALT_DISPLAY)
setupbg
@@ -477,7 +472,7 @@ test select-5.8 {Tk_GetSelection procedure} {
selection handle .f1 {weirdHandler STRING}
list [selection get] $selInfo [catch {selection get} msg] $msg
} "$longValue {STRING 0 4000 STRING 4000 4000 STRING 8000 4000 STRING 12000 4000 STRING 16000 4000} 1 {PRIMARY selection doesn't exist or form \"STRING\" not defined}"
-test select-5.9 {Tk_GetSelection procedure} {unixOnly} {
+test select-5.9 {Tk_GetSelection procedure} unix {
setup
setupbg
selection handle -selection PRIMARY .f1 {handler TEST} TEST
@@ -489,7 +484,7 @@ test select-5.9 {Tk_GetSelection procedure} {unixOnly} {
cleanupbg
lappend result $selInfo
} {{Test value} {TEST 0 4000}}
-test select-5.10 {Tk_GetSelection procedure} {unixOnly} {
+test select-5.10 {Tk_GetSelection procedure} unix {
setup
setupbg
selection handle -selection PRIMARY .f1 {handler TEST} TEST
@@ -502,9 +497,7 @@ test select-5.10 {Tk_GetSelection procedure} {unixOnly} {
cleanupbg
lappend result $selInfo
} {{selection owner didn't respond} {}}
-
# multiple display tests
-
test select-5.11 {Tk_GetSelection procedure} {altDisplay} {
setup .f1
setup .f2 $env(TK_ALT_DISPLAY)
@@ -531,7 +524,7 @@ test select-5.12 {Tk_GetSelection procedure} {altDisplay} {
lappend result [catch {selection get -displayof .f2 TEST} msg] $msg \
$selInfo
} {0 {Test value} {TEST 0 4000} 1 {PRIMARY selection doesn't exist or form "TEST" not defined} {}}
-test select-5.13 {Tk_GetSelection procedure} {unixOnly altDisplay} {
+test select-5.13 {Tk_GetSelection procedure} {unix altDisplay} {
setup .f1
setup .f2 $env(TK_ALT_DISPLAY)
setupbg
@@ -549,7 +542,7 @@ test select-5.13 {Tk_GetSelection procedure} {unixOnly altDisplay} {
cleanupbg
lappend result $selInfo
} {{Test value} {Test value2} {TEST2 0 4000 TEST 0 4000}}
-test select-5.14 {Tk_GetSelection procedure} {unixOnly altDisplay} {
+test select-5.14 {Tk_GetSelection procedure} {unix altDisplay} {
setup .f1
setup .f2 $env(TK_ALT_DISPLAY)
setupbg
@@ -573,7 +566,6 @@ test select-5.14 {Tk_GetSelection procedure} {unixOnly altDisplay} {
test select-6.1 {Tk_SelectionCmd procedure} {
list [catch {selection} cmd] $cmd
} {1 {wrong # args: should be "selection option ?arg arg ...?"}}
-
# selection clear
test select-6.2 {Tk_SelectionCmd procedure} {
list [catch {selection clear -selection} cmd] $cmd
@@ -629,7 +621,6 @@ test select-6.11 {Tk_SelectionCmd procedure} {
test select-6.12 {Tk_SelectionCmd procedure} {
list [catch {selection clear foo bar} cmd] $cmd
} {1 {wrong # args: should be "selection clear ?options?"}}
-
# selection get
test select-6.13 {Tk_SelectionCmd procedure} {
list [catch {selection get -selection} cmd] $cmd
@@ -683,7 +674,6 @@ test select-6.21 {Tk_SelectionCmd procedure} {
set selInfo ""
list [selection get TEST] $selInfo
} {{Test value} {TEST 0 4000}}
-
# selection handle
# most of the handle section has been covered earlier
test select-6.22 {Tk_SelectionCmd procedure} {
@@ -715,7 +705,6 @@ test select-6.29 {Tk_SelectionCmd procedure} {
catch { destroy .f2 }
list [catch {selection handle .f2 dummy} cmd] $cmd
} {1 {bad window path name ".f2"}}
-
# selection own
test select-6.30 {Tk_SelectionCmd procedure} {
list [catch {selection own -selection} cmd] $cmd
@@ -758,57 +747,55 @@ test select-6.37 {Tk_SelectionCmd procedure} {
test select-6.38 {Tk_SelectionCmd procedure} {
list [catch {selection own foo bar baz} cmd] $cmd
} {1 {wrong # args: should be "selection own ?options? ?window?"}}
-
test select-6.39 {Tk_SelectionCmd procedure} {
list [catch {selection foo} cmd] $cmd
} {1 {bad option "foo": must be clear, get, handle, or own}}
##############################################################################
- # This test is non-portable because some old X11/News servers ignore
- # a selection request when the window doesn't exist, which causes a
- # different error message.
-
- test select-7.1 {TkSelDeadWindow procedure} {nonPortable} {
- setup
- selection handle .f1 { handler TEST }
- set result [selection own]
- destroy .f1
- lappend result [selection own] [catch { selection get } msg] $msg
- } {.f1 {} 1 {PRIMARY selection doesn't exist or form "STRING" not defined}}
+# This test is non-portable because some old X11/News servers ignore
+# a selection request when the window doesn't exist, which causes a
+# different error message.
+test select-7.1 {TkSelDeadWindow procedure} nonPortable {
+ setup
+ selection handle .f1 { handler TEST }
+ set result [selection own]
+ destroy .f1
+ lappend result [selection own] [catch {selection get} msg] $msg
+} {.f1 {} 1 {PRIMARY selection doesn't exist or form "STRING" not defined}}
##############################################################################
# Check reentrancy on losing selection
-test select-8.1 {TkSelEventProc procedure} {unixOnly} {
+test select-8.1 {TkSelEventProc procedure} -constraints unix -setup {
setup
setupbg
- selection own -selection CLIPBOARD -command { destroy .f1 } .f1
+} -body {
+ selection own -selection CLIPBOARD -command {destroy .f1} .f1
update
- set result [dobg {selection own -selection CLIPBOARD .}]
+ dobg {selection own -selection CLIPBOARD .}
+} -cleanup {
cleanupbg
- set result
-} {}
+} -result {}
##############################################################################
-test select-9.1 {SelCvtToX and SelCvtFromX procedures} {unixOnly} {
- global selValue selInfo
+test select-9.1 {SelCvtToX and SelCvtFromX procedures} -setup {
setup
setupbg
+} -constraints unix -body {
set selValue "1024"
set selInfo ""
selection handle -selection PRIMARY -format INTEGER -type TEST \
- .f1 {handler TEST}
+ .f1 {handler TEST}
update
set result ""
lappend result [dobg {selection get TEST}]
cleanupbg
lappend result $selInfo
-} {0x400 {TEST 0 4000}}
-test select-9.2 {SelCvtToX and SelCvtFromX procedures} {unixOnly} {
- global selValue selInfo
+} -result {{0x400 } {TEST 0 4000}}
+test select-9.2 {SelCvtToX and SelCvtFromX procedures} unix {
setup
setupbg
set selValue "1024 0xffff 2048 -2 "
@@ -819,9 +806,8 @@ test select-9.2 {SelCvtToX and SelCvtFromX procedures} {unixOnly} {
lappend result [dobg {selection get TEST}]
cleanupbg
lappend result $selInfo
-} {{0x400 0xffff 0x800 0xfffffffe} {TEST 0 4000}}
-test select-9.3 {SelCvtToX and SelCvtFromX procedures} {unixOnly} {
- global selValue selInfo
+} {{0x400 0xffff 0x800 0xfffffffe } {TEST 0 4000}}
+test select-9.3 {SelCvtToX and SelCvtFromX procedures} unix {
setup
setupbg
set selValue " "
@@ -832,9 +818,8 @@ test select-9.3 {SelCvtToX and SelCvtFromX procedures} {unixOnly} {
lappend result [dobg {selection get TEST}]
cleanupbg
lappend result $selInfo
-} {{} {TEST 0 4000}}
-test select-9.4 {SelCvtToX and SelCvtFromX procedures} {unixOnly} {
- global selValue selInfo
+} {{ } {TEST 0 4000}}
+test select-9.4 {SelCvtToX and SelCvtFromX procedures} unix {
setup
setupbg
set selValue "16 foobar 32"
@@ -845,7 +830,7 @@ test select-9.4 {SelCvtToX and SelCvtFromX procedures} {unixOnly} {
lappend result [dobg {selection get TEST}]
cleanupbg
lappend result $selInfo
-} {{0x10 0x0 0x20} {TEST 0 4000}}
+} {{0x10 0x0 0x20 } {TEST 0 4000}}
test select-9.5 {SelCvtToX and SelCvtFromX procedures} -setup {
setup
setupbg
@@ -867,14 +852,14 @@ test select-9.5 {SelCvtToX and SelCvtFromX procedures} -setup {
# note, we are not testing MULTIPLE style selections
# most control paths have been exercised above
-test select-10.1 {ConvertSelection procedure, race with selection clear} {unixOnly} {
+test select-10.1 {ConvertSelection procedure, race with selection clear} unix {
setup
proc Ready {fd} {
variable x
lappend x [gets $fd]
}
set fd [open "|[list [interpreter] -geometry +0+0 -name tktest]" r+]
- puts $fd "puts foo; flush stdout"
+ puts $fd "puts foo; [loadTkCommand]; flush stdout"
flush $fd
gets $fd
fileevent $fd readable [list Ready $fd]
@@ -890,10 +875,12 @@ test select-10.1 {ConvertSelection procedure, race with selection clear} {unixOn
vwait [namespace which -variable x]
puts $fd {exit}
flush $fd
- close $fd
+ # Don't understand why, but the [loadTkCommand] above causes
+ # a "broken pipe" error when Tk was actually [load]ed in the child.
+ catch {close $fd}
lappend x $selInfo
} {{1 PRIMARY selection doesn't exist or form "STRING" not defined} {}}
-test select-10.2 {ConvertSelection procedure} {unixOnly} {
+test select-10.2 {ConvertSelection procedure} unix {
setup
setupbg
set selValue [string range $longValue 0 3999]
@@ -904,7 +891,7 @@ test select-10.2 {ConvertSelection procedure} {unixOnly} {
cleanupbg
lappend result $selInfo
} [list [string range $longValue 0 3999] {STRING 0 4000 STRING 4000 4000 STRING 0 4000 STRING 4000 4000}]
-test select-10.3 {ConvertSelection procedure} {unixOnly} {
+test select-10.3 {ConvertSelection procedure} unix {
setup
setupbg
selection handle .f1 ERROR errHandler
@@ -915,7 +902,7 @@ test select-10.3 {ConvertSelection procedure} {unixOnly} {
} {{PRIMARY selection doesn't exist or form "ERROR" not defined}}
# testing timers
# This one hangs in Exceed
-test select-10.4 {ConvertSelection procedure} {unixOnly noExceed} {
+test select-10.4 {ConvertSelection procedure} {unix noExceed} {
setup
setupbg
set selValue $longValue
@@ -927,7 +914,7 @@ test select-10.4 {ConvertSelection procedure} {unixOnly noExceed} {
cleanupbg
lappend result $selInfo
} {{selection owner didn't respond} {STRING 0 4000 STRING 4000 4000 STRING 8000 4000 STRING 12000 4000 STRING 16000 4000 STRING 0 4000 STRING 4000 4000}}
-test select-10.5 {ConvertSelection procedure, reentrancy issues} {unixOnly} {
+test select-10.5 {ConvertSelection procedure, reentrancy issues} unix {
setup
setupbg
set selValue "Test value"
@@ -939,7 +926,7 @@ test select-10.5 {ConvertSelection procedure, reentrancy issues} {unixOnly} {
cleanupbg
lappend result $selInfo
} {{PRIMARY selection doesn't exist or form "STRING" not defined} {.f1 STRING 0 4000}}
-test select-10.6 {ConvertSelection procedure, reentrancy issues} {unixOnly} {
+test select-10.6 {ConvertSelection procedure, reentrancy issues} unix {
proc weirdHandler {type offset count} {
destroy .f1
handler $type $offset $count
@@ -958,7 +945,7 @@ test select-10.6 {ConvertSelection procedure, reentrancy issues} {unixOnly} {
##############################################################################
# testing reentrancy
-test select-11.1 {TkSelPropProc procedure} {unixOnly} {
+test select-11.1 {TkSelPropProc procedure} unix {
setup
setupbg
set selValue $longValue
@@ -975,15 +962,15 @@ test select-11.1 {TkSelPropProc procedure} {unixOnly} {
##############################################################################
# Note, this assumes we are using CurrentTtime
-test select-12.1 {DefaultSelection procedure} {unixOnly} {
+test select-12.1 {DefaultSelection procedure} unix {
setup
set result [selection get -type TIMESTAMP]
setupbg
lappend result [dobg {selection get -type TIMESTAMP}]
cleanupbg
set result
-} {0x0 0x0}
-test select-12.2 {DefaultSelection procedure} {unixOnly} {
+} {0x0 {0x0 }}
+test select-12.2 {DefaultSelection procedure} unix {
setup
set result [lsort [list [selection get -type TARGETS]]]
setupbg
@@ -991,7 +978,7 @@ test select-12.2 {DefaultSelection procedure} {unixOnly} {
cleanupbg
set result
} {{MULTIPLE TARGETS TIMESTAMP TK_APPLICATION TK_WINDOW} {MULTIPLE TARGETS TIMESTAMP TK_APPLICATION TK_WINDOW}}
-test select-12.3 {DefaultSelection procedure} {unixOnly} {
+test select-12.3 {DefaultSelection procedure} unix {
setup
selection handle .f1 {handler TEST} TEST
set result [list [lsort [selection get -type TARGETS]]]
@@ -1000,7 +987,7 @@ test select-12.3 {DefaultSelection procedure} {unixOnly} {
cleanupbg
set result
} {{MULTIPLE TARGETS TEST TIMESTAMP TK_APPLICATION TK_WINDOW} {MULTIPLE TARGETS TEST TIMESTAMP TK_APPLICATION TK_WINDOW}}
-test select-12.4 {DefaultSelection procedure} {unixOnly} {
+test select-12.4 {DefaultSelection procedure} unix {
setup
set result ""
lappend result [selection get -type TK_APPLICATION]
@@ -1009,7 +996,7 @@ test select-12.4 {DefaultSelection procedure} {unixOnly} {
cleanupbg
set result
} [list [winfo name .] [winfo name .]]
-test select-12.5 {DefaultSelection procedure} {unixOnly} {
+test select-12.5 {DefaultSelection procedure} unix {
setup
set result [selection get -type TK_WINDOW]
setupbg
@@ -1018,7 +1005,6 @@ test select-12.5 {DefaultSelection procedure} {unixOnly} {
set result
} {.f1 .f1}
test select-12.6 {DefaultSelection procedure} {
- global selValue selInfo
setup
selection handle .f1 {handler TARGETS.f1} TARGETS
set selValue "Targets value"
@@ -1028,7 +1014,7 @@ test select-12.6 {DefaultSelection procedure} {
lappend result [selection get TARGETS]
} {{Targets value} {TARGETS.f1 0 4000} {MULTIPLE TARGETS TIMESTAMP TK_APPLICATION TK_WINDOW}}
-test select-13.1 {SelectionSize procedure, handler deleted} {unixOnly} {
+test select-13.1 {SelectionSize procedure, handler deleted} unix {
proc badHandler {path type offset count} {
global selValue selInfo abortCount
incr abortCount -1
@@ -1057,18 +1043,5 @@ test select-13.1 {SelectionSize procedure, handler deleted} {unixOnly} {
catch {rename weirdHandler {}}
# cleanup
-::tcltest::cleanupTests
+cleanupTests
return
-
-
-
-
-
-
-
-
-
-
-
-
-