From 891c10d09da333e6af172bacd0c28540fd7a7032 Mon Sep 17 00:00:00 2001 From: Arthur Schiwon Date: Thu, 16 Jun 2022 13:30:52 +0200 Subject: fix overwriting original vars when logging Signed-off-by: Arthur Schiwon --- tests/lib/Log/ExceptionSerializerTest.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'tests/lib') diff --git a/tests/lib/Log/ExceptionSerializerTest.php b/tests/lib/Log/ExceptionSerializerTest.php index 1b7bfee2c87..f8cc6b77ee6 100644 --- a/tests/lib/Log/ExceptionSerializerTest.php +++ b/tests/lib/Log/ExceptionSerializerTest.php @@ -60,8 +60,9 @@ class ExceptionSerializerTest extends TestCase { $secret = ['Secret']; $this->emit([&$secret]); } catch (\Exception $e) { - $this->serializer->serializeException($e); + $serializedData = $this->serializer->serializeException($e); $this->assertSame(['Secret'], $secret); + $this->assertSame('*** sensitive parameters replaced ***', $serializedData['Trace'][0]['args'][0]); } } } -- cgit v1.2.3