* config/unix.exp: Call send_error instead of fail to prevent
authorTom Yu <tlyu@mit.edu>
Mon, 7 Feb 2000 23:51:13 +0000 (23:51 +0000)
committerTom Yu <tlyu@mit.edu>
Mon, 7 Feb 2000 23:51:13 +0000 (23:51 +0000)
referencing variables not yet set up by the test framework.

* lib/helpers.exp: Call kinit and kdestroy with the -5 flag to
deal with new program behavior.  Also call perror rather than
error to avoid spewing a stack trace.

git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@12021 dc483132-0cff-0310-8789-dd5450dbe970

src/lib/rpc/unit-test/ChangeLog
src/lib/rpc/unit-test/config/unix.exp
src/lib/rpc/unit-test/lib/helpers.exp

index fa42402985c2ed946b3e0362a15968749c8ee783..344713e432e7f7676b4f4d2dc6eaddd6c3a73b58 100644 (file)
@@ -1,3 +1,12 @@
+2000-02-07  Tom Yu  <tlyu@mit.edu>
+
+       * config/unix.exp: Call send_error instead of fail to prevent
+       referencing variables not yet set up by the test framework.
+
+       * lib/helpers.exp: Call kinit and kdestroy with the -5 flag to
+       deal with new program behavior.  Also call perror rather than
+       error to avoid spewing a stack trace.
+
 1999-10-26  Tom Yu  <tlyu@mit.edu>
 
        * Makefile.in: Clean up usage of CFLAGS, CPPFLAGS, DEFS, DEFINES,
index e266216743d0c912082a11083eed2d8343b98123..fe6dd036b83694c59e41b0f0a0e3ecb91f19eadf 100644 (file)
@@ -65,11 +65,11 @@ proc rpc_test_start { } {
        expect {
                "running" { }
                eof { 
-                       fail "server exited!"
+                       send_error "server exited!"
                        verbose $expect_out(buffer) 1
                }
                timeout { 
-                       fail "server didn't start in $timeout seconds"
+                       send_error "server didn't start in $timeout seconds"
                        verbose $expect_out(buffer) 1
                }
        }
index b33af6a50b62e3d205541832ebd4620acf8fd5c2..3d7b167fc50ee0cc3c6cefe4fa8a95fb98102245 100644 (file)
@@ -21,20 +21,20 @@ proc kinit {princ pass lifetime} {
        global kinit
        global wait_error_index wait_errno_index wait_status_index
 
-       spawn -noecho $kinit -l $lifetime $princ
+       spawn -noecho $kinit -5 -l $lifetime $princ
        expect {
                -re "Password for $princ.*: " { send "$pass\n" }
-               timeout { error "Timeout waiting for kinit"; close }
+               timeout { perror "Timeout waiting for kinit"; close }
        }
        expect { eof {} }
 
        set ret [wait]
        if {[lindex $ret $wait_error_index] == -1} {
-               error \
+               perror \
            "wait(kinit $princ) returned error [lindex $ret $wait_errno_index]"
        } else {
                if {[lindex $ret $wait_status_index] != 0} {
-                       error \
+                       perror \
                    "kinit $princ failed with [lindex $ret $wait_status_index]"
                }
        }
@@ -116,7 +116,7 @@ proc wait_client {testname ccname id status} {
        }
 
        set env(KRB5CCNAME) FILE:/tmp/krb5cc_rpc_test_$ccname
-       if {[catch "exec $kdestroy"] != 0} {
+       if {[catch "exec $kdestroy -5"] != 0} {
                error "$testname: cannot destroy client $ccname ccache"
        }