Put wrapped errors into the detailed field on serialization (#20846)

Этот коммит содержится в:
Tim Scheuermann
2022-08-18 14:22:12 +02:00
коммит произвёл GitHub
родитель 53985ef162
Коммит e665542c91
3 изменённых файлов: 68 добавлений и 1 удалений

Просмотреть файл

@@ -928,7 +928,7 @@ func TestPatchPost(t *testing.T) {
t.Run("invalid requests", func(t *testing.T) {
r, err := client.DoAPIPut("/posts/"+post.Id+"/patch", "garbage")
require.EqualError(t, err, ": Invalid or missing post in request body.")
require.EqualError(t, err, ": Invalid or missing post in request body., invalid character 'g' looking for beginning of value")
require.Equal(t, http.StatusBadRequest, r.StatusCode, "wrong status code")
patch := &model.PostPatch{}