Skip to content

Commit a1b5daf

Browse files
authored
testserver: better error message in resource not found case (#3210)
## Changes New 404 message looks like this: Resource catalog.VolumeInfo not found: main.myschema.myvolume ## Why This allows distinguishing between handler not set up correct and object not found issues. ## Tests Manually.
1 parent 98e9d4a commit a1b5daf

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

libs/testserver/fake_workspace.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,7 @@ func MapGet[T any](w *FakeWorkspace, collection map[string]T, key string) Respon
7070
if !ok {
7171
return Response{
7272
StatusCode: 404,
73+
Body: map[string]string{"message": fmt.Sprintf("Resource %T not found: %v", value, key)},
7374
}
7475
}
7576
return Response{

0 commit comments

Comments
 (0)