forked from TrueCloudLab/frostfs-s3-gw
[#253] Caches refactoring
Signed-off-by: Denis Kirillov <denis@nspcc.ru>
This commit is contained in:
parent
951eb6fda8
commit
19b917e3b5
30 changed files with 365 additions and 322 deletions
|
@ -5,7 +5,7 @@ import (
|
|||
"testing"
|
||||
"time"
|
||||
|
||||
"github.com/nspcc-dev/neofs-s3-gw/api"
|
||||
"github.com/nspcc-dev/neofs-s3-gw/api/data"
|
||||
"github.com/nspcc-dev/neofs-s3-gw/api/errors"
|
||||
"github.com/nspcc-dev/neofs-s3-gw/api/layer"
|
||||
"github.com/stretchr/testify/require"
|
||||
|
@ -46,8 +46,8 @@ func TestFetchRangeHeader(t *testing.T) {
|
|||
}
|
||||
}
|
||||
|
||||
func newInfo(etag string, created time.Time) *api.ObjectInfo {
|
||||
return &api.ObjectInfo{
|
||||
func newInfo(etag string, created time.Time) *data.ObjectInfo {
|
||||
return &data.ObjectInfo{
|
||||
HashSum: etag,
|
||||
Created: created,
|
||||
}
|
||||
|
@ -61,13 +61,13 @@ func TestPreconditions(t *testing.T) {
|
|||
|
||||
for _, tc := range []struct {
|
||||
name string
|
||||
info *api.ObjectInfo
|
||||
info *data.ObjectInfo
|
||||
args *conditionalArgs
|
||||
expected error
|
||||
}{
|
||||
{
|
||||
name: "no conditions",
|
||||
info: new(api.ObjectInfo),
|
||||
info: new(data.ObjectInfo),
|
||||
args: new(conditionalArgs),
|
||||
expected: nil,
|
||||
},
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue