function it_should_resolve_base_dn_parameters_when_querying_ldap($connection)
{
$schema = new LdapObjectSchema('ad', 'user');
$schema->setBaseDn('%_configurationnamingcontext_%');
$schema->setFilter(new Comparison('foo', '=', 'bar'));
$this->operation->getFilter()->addLdapObjectSchema($schema);
$this->operation->setBaseDn('%_configurationnamingcontext_%');
$connection->execute(Argument::that(function ($op) {
return $op->getBaseDn() == 'cn=Configuration,dc=example,dc=local';
}))->willReturn($this->ldapEntries);
$this->execute();
}