Revision faa4a3ea

b/kamaki/clients/pithos/rest_api.py
388 388

  
389 389
        path = path4url(self.account, self.container)
390 390
        success = kwargs.pop('success', 204)
391
        return self.delete(path, success=success)
391
        return self.delete(path, *args, success=success, **kwargs)
392 392

  
393 393
    def object_head(
394 394
            self, object,
b/kamaki/clients/pithos/test.py
391 391
                success=kwargs.pop('success', 202),
392 392
                **kwargs))
393 393

  
394
    @patch('%s.set_param' % rest_pkg)
395
    @patch('%s.delete' % rest_pkg, return_value=FR())
396
    def test_container_delete(self, delete, SP):
397
        for pm in product(
398
                (None, 'd473'),
399
                (None, 'd3l1m'),
400
                ((), ('someval',)),
401
                (dict(), dict(success=400), dict(k='v', v='k'))):
402
            args, kwargs = pm[-2:]
403
            pm = pm[:-2]
404
            self.client.container_delete(*(pm + args), **kwargs)
405
            unt, dlm = pm[-2:]
406
            self.assertEqual(SP.mock_calls[-2:], [
407
                call('until', unt, iff=unt),
408
                call('delimiter', dlm, iff=dlm)])
409
            self.assertEqual(delete.mock_calls[-1], call(
410
                '/%s/%s' % (self.client.account, self.client.container),
411
                *args,
412
                success=kwargs.pop('success', 204),
413
                **kwargs))
414

  
394 415

  
395 416
class Pithos(TestCase):
396 417

  

Also available in: Unified diff