def test_delete_existing(self):
        d = self.save_leases()
        d.addCallback(lambda _: self.assertResult(
            b"DELETE", b"/configuration/leases/" + bytes(self.dataset1),
            request_body=None, expected_code=OK,
            expected_result=self.expected_lease1))

        def deleted(_):
            # Dataset 1 was removed:
            self.assertEqual(self.persistence_service.get().leases.keys(),
                             [self.dataset2])
        d.addCallback(deleted)
        return d
DELETE ``/configuration/leases/<dataset_id>`` releases that lease.
dataset/ETHPy150Open ClusterHQ/flocker/flocker/control/test/test_httpapi.py/LeasesTestsMixin.test_delete_existing