summaryrefslogtreecommitdiffstats
path: root/tests/lib/AppFramework/Http/ResponseTest.php
diff options
context:
space:
mode:
authorLukas Reschke <lukas@statuscode.ch>2017-07-27 14:14:20 +0200
committerLukas Reschke <lukas@statuscode.ch>2017-07-27 14:17:45 +0200
commitf22ab3e665124e79427f51049fea0f937b66cdbb (patch)
treea2f4b3260853d0252b76d3ce452512a3f6a47ee6 /tests/lib/AppFramework/Http/ResponseTest.php
parent63aa12e38c2e819b54c4b9e9632264a0e59dc6f2 (diff)
downloadnextcloud-server-f22ab3e665124e79427f51049fea0f937b66cdbb.tar.gz
nextcloud-server-f22ab3e665124e79427f51049fea0f937b66cdbb.zip
Add metadata to \OCP\AppFramework\Http\Response::throttle
Fixes https://github.com/nextcloud/server/issues/5891 Signed-off-by: Lukas Reschke <lukas@statuscode.ch>
Diffstat (limited to 'tests/lib/AppFramework/Http/ResponseTest.php')
-rw-r--r--tests/lib/AppFramework/Http/ResponseTest.php5
1 files changed, 5 insertions, 0 deletions
diff --git a/tests/lib/AppFramework/Http/ResponseTest.php b/tests/lib/AppFramework/Http/ResponseTest.php
index d8959face89..9267d862600 100644
--- a/tests/lib/AppFramework/Http/ResponseTest.php
+++ b/tests/lib/AppFramework/Http/ResponseTest.php
@@ -269,4 +269,9 @@ class ResponseTest extends \Test\TestCase {
$this->childResponse->throttle();
$this->assertTrue($this->childResponse->isThrottled());
}
+
+ public function testGetThrottleMetadata() {
+ $this->childResponse->throttle(['foo' => 'bar']);
+ $this->assertSame(['foo' => 'bar'], $this->childResponse->getThrottleMetadata());
+ }
}