forked from TrueCloudLab/rclone
swift: update github.com/ncw/swift to v2.0.0
The update to v2 of the swift library introduces a context parameter to each function. This required a lot of mostly mechanical changes adding context parameters. See: https://github.com/ncw/swift/issues/159 See: https://github.com/ncw/swift/issues/161
This commit is contained in:
parent
1545ace8f2
commit
bbe791a886
9 changed files with 88 additions and 87 deletions
|
@ -9,7 +9,7 @@ import (
|
|||
"io/ioutil"
|
||||
"testing"
|
||||
|
||||
"github.com/ncw/swift"
|
||||
"github.com/ncw/swift/v2"
|
||||
"github.com/rclone/rclone/fs"
|
||||
"github.com/rclone/rclone/fs/hash"
|
||||
"github.com/rclone/rclone/fs/object"
|
||||
|
@ -144,10 +144,10 @@ func (f *Fs) testWithChunkFail(t *testing.T) {
|
|||
// error is potato
|
||||
require.NotNil(t, err)
|
||||
require.Equal(t, errMessage, err.Error())
|
||||
_, _, err = f.c.Object(f.rootContainer, path)
|
||||
_, _, err = f.c.Object(ctx, f.rootContainer, path)
|
||||
assert.Equal(t, swift.ObjectNotFound, err)
|
||||
prefix := path
|
||||
objs, err := f.c.Objects(segmentContainer, &swift.ObjectsOpts{
|
||||
objs, err := f.c.Objects(ctx, segmentContainer, &swift.ObjectsOpts{
|
||||
Prefix: prefix,
|
||||
})
|
||||
require.NoError(t, err)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue