forked from TrueCloudLab/frostfs-sdk-go
[#168] container: Replace []*Attribute with []Attribute
Signed-off-by: Alex Vanin <alexey@nspcc.ru>
This commit is contained in:
parent
cef9872b39
commit
98d4b5c926
4 changed files with 17 additions and 21 deletions
|
@ -74,14 +74,11 @@ func TestAttributes(t *testing.T) {
|
|||
vals = []string{"val1", "val2", "val3"}
|
||||
)
|
||||
|
||||
attrs := make(container.Attributes, 0, len(keys))
|
||||
attrs := make(container.Attributes, len(keys))
|
||||
|
||||
for i := range keys {
|
||||
attr := container.NewAttribute()
|
||||
attr.SetKey(keys[i])
|
||||
attr.SetValue(vals[i])
|
||||
|
||||
attrs = append(attrs, attr)
|
||||
attrs[i].SetKey(keys[i])
|
||||
attrs[i].SetValue(vals[i])
|
||||
}
|
||||
|
||||
t.Run("test v2", func(t *testing.T) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue