diff options
author | Morris Jobke <hey@morrisjobke.de> | 2018-01-17 15:21:56 +0100 |
---|---|---|
committer | Morris Jobke <hey@morrisjobke.de> | 2018-01-23 10:57:21 +0100 |
commit | 2a38605545e26ce68a37e5ebb877fd9c9875a37d (patch) | |
tree | a149433f3fdeae3b4615061b495e4c523328a9a6 /apps/federation/tests/Middleware/AddServerMiddlewareTest.php | |
parent | 520f2fd6ea3661d5d49517c7265dd8d7515036ac (diff) | |
download | nextcloud-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 'apps/federation/tests/Middleware/AddServerMiddlewareTest.php')
-rw-r--r-- | apps/federation/tests/Middleware/AddServerMiddlewareTest.php | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/apps/federation/tests/Middleware/AddServerMiddlewareTest.php b/apps/federation/tests/Middleware/AddServerMiddlewareTest.php index 4620234d685..7bae5e566fc 100644 --- a/apps/federation/tests/Middleware/AddServerMiddlewareTest.php +++ b/apps/federation/tests/Middleware/AddServerMiddlewareTest.php @@ -68,13 +68,11 @@ class AddServerMiddlewareTest extends TestCase { * @dataProvider dataTestAfterException * * @param \Exception $exception - * @param string $message * @param string $hint */ - public function testAfterException($exception, $message, $hint) { + public function testAfterException($exception, $hint) { - $this->logger->expects($this->once())->method('error') - ->with($message, ['app' => 'AddServerMiddlewareTest']); + $this->logger->expects($this->once())->method('logException'); $this->l10n->expects($this->any())->method('t') ->willReturnCallback( @@ -98,8 +96,8 @@ class AddServerMiddlewareTest extends TestCase { public function dataTestAfterException() { return [ - [new HintException('message', 'hint'), 'message', 'hint'], - [new \Exception('message'), 'message', 'message'], + [new HintException('message', 'hint'), 'hint'], + [new \Exception('message'), 'message'], ]; } |