summaryrefslogtreecommitdiffstats
path: root/tests/winClipboard.test
diff options
context:
space:
mode:
authorhobbs <hobbs>2001-04-04 07:07:45 (GMT)
committerhobbs <hobbs>2001-04-04 07:07:45 (GMT)
commit8eee5368a9fac311805ccdb999a77fe521802819 (patch)
tree61a73e32fc3c0d6255424f8daa03496073e308dd /tests/winClipboard.test
parent7d045938e02b119cb12697a20f9f0e169e2da49d (diff)
downloadtk-8eee5368a9fac311805ccdb999a77fe521802819.zip
tk-8eee5368a9fac311805ccdb999a77fe521802819.tar.gz
tk-8eee5368a9fac311805ccdb999a77fe521802819.tar.bz2
* tests/winClipboard.test: improved results for understanding when
tests fail.
Diffstat (limited to 'tests/winClipboard.test')
-rw-r--r--tests/winClipboard.test26
1 files changed, 19 insertions, 7 deletions
diff --git a/tests/winClipboard.test b/tests/winClipboard.test
index fca13eb..3c67bb7 100644
--- a/tests/winClipboard.test
+++ b/tests/winClipboard.test
@@ -10,7 +10,7 @@
# Copyright (c) 1998-2000 by Scriptics Corporation.
# All rights reserved.
#
-# RCS: @(#) $Id: winClipboard.test,v 1.7 2000/04/12 18:52:14 hobbs Exp $
+# RCS: @(#) $Id: winClipboard.test,v 1.8 2001/04/04 07:07:45 hobbs Exp $
if {[lsearch [namespace children] ::tcltest] == -1} {
source [file join [pwd] [file dirname [info script]] defs.tcl]
@@ -33,23 +33,31 @@ test winClipboard-1.1 {TkSelGetSelection} {pcOnly} {
test winClipboard-1.2 {TkSelGetSelection} {pcOnly} {
clipboard clear
clipboard append {}
- list [selection get -selection CLIPBOARD] [testclipboard]
+ catch {selection get -selection CLIPBOARD} r1
+ catch {testclipboard} r2
+ list $r1 $r2
} {{} {}}
test winClipboard-1.3 {TkSelGetSelection & TkWinClipboardRender} {pcOnly} {
clipboard clear
clipboard append abcd
update
- list [selection get -selection CLIPBOARD] [testclipboard]
+ catch {selection get -selection CLIPBOARD} r1
+ catch {testclipboard} r2
+ list $r1 $r2
} {abcd abcd}
test winClipboard-1.4 {TkSelGetSelection & TkWinClipboardRender} {pcOnly} {
clipboard clear
clipboard append "line 1\nline 2"
- list [selection get -selection CLIPBOARD] [testclipboard]
+ catch {selection get -selection CLIPBOARD} r1
+ catch {testclipboard} r2
+ list $r1 $r2
} [list "line 1\nline 2" "line 1\r\nline 2"]
test winClipboard-1.5 {TkSelGetSelection & TkWinClipboardRender} {pcOnly} {
clipboard clear
clipboard append "line 1\u00c7\nline 2"
- list [selection get -selection CLIPBOARD] [testclipboard]
+ catch {selection get -selection CLIPBOARD} r1
+ catch {testclipboard} r2
+ list $r1 $r2
} [list "line 1\u00c7\nline 2" [bytestring "line 1\u00c7\r\nline 2"]]
test winClipboard-2.1 {TkSelUpdateClipboard reentrancy problem} {pcOnly} {
@@ -57,14 +65,18 @@ test winClipboard-2.1 {TkSelUpdateClipboard reentrancy problem} {pcOnly} {
clipboard append -type OUR_ACTION "action data"
clipboard append "string data"
update
- list [selection get -selection CLIPBOARD -type OUR_ACTION] [testclipboard]
+ catch {selection get -selection CLIPBOARD -type OUR_ACTION} r1
+ catch {testclipboard} r2
+ list $r1 $r2
} [list "action data" "string data"]
test winClipboard-2.2 {TkSelUpdateClipboard reentrancy problem} {pcOnly} {
clipboard clear
clipboard append -type OUR_ACTION "new data"
clipboard append "more data in string"
update
- list [testclipboard] [selection get -selection CLIPBOARD -type OUR_ACTION]
+ catch {testclipboard} r1
+ catch {selection get -selection CLIPBOARD -type OUR_ACTION} r2
+ list $r1 $r2
} [list "more data in string" "new data"]
# cleanup