[#1461] meta: Return error on lock object removal

Signed-off-by: Pavel Karpy <carpawell@nspcc.ru>
This commit is contained in:
Pavel Karpy 2022-06-06 17:44:37 +03:00 committed by fyrchik
parent b5c56d459a
commit 18ec5d7c8e
3 changed files with 18 additions and 6 deletions

View file

@ -9,6 +9,7 @@ import (
objectV2 "github.com/nspcc-dev/neofs-api-go/v2/object"
objectcore "github.com/nspcc-dev/neofs-node/pkg/core/object"
meta "github.com/nspcc-dev/neofs-node/pkg/local_object_storage/metabase"
"github.com/nspcc-dev/neofs-node/pkg/local_object_storage/shard"
"github.com/nspcc-dev/neofs-node/pkg/util"
apistatus "github.com/nspcc-dev/neofs-sdk-go/client/status"
@ -133,7 +134,7 @@ func TestLockUserScenario(t *testing.T) {
inhumePrm.WithTarget(tombForLockAddr, lockerAddr)
_, err = e.Inhume(inhumePrm)
require.NoError(t, err, new(apistatus.ObjectLocked))
require.ErrorIs(t, err, meta.ErrLockObjectRemoval)
// 5.
for i := range chEvents {