X-Git-Url: https://git.arvados.org/arvados.git/blobdiff_plain/eaf51fcce5551ab66b6e7453938db063871845a7..c512f060057f497030df8266f680d55084c0e860:/services/keepstore/handler_test.go diff --git a/services/keepstore/handler_test.go b/services/keepstore/handler_test.go index ba923cad76..3817ea1900 100644 --- a/services/keepstore/handler_test.go +++ b/services/keepstore/handler_test.go @@ -954,3 +954,19 @@ func TestGetHandlerNoBufferleak(t *testing.T) { case <-ok: } } + +func TestPutReplicationHeader(t *testing.T) { + defer teardown() + + KeepVM = MakeTestVolumeManager(2) + defer KeepVM.Close() + + resp := IssueRequest(&RequestTester{ + method: "PUT", + uri: "/" + TestHash, + requestBody: TestBlock, + }) + if r := resp.Header().Get("X-Keep-Replicas-Stored"); r != "1" { + t.Errorf("Got X-Keep-Replicas-Stored: %q, expected %q", r, "1") + } +}