'init_host will clean an available volume stuck in uploading.'

def test_init_host_clears_uploads_available_volume(self):

    volume = tests_utils.create_volume(self.context, status='uploading', size=0, host=CONF.host)
    db.worker_create(self.context, resource_type='Volume', resource_id=volume.id, status=volume.status, service_id=self.service_id)
    self.volume.init_host(service_id=service.Service.service_id)
    volume.refresh()
    self.assertEqual('available', volume.status)
    self._assert_workers_are_removed()
