Skip to content

Commit 9f29ed5

Browse files
committed
Fixed status codes in tests.
1 parent b0e6b8e commit 9f29ed5

File tree

2 files changed

+9
-9
lines changed

2 files changed

+9
-9
lines changed

integrations/api_repo_lfs_locks_test.go

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -25,13 +25,13 @@ func TestAPILFSLocksNotStarted(t *testing.T) {
2525
repo := models.AssertExistsAndLoadBean(t, &models.Repository{ID: 1}).(*models.Repository)
2626

2727
req := NewRequestf(t, "GET", "/%s/%s.git/info/lfs/locks", user.Name, repo.Name)
28-
MakeRequest(t, req, http.StatusForbidden)
28+
MakeRequest(t, req, http.StatusNotFound)
2929
req = NewRequestf(t, "POST", "/%s/%s.git/info/lfs/locks", user.Name, repo.Name)
30-
MakeRequest(t, req, http.StatusForbidden)
30+
MakeRequest(t, req, http.StatusNotFound)
3131
req = NewRequestf(t, "GET", "/%s/%s.git/info/lfs/locks/verify", user.Name, repo.Name)
32-
MakeRequest(t, req, http.StatusForbidden)
32+
MakeRequest(t, req, http.StatusNotFound)
3333
req = NewRequestf(t, "GET", "/%s/%s.git/info/lfs/locks/10/unlock", user.Name, repo.Name)
34-
MakeRequest(t, req, http.StatusForbidden)
34+
MakeRequest(t, req, http.StatusNotFound)
3535
}
3636

3737
func TestAPILFSLocksNotLogin(t *testing.T) {

integrations/api_repo_lfs_test.go

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -29,15 +29,15 @@ func TestAPILFSNotStarted(t *testing.T) {
2929
repo := models.AssertExistsAndLoadBean(t, &models.Repository{ID: 1}).(*models.Repository)
3030

3131
req := NewRequestf(t, "POST", "/%s/%s.git/info/lfs/objects/batch", user.Name, repo.Name)
32-
MakeRequest(t, req, http.StatusForbidden)
32+
MakeRequest(t, req, http.StatusNotFound)
3333
req = NewRequestf(t, "PUT", "/%s/%s.git/info/lfs/objects/oid/10", user.Name, repo.Name)
34-
MakeRequest(t, req, http.StatusForbidden)
34+
MakeRequest(t, req, http.StatusNotFound)
3535
req = NewRequestf(t, "GET", "/%s/%s.git/info/lfs/objects/oid/name", user.Name, repo.Name)
36-
MakeRequest(t, req, http.StatusForbidden)
36+
MakeRequest(t, req, http.StatusNotFound)
3737
req = NewRequestf(t, "GET", "/%s/%s.git/info/lfs/objects/oid", user.Name, repo.Name)
38-
MakeRequest(t, req, http.StatusForbidden)
38+
MakeRequest(t, req, http.StatusNotFound)
3939
req = NewRequestf(t, "POST", "/%s/%s.git/info/lfs/verify", user.Name, repo.Name)
40-
MakeRequest(t, req, http.StatusForbidden)
40+
MakeRequest(t, req, http.StatusNotFound)
4141
}
4242

4343
func TestAPILFSMediaType(t *testing.T) {

0 commit comments

Comments
 (0)