Skip to content
This repository was archived by the owner on Jul 24, 2023. It is now read-only.

Commit 20867ca

Browse files
committed
User mock builder
1 parent fd8a667 commit 20867ca

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

tests/AdldapTest.php

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -308,7 +308,9 @@ protected function getMockUser(array $attributes = [])
308308
protected function getMockConnection($methods = [])
309309
{
310310
$defaults = ['isBound', 'search', 'getEntries', 'bind', 'close'];
311-
$connection = $this->getMock(Ldap::class, array_merge($defaults, $methods));
311+
$connection = $this->getMockBuilder(Ldap::class)
312+
->setMethods(array_merge($defaults, $methods))
313+
->getMock();
312314

313315
$this->app['adldap']->getDefaultProvider()->setConnection($connection);
314316

0 commit comments

Comments
 (0)