Commit 0d343c917d
Verified · cmc ci/build: success ci/test: success
Layout: unified · split
internal/sshd/revoke_test.go +5
| @@ -94,6 +94,11 @@ func TestRemoveKeyCutsConnection(t *testing.T) { | ||
| 94 | 94 | |
| 95 | 95 | func TestDisableCutsConnection(t *testing.T) { |
| 96 | 96 | ts := newTestServer(t) |
| 97 | // The client's handshake can finish before the server has recorded | |
| 98 | // the connection's account; a command answered proves it has. | |
| 99 | if code, errOut := execStatus(ts.client, "whoami"); code != 0 { | |
| 100 | t.Fatalf("whoami: %d %s", code, errOut) | |
| 101 | } | |
| 97 | 102 | if err := ts.st.SetUserDisabled(ts.uid, true); err != nil { |
| 98 | 103 | t.Fatal(err) |
| 99 | 104 | } |