diff options
author | Joas Schilling <coding@schilljs.com> | 2019-02-22 08:27:22 +0100 |
---|---|---|
committer | Joas Schilling <coding@schilljs.com> | 2019-02-22 09:08:53 +0100 |
commit | b4902369fbbbdddd80ef5043bfb3e9dbd9bf1732 (patch) | |
tree | 08ae47a740923cec2d0e2616fee4f405aabdd440 | |
parent | 0c77cd21f94dd9922e0e04ec4c7e99eff9376e07 (diff) | |
download | nextcloud-server-b4902369fbbbdddd80ef5043bfb3e9dbd9bf1732.tar.gz nextcloud-server-b4902369fbbbdddd80ef5043bfb3e9dbd9bf1732.zip |
Fix unit tests
Signed-off-by: Joas Schilling <coding@schilljs.com>
-rw-r--r-- | apps/dav/tests/unit/Connector/Sabre/MaintenancePluginTest.php | 3 | ||||
-rw-r--r-- | tests/Core/Command/Encryption/EncryptAllTest.php | 2 | ||||
-rw-r--r-- | tests/Core/Command/Maintenance/ModeTest.php | 2 |
3 files changed, 4 insertions, 3 deletions
diff --git a/apps/dav/tests/unit/Connector/Sabre/MaintenancePluginTest.php b/apps/dav/tests/unit/Connector/Sabre/MaintenancePluginTest.php index d4cc00f1582..5a1a4619ead 100644 --- a/apps/dav/tests/unit/Connector/Sabre/MaintenancePluginTest.php +++ b/apps/dav/tests/unit/Connector/Sabre/MaintenancePluginTest.php @@ -53,7 +53,8 @@ class MaintenancePluginTest extends TestCase { public function testMaintenanceMode() { $this->config ->expects($this->exactly(1)) - ->method('getSystemValue') + ->method('getSystemValueBool') + ->with('maintenance') ->will($this->returnValue(true)); $this->maintenancePlugin->checkMaintenanceMode(); diff --git a/tests/Core/Command/Encryption/EncryptAllTest.php b/tests/Core/Command/Encryption/EncryptAllTest.php index ca7b264c98f..c6af7e38722 100644 --- a/tests/Core/Command/Encryption/EncryptAllTest.php +++ b/tests/Core/Command/Encryption/EncryptAllTest.php @@ -91,7 +91,7 @@ class EncryptAllTest extends TestCase { $this->appManager->expects($this->once())->method('disableApp')->with('files_trashbin'); // enable single user mode to avoid that other user login during encryption // destructor should disable the single user mode again - $this->config->expects($this->once())->method('getSystemValue')->with('maintenance', false)->willReturn(false); + $this->config->expects($this->once())->method('getSystemValueBool')->with('maintenance', false)->willReturn(false); $this->config->expects($this->at(1))->method('setSystemValue')->with('maintenance', true); $this->config->expects($this->at(2))->method('setSystemValue')->with('maintenance', false); diff --git a/tests/Core/Command/Maintenance/ModeTest.php b/tests/Core/Command/Maintenance/ModeTest.php index da5e95998e9..895a06bbec1 100644 --- a/tests/Core/Command/Maintenance/ModeTest.php +++ b/tests/Core/Command/Maintenance/ModeTest.php @@ -123,7 +123,7 @@ class ModeTest extends TestCase { string $expectedOutput ) { $this->config->expects($this->any()) - ->method('getSystemValue') + ->method('getSystemValueBool') ->willReturn($currentMaintenanceState); if ($expectedMaintenanceState !== null) { |