summaryrefslogtreecommitdiff
path: root/tests/stty.test
diff options
context:
space:
mode:
Diffstat (limited to 'tests/stty.test')
-rw-r--r--tests/stty.test33
1 files changed, 33 insertions, 0 deletions
diff --git a/tests/stty.test b/tests/stty.test
new file mode 100644
index 0000000..64f73b9
--- /dev/null
+++ b/tests/stty.test
@@ -0,0 +1,33 @@
+# Commands covered: stty
+#
+# 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.
+
+if {[lsearch [namespace children] ::tcltest] == -1} {
+ package require tcltest
+ # do this in a way that is backward compatible for Tcl 8.3
+ namespace import ::tcltest::test ::tcltest::cleanupTests
+}
+package require Expect
+
+#exp_internal -f /dev/ttyp5 0
+
+catch {unset x}
+
+log_user 0
+
+test stty-1.1 {basic stty operation} {
+ exp_spawn cat -u
+ catch {exp_stty < $spawn_out(slave,name)}
+} {0}
+
+test stty-1.2 {basic stty operation} {
+ exp_spawn cat -u
+ catch {exp_stty -echo < $spawn_out(slave,name)}
+} {0}
+
+#exp_internal 0
+
+cleanupTests
+return