Skip to content

Commit dfc7007

Browse files
committed
with LDAP server set offline, config cannot be controlled via ocs anymore
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
1 parent 5dd2207 commit dfc7007

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

build/integration/features/bootstrap/LDAPContext.php

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@
2727

2828
class LDAPContext implements Context {
2929
use BasicStructure;
30+
use CommandLine;
3031

3132
protected $configID;
3233

@@ -37,6 +38,8 @@ public function teardown() {
3738
if($this->configID === null) {
3839
return;
3940
}
41+
$this->disableLDAPConfiguration(); # via occ in case of big config issues
42+
$this->asAn('admin');
4043
$this->sendingTo('DELETE', $this->apiUrl . '/' . $this->configID);
4144
}
4245

@@ -196,4 +199,9 @@ public function theRecordFieldsShouldMatch(TableNode $expectations) {
196199
$backend = (string)simplexml_load_string($this->response->getBody())->data[0]->backend;
197200
Assert::assertEquals('LDAP', $backend);
198201
}
202+
203+
public function disableLDAPConfiguration() {
204+
$configKey = $this->configID . 'ldap_configuration_active';
205+
$this->invokingTheCommand('config:app:set user_ldap ' . $configKey . ' --value="0"');
206+
}
199207
}

0 commit comments

Comments
 (0)