2021-03-12 15:57:23 +03:00
|
|
|
package storagegrouptest
|
|
|
|
|
|
|
|
import (
|
2023-03-07 13:38:56 +03:00
|
|
|
refstest "git.frostfs.info/TrueCloudLab/frostfs-api-go/v2/refs/test"
|
|
|
|
"git.frostfs.info/TrueCloudLab/frostfs-api-go/v2/storagegroup"
|
2021-03-12 15:57:23 +03:00
|
|
|
)
|
|
|
|
|
|
|
|
func GenerateStorageGroup(empty bool) *storagegroup.StorageGroup {
|
|
|
|
m := new(storagegroup.StorageGroup)
|
|
|
|
|
|
|
|
if !empty {
|
|
|
|
m.SetValidationDataSize(44)
|
2022-09-17 10:39:11 +04:00
|
|
|
//nolint:staticcheck
|
2021-03-12 15:57:23 +03:00
|
|
|
m.SetExpirationEpoch(55)
|
2021-06-11 15:45:04 +03:00
|
|
|
m.SetMembers(refstest.GenerateObjectIDs(false))
|
2021-03-12 15:57:23 +03:00
|
|
|
}
|
|
|
|
|
|
|
|
m.SetValidationHash(refstest.GenerateChecksum(empty))
|
|
|
|
|
|
|
|
return m
|
|
|
|
}
|