summaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorMorris Jobke <hey@morrisjobke.de>2018-01-17 15:21:56 +0100
committerMorris Jobke <hey@morrisjobke.de>2018-01-23 10:57:21 +0100
commit2a38605545e26ce68a37e5ebb877fd9c9875a37d (patch)
treea149433f3fdeae3b4615061b495e4c523328a9a6 /tests
parent520f2fd6ea3661d5d49517c7265dd8d7515036ac (diff)
downloadnextcloud-server-2a38605545e26ce68a37e5ebb877fd9c9875a37d.tar.gz
nextcloud-server-2a38605545e26ce68a37e5ebb877fd9c9875a37d.zip
Properly log the full exception instead of only the message
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
Diffstat (limited to 'tests')
-rw-r--r--tests/lib/AppFramework/Middleware/Security/SecurityMiddlewareTest.php6
-rw-r--r--tests/lib/CapabilitiesManagerTest.php2
2 files changed, 3 insertions, 5 deletions
diff --git a/tests/lib/AppFramework/Middleware/Security/SecurityMiddlewareTest.php b/tests/lib/AppFramework/Middleware/Security/SecurityMiddlewareTest.php
index 151d6935e7f..0d7418673dd 100644
--- a/tests/lib/AppFramework/Middleware/Security/SecurityMiddlewareTest.php
+++ b/tests/lib/AppFramework/Middleware/Security/SecurityMiddlewareTest.php
@@ -483,8 +483,7 @@ class SecurityMiddlewareTest extends \Test\TestCase {
->will($this->returnValue('http://localhost/nextcloud/index.php/login?redirect_url=nextcloud/index.php/apps/specialapp'));
$this->logger
->expects($this->once())
- ->method('debug')
- ->with('Current user is not logged in');
+ ->method('logException');
$response = $this->middleware->afterException(
$this->controller,
'test',
@@ -554,8 +553,7 @@ class SecurityMiddlewareTest extends \Test\TestCase {
$this->middleware = $this->getMiddleware(false, false);
$this->logger
->expects($this->once())
- ->method('debug')
- ->with($exception->getMessage());
+ ->method('logException');
$response = $this->middleware->afterException(
$this->controller,
'test',
diff --git a/tests/lib/CapabilitiesManagerTest.php b/tests/lib/CapabilitiesManagerTest.php
index 8df385e6ef9..c967b77130d 100644
--- a/tests/lib/CapabilitiesManagerTest.php
+++ b/tests/lib/CapabilitiesManagerTest.php
@@ -148,7 +148,7 @@ class CapabilitiesManagerTest extends TestCase {
});
$this->logger->expects($this->once())
- ->method('error');
+ ->method('logException');
$res = $this->manager->getCapabilities();