From 0ebe5a2fa1b900cf5ec44b92a055fb2436111bce Mon Sep 17 00:00:00 2001 From: Dominik Schmidt Date: Mon, 7 Sep 2026 08:19:46 +0200 Subject: [PATCH] test(graph): root children permission denied is 404 --- services/graph/pkg/service/v0/driveitems_test.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/services/graph/pkg/service/v0/driveitems_test.go b/services/graph/pkg/service/v0/driveitems_test.go index 5ebf00f477..94a56999e7 100644 --- a/services/graph/pkg/service/v0/driveitems_test.go +++ b/services/graph/pkg/service/v0/driveitems_test.go @@ -142,7 +142,7 @@ var _ = Describe("Driveitems", func() { Expect(rr.Code).To(Equal(http.StatusNotFound)) }) - It("handles ListContainer permission denied", func() { + It("handles ListContainer permission denied as not found", func() { gatewayClient.On("ListStorageSpaces", mock.Anything, mock.Anything).Return(&provider.ListStorageSpacesResponse{ Status: status.NewOK(ctx), StorageSpaces: []*provider.StorageSpace{{Owner: currentUser, Root: &provider.ResourceId{}}}, @@ -154,7 +154,7 @@ var _ = Describe("Driveitems", func() { r := httptest.NewRequest(http.MethodGet, "/graph/v1.0/me/drive/root/children", nil) r = r.WithContext(revactx.ContextSetUser(ctx, currentUser)) svc.GetRootDriveChildren(rr, r) - Expect(rr.Code).To(Equal(http.StatusForbidden)) + Expect(rr.Code).To(Equal(http.StatusNotFound)) }) It("handles ListContainer error", func() {