pull up r18691 from trunk
authorTom Yu <tlyu@mit.edu>
Thu, 26 Oct 2006 19:20:42 +0000 (19:20 +0000)
committerTom Yu <tlyu@mit.edu>
Thu, 26 Oct 2006 19:20:42 +0000 (19:20 +0000)
 r18691@cathode-dark-space:  raeburn | 2006-10-11 23:47:05 -0400
 ticket: 4355
 tags: pullup
 target_version: 1.5.2

 Add a policy to the database, then after the dump and restore, check
 that it's still there.

ticket: 43355
version_fixed: 1.5.2

git-svn-id: svn://anonsvn.mit.edu/krb5/branches/krb5-1-5@18739 dc483132-0cff-0310-8789-dd5450dbe970

src/tests/dejagnu/krb-standalone/standalone.exp

index 3799a51abe0a28e9fc8d2bd2d2ebb221b792d548..9a92b930350b9e271e46db2229e8cb316c299075 100644 (file)
@@ -99,6 +99,20 @@ proc doit { } {
        return
     }
 
+    spawn $KADMIN_LOCAL -q "addpol fred"
+    catch expect_after
+    expect {
+       timeout {
+           fail "kadmin.local addpol fred"
+       }
+       eof {
+           pass "kadmin.local addpol fred"
+       }
+    }
+    set k_stat [wait -i $spawn_id]
+    verbose "wait -i $spawn_id returned $k_stat (kadmin addpol)"
+    catch "close -i $spawn_id"
+
     # Use ksrvutil to create a srvtab entry.
     if ![setup_srvtab 1] {
        return
@@ -107,6 +121,23 @@ proc doit { } {
     # Test dump and load.  Continue on, whatever the result.
     dump_and_reload
 
+    spawn $KADMIN_LOCAL -q "getpols"
+    expect {
+       fred {
+           pass "kadmin.local getpols"
+           expect eof
+       }
+       timeout {
+           fail "kadmin.local getpols"
+       }
+       eof {
+           fail "kadmin.local getpols"
+       }
+    }
+    set k_stat [wait -i $spawn_id]
+    verbose "wait -i $spawn_id returned $k_stat (kadmin addpol)"
+    catch "close -i $spawn_id"
+
     # Use kinit to get a ticket.
     if ![kinit krbtest/admin adminpass$KEY 1] {
        return