[MM-58020] Improve error message of NotFound errors in store (#26870)

* Improve error message of NotFound errors in store

* update mmctl tests
Этот коммит содержится в:
Ben Schumacher
2024-05-07 15:30:48 +02:00
коммит произвёл GitHub
родитель d6543b9bd5
Коммит 09c39cf3ec
4 изменённых файлов: 37 добавлений и 9 удалений

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

@@ -357,7 +357,7 @@ func (s *MmctlE2ETestSuite) TestDeleteChannelsCmd() {
_, err = s.th.App.GetChannel(s.th.Context, channel.Id)
s.Require().NotNil(err)
s.Require().Equal(fmt.Sprintf("GetChannel: Unable to find the existing channel., resource: Channel id: %s", channel.Id), err.Error())
s.Require().Equal(fmt.Sprintf("GetChannel: Unable to find the existing channel., resource \"Channel\" not found, id: %s", channel.Id), err.Error())
})
s.Run("Delete channel without permissions", func() {
@@ -401,7 +401,7 @@ func (s *MmctlE2ETestSuite) TestDeleteChannelsCmd() {
s.Require().Nil(channel)
s.Require().NotNil(err)
s.Require().Equal(fmt.Sprintf("GetChannel: Unable to find the existing channel., resource: Channel id: %s", notExistingChannelID), err.Error())
s.Require().Equal(fmt.Sprintf("GetChannel: Unable to find the existing channel., resource \"Channel\" not found, id: %s", notExistingChannelID), err.Error())
})
}