summaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authormdejong <mdejong>2002-06-14 07:17:53 (GMT)
committermdejong <mdejong>2002-06-14 07:17:53 (GMT)
commit8c18f8111d03425255bcd1d60b70da5c9ae5f521 (patch)
tree9833a60aa9cc30a18c1210e7283dc652af965645 /tests
parent05e959fcd9384aa5fd48d1c117f66461f829e4ee (diff)
downloadtk-8c18f8111d03425255bcd1d60b70da5c9ae5f521.zip
tk-8c18f8111d03425255bcd1d60b70da5c9ae5f521.tar.gz
tk-8c18f8111d03425255bcd1d60b70da5c9ae5f521.tar.bz2
* tests/winfo.test: Add basic tests for winfo ismapped.
Diffstat (limited to 'tests')
-rw-r--r--tests/winfo.test24
1 files changed, 23 insertions, 1 deletions
diff --git a/tests/winfo.test b/tests/winfo.test
index 443ab66..a1344c9 100644
--- a/tests/winfo.test
+++ b/tests/winfo.test
@@ -6,7 +6,7 @@
# Copyright (c) 1998-1999 by Scriptics Corporation.
# All rights reserved.
#
-# RCS: @(#) $Id: winfo.test,v 1.5 2000/03/02 23:52:57 hobbs Exp $
+# RCS: @(#) $Id: winfo.test,v 1.6 2002/06/14 07:17:53 mdejong Exp $
if {[lsearch [namespace children] ::tcltest] == -1} {
source [file join [pwd] [file dirname [info script]] defs.tcl]
@@ -360,6 +360,28 @@ test winfo-13.4 {[winfo containing] with embedded windows} {
set z
} 0
+test winfo-14.1 {usage} {
+ list [catch {winfo ismapped} msg] $msg
+} {1 {wrong # args: should be "winfo ismapped window"}}
+
+test winfo-14.2 {usage} {
+ list [catch {winfo ismapped . .} msg] $msg
+} {1 {wrong # args: should be "winfo ismapped window"}}
+
+test winfo-14.3 {initially unmapped} {
+ catch {destroy .t}
+ toplevel .t
+ winfo ismapped .t
+} 0
+
+test winfo-14.4 {mapped at idle time} {
+ catch {destroy .t}
+ toplevel .t
+ update idletasks
+ winfo ismapped .t
+} 1
+
+
foreach i [winfo children .] {
catch {destroy $i}
}