[#570] *: Remove usage of deprecated elements from API Go library

Signed-off-by: Leonard Lyubich <leonard@nspcc.ru>
This commit is contained in:
Leonard Lyubich 2021-05-31 14:03:17 +03:00 committed by Leonard Lyubich
parent 70a7354e9d
commit 3dd10b6795
63 changed files with 285 additions and 270 deletions

View file

@ -8,7 +8,7 @@ import (
"testing"
"github.com/nspcc-dev/neofs-api-go/pkg"
"github.com/nspcc-dev/neofs-api-go/pkg/container"
cid "github.com/nspcc-dev/neofs-api-go/pkg/container/id"
objectSDK "github.com/nspcc-dev/neofs-api-go/pkg/object"
"github.com/nspcc-dev/neofs-api-go/pkg/owner"
"github.com/nspcc-dev/neofs-node/pkg/core/object"
@ -61,11 +61,11 @@ func testNewShard(t *testing.T, id int) *shard.Shard {
return s
}
func testCID() *container.ID {
func testCID() *cid.ID {
cs := [sha256.Size]byte{}
_, _ = rand.Read(cs[:])
id := container.NewID()
id := cid.New()
id.SetSHA256(cs)
return id
@ -81,7 +81,7 @@ func testOID() *objectSDK.ID {
return id
}
func generateRawObjectWithCID(t *testing.T, cid *container.ID) *object.RawObject {
func generateRawObjectWithCID(t *testing.T, cid *cid.ID) *object.RawObject {
version := pkg.NewVersion()
version.SetMajor(2)
version.SetMinor(1)