6997: Avoid unnecessarily inefficient dirent sorting (and a mismatch between index...
[arvados.git] / services / keepstore / handler_test.go
index 074e49999b449eca9dd82ba418fa5f0fe9401e8e..8be471025db5119fb25510d2305fdaaa5cbb7257 100644 (file)
@@ -231,6 +231,7 @@ func TestPutAndDeleteSkipReadonlyVolumes(t *testing.T) {
                        uri:          "/" + TEST_HASH,
                        request_body: TEST_BLOCK,
                })
+       never_delete = false
        IssueRequest(
                &RequestTester{
                        method:       "DELETE",
@@ -377,7 +378,7 @@ func TestIndexHandler(t *testing.T) {
                response)
 
        expected := `^` + TEST_HASH + `\+\d+ \d+\n` +
-               TEST_HASH_2 + `\+\d+ \d+\n$`
+               TEST_HASH_2 + `\+\d+ \d+\n\n$`
        match, _ := regexp.MatchString(expected, response.Body.String())
        if !match {
                t.Errorf(
@@ -393,7 +394,7 @@ func TestIndexHandler(t *testing.T) {
                http.StatusOK,
                response)
 
-       expected = `^` + TEST_HASH + `\+\d+ \d+\n$`
+       expected = `^` + TEST_HASH + `\+\d+ \d+\n\n$`
        match, _ = regexp.MatchString(expected, response.Body.String())
        if !match {
                t.Errorf(
@@ -448,6 +449,8 @@ func TestDeleteHandler(t *testing.T) {
        var user_token = "NOT DATA MANAGER TOKEN"
        data_manager_token = "DATA MANAGER TOKEN"
 
+       never_delete = false
+
        unauth_req := &RequestTester{
                method: "DELETE",
                uri:    "/" + TEST_HASH,