def METHOD_NAME(definition, provisioner, backend, provisioner_params):  # pylint: disable=no-self-use
    provisioner.get_or_create_instance(definition)
    assert len(provisioner.list_instances()) == 1
    provisioner.cleanup(wait=True)
    # validate cache has been cleaned up
    assert not provisioner.list_instances()
    # validate real termination
    provisioner = provisioner_factory.create_provisioner(backend=backend, **provisioner_params)
    assert not provisioner.list_instances(), "failed cleaning up resources"