summaryrefslogtreecommitdiffstats
path: root/apps/user_ldap/tests
diff options
context:
space:
mode:
authorRoger Szabo <roger.szabo@web.de>2018-05-09 20:24:41 +0800
committerRoger Szabo <roger.szabo@web.de>2018-05-09 20:24:41 +0800
commitced15ab7567fd3dc72734993609d663e399748b6 (patch)
treeeb2beea88f879c3d69e9e9806e358b995b144436 /apps/user_ldap/tests
parent856164e5782c747f2ead917ecc99b900cc486802 (diff)
downloadnextcloud-server-ced15ab7567fd3dc72734993609d663e399748b6.tar.gz
nextcloud-server-ced15ab7567fd3dc72734993609d663e399748b6.zip
adjust unit tests for \"Invalid argument supplied for foreach()\" fix
Signed-off-by: Roger Szabo <roger.szabo@web.de>
Diffstat (limited to 'apps/user_ldap/tests')
-rw-r--r--apps/user_ldap/tests/User/UserTest.php8
1 files changed, 4 insertions, 4 deletions
diff --git a/apps/user_ldap/tests/User/UserTest.php b/apps/user_ldap/tests/User/UserTest.php
index 27bd7762e39..c61a9bd3d47 100644
--- a/apps/user_ldap/tests/User/UserTest.php
+++ b/apps/user_ldap/tests/User/UserTest.php
@@ -1132,7 +1132,7 @@ class UserTest extends \Test\TestCase {
$this->access->expects($this->any())
->method('search')
->will($this->returnCallback(function($filter, $base) {
- if($base === 'uid=alice') {
+ if($base === array('uid=alice')) {
return array(
array(
'pwdchangedtime' => array((new \DateTime())->sub(new \DateInterval('P28D'))->format('Ymdhis').'Z'),
@@ -1140,7 +1140,7 @@ class UserTest extends \Test\TestCase {
),
);
}
- if($base === 'cn=default,ou=policies,dc=foo,dc=bar') {
+ if($base === array('cn=default,ou=policies,dc=foo,dc=bar')) {
return array(
array(
'pwdmaxage' => array('2592000'),
@@ -1202,7 +1202,7 @@ class UserTest extends \Test\TestCase {
$this->access->expects($this->any())
->method('search')
->will($this->returnCallback(function($filter, $base) {
- if($base === 'uid=alice') {
+ if($base === array('uid=alice')) {
return array(
array(
'pwdpolicysubentry' => array('cn=custom,ou=policies,dc=foo,dc=bar'),
@@ -1211,7 +1211,7 @@ class UserTest extends \Test\TestCase {
)
);
}
- if($base === 'cn=custom,ou=policies,dc=foo,dc=bar') {
+ if($base === array('cn=custom,ou=policies,dc=foo,dc=bar')) {
return array(
array(
'pwdmaxage' => array('2592000'),