summaryrefslogtreecommitdiffstats
path: root/tests/main.test
diff options
context:
space:
mode:
authorrjohnson <rjohnson>1998-04-01 09:51:44 (GMT)
committerrjohnson <rjohnson>1998-04-01 09:51:44 (GMT)
commit066ea7fd88d49cb456f74da71dbe875e4fc0aabb (patch)
tree8fb30cb152c4dc191be47fa043d2e6f5ea38c7ba /tests/main.test
parent13242623d2ff3ea02ab6a62bfb48a7dbb5c27e22 (diff)
downloadtk-066ea7fd88d49cb456f74da71dbe875e4fc0aabb.zip
tk-066ea7fd88d49cb456f74da71dbe875e4fc0aabb.tar.gz
tk-066ea7fd88d49cb456f74da71dbe875e4fc0aabb.tar.bz2
Initial revision
Diffstat (limited to 'tests/main.test')
-rw-r--r--tests/main.test31
1 files changed, 31 insertions, 0 deletions
diff --git a/tests/main.test b/tests/main.test
new file mode 100644
index 0000000..49365c3
--- /dev/null
+++ b/tests/main.test
@@ -0,0 +1,31 @@
+# This file contains tests for the tkMain.c file.
+#
+# This file contains a collection of tests for one or more of the Tcl
+# built-in commands. Sourcing this file into Tcl runs the tests and
+# generates output for errors. No output means no errors were found.
+#
+# Copyright (c) 1997 by Sun Microsystems, Inc.
+#
+# See the file "license.terms" for information on usage and redistribution
+# of this file, and for a DISCLAIMER OF ALL WARRANTIES.
+#
+# SCCS: @(#) main.test 1.2 97/09/10 17:49:20
+
+if {[info procs test] != "test"} {
+ source defs
+}
+
+test main-1.1 {StdinProc} {unixOnly} {
+ catch {removeFile script}
+ set fd [open script w]
+ puts $fd {
+ close stdin; exit
+ }
+ close $fd
+ if {[catch {exec $tktest <script} msg]} {
+ set error 1
+ } else {
+ set error 0
+ }
+ list $error $msg
+} {0 {}}