forked from TrueCloudLab/frostfs-s3-gw
[#611] Split name processing from object info creation procedure
Signed-off-by: Alex Vanin <alexey@nspcc.ru>
This commit is contained in:
parent
97f81d3270
commit
e0136feb73
3 changed files with 51 additions and 71 deletions
|
@ -72,7 +72,7 @@ func newTestInfo(obj oid.ID, bkt *data.BucketInfo, name string, isDir bool) *dat
|
|||
return info
|
||||
}
|
||||
|
||||
func Test_objectInfoFromMeta(t *testing.T) {
|
||||
func Test_objectInfoName(t *testing.T) {
|
||||
var uid user.ID
|
||||
var id oid.ID
|
||||
var containerID cid.ID
|
||||
|
@ -158,7 +158,7 @@ func Test_objectInfoFromMeta(t *testing.T) {
|
|||
|
||||
for _, tc := range cases {
|
||||
t.Run(tc.name, func(t *testing.T) {
|
||||
info := objectInfoFromMeta(bkt, tc.object, tc.prefix, tc.delimiter)
|
||||
info := processObjectInfoName(objectInfoFromMeta(bkt, tc.object), tc.prefix, tc.delimiter)
|
||||
require.Equal(t, tc.result, info)
|
||||
})
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue