|
@@ 252-259 (lines=8) @@
|
| 249 |
|
print(info) |
| 250 |
|
assert ret == {} |
| 251 |
|
|
| 252 |
|
def test_batch_rename_force(self): |
| 253 |
|
ret,info = self.bucket.rename(bucket_name, 'copyfrom', 'copyfrom', force='true') |
| 254 |
|
print(info) |
| 255 |
|
assert info.status_code == 200 |
| 256 |
|
ops = build_batch_rename(bucket_name, {'copyfrom':'copyfrom'}, force='true') |
| 257 |
|
ret, info = self.bucket.batch(ops) |
| 258 |
|
print(info) |
| 259 |
|
assert ret[0]['code'] == 200 |
| 260 |
|
|
| 261 |
|
def test_batch_stat(self): |
| 262 |
|
ops = build_batch_stat(bucket_name, ['python-sdk.html']) |
|
@@ 231-238 (lines=8) @@
|
| 228 |
|
print(info) |
| 229 |
|
assert ret == {} |
| 230 |
|
|
| 231 |
|
def test_batch_move_force(self): |
| 232 |
|
ret,info = self.bucket.copy(bucket_name, 'copyfrom', bucket_name, 'copyfrom', force='true') |
| 233 |
|
print(info) |
| 234 |
|
assert info.status_code == 200 |
| 235 |
|
ops = build_batch_move(bucket_name, {'copyfrom':'copyfrom'}, bucket_name,force='true') |
| 236 |
|
ret, info = self.bucket.batch(ops) |
| 237 |
|
print(info) |
| 238 |
|
assert ret[0]['code'] == 200 |
| 239 |
|
|
| 240 |
|
def test_batch_rename(self): |
| 241 |
|
key = 'rename'+rand_string(8) |