frostfs-api-go/tombstone/test/generate.go
Airat Arifullin bc16a32c24 [#40] types: Generate StableMarshaler/StableSize methods for protobufs
* Add plugin option for protogen in Makefile
* Fix the generator for the plugin in util/protogen
* Erase convertable types, move helpful methods to gRPC protobufs
* Erase helpers for convertations
* Generate StableMarshlal/StableSize for protobufs by the protoc plugin

Signed-off-by: Airat Arifullin a.arifullin@yadro.com
2023-07-10 12:08:48 +03:00

18 lines
409 B
Go

package tombstonetest
import (
refstest "git.frostfs.info/TrueCloudLab/frostfs-api-go/v2/refs/test"
tombstone "git.frostfs.info/TrueCloudLab/frostfs-api-go/v2/tombstone/grpc"
)
func GenerateTombstone(empty bool) *tombstone.Tombstone {
m := new(tombstone.Tombstone)
if !empty {
m.SetExpirationEpoch(89)
m.SetSplitId([]byte{3, 2, 1})
m.SetMembers(refstest.GenerateObjectIDs(false))
}
return m
}