'Set the configuration, and verify that the hash of the configuration is
correct.
:param configuration: The new configuration.
:param verify_hash: The expected generation hash of the new
configuration.
:raises: ValueError if the new configuration does not have the
specified hash.'

def _set_configuration(self, configuration, verify_hash):

    candidate_hash = make_generation_hash(configuration)
    if (candidate_hash != verify_hash):
        raise ValueError(('Bad    hash    value    %s    is    not    %s' % (candidate_hash, verify_hash)))
    self._current_configuration = configuration
    self._current_configuration_generation = candidate_hash
