From 76a7600e2e8ee239c2f7dd19e8b3d1e86f7c5362 Mon Sep 17 00:00:00 2001 From: Roeland Jago Douma Date: Fri, 18 Sep 2020 12:34:43 +0200 Subject: Allow configuring the activity update interval of token On some systems with a lot of users this creates a lot of extra DB writes. Being able to increase this interval helps there. Signed-off-by: Roeland Jago Douma --- tests/lib/Authentication/Token/PublicKeyTokenProviderTest.php | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'tests/lib') diff --git a/tests/lib/Authentication/Token/PublicKeyTokenProviderTest.php b/tests/lib/Authentication/Token/PublicKeyTokenProviderTest.php index c16ee7b818e..a815025a509 100644 --- a/tests/lib/Authentication/Token/PublicKeyTokenProviderTest.php +++ b/tests/lib/Authentication/Token/PublicKeyTokenProviderTest.php @@ -112,6 +112,12 @@ class PublicKeyTokenProviderTest extends TestCase { public function testUpdateTokenDebounce() { $tk = new PublicKeyToken(); + + $this->config->method('getSystemValueInt') + ->willReturnCallback(function ($value, $default) { + return $default; + }); + $tk->setLastActivity($this->time - 30); $this->mapper->expects($this->never()) ->method('update') -- cgit v1.2.3