Skip to content

Commit ab7a313

Browse files
author
Aaron Schlesinger
committed
fix(pkg/sshd/server_test.go): fix error and output expectations
now that the cleaner uses a sync.Mutex, we don’t have the case where the server might fail because the cleaner is cleaning up
1 parent 7d23f75 commit ab7a313

1 file changed

Lines changed: 4 additions & 4 deletions

File tree

pkg/sshd/server_test.go

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -203,10 +203,10 @@ func TestDelete(t *testing.T) {
203203
if err != nil {
204204
t.Fatalf("Failed to create client session: %s", err)
205205
}
206-
if out, err := sess.Output("git-upload-pack /" + repoName + ".git"); err == nil {
207-
t.Error("Expected concurrent delete error, got nothing")
208-
} else if string(out) == "OK" {
209-
t.Errorf("Expected error output, got %s", string(out))
206+
if out, err := sess.Output("git-upload-pack /" + repoName + ".git"); err != nil {
207+
t.Errorf("expected no error, got %s", err)
208+
} else if string(out) != "OK" {
209+
t.Errorf("Expected 'OK' output, got %s", string(out))
210210
}
211211
sess.Close()
212212
}

0 commit comments

Comments
 (0)