diff --git a/audit/test/generate.go b/audit/test/generate.go index 813dffd2..ac14cfbc 100644 --- a/audit/test/generate.go +++ b/audit/test/generate.go @@ -5,14 +5,14 @@ import ( cidtest "github.com/nspcc-dev/neofs-sdk-go/container/id/test" "github.com/nspcc-dev/neofs-sdk-go/object" objecttest "github.com/nspcc-dev/neofs-sdk-go/object/test" - "github.com/nspcc-dev/neofs-sdk-go/version" + versiontest "github.com/nspcc-dev/neofs-sdk-go/version/test" ) // Generate returns random audit.Result. func Generate() *audit.Result { x := audit.NewResult() - x.SetVersion(version.Current()) + x.SetVersion(versiontest.Version()) x.SetContainerID(cidtest.GenerateID()) x.SetPublicKey([]byte("key")) x.SetComplete(true) diff --git a/version/test/generate.go b/version/test/generate.go new file mode 100644 index 00000000..1afecaa9 --- /dev/null +++ b/version/test/generate.go @@ -0,0 +1,17 @@ +package test + +import ( + "math/rand" + + "github.com/nspcc-dev/neofs-sdk-go/version" +) + +// Version returns random version.Version. +func Version() *version.Version { + x := version.New() + + x.SetMajor(rand.Uint32()) + x.SetMinor(rand.Uint32()) + + return x +}