We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent fa388b6 commit 5cb4b74Copy full SHA for 5cb4b74
composer.json
@@ -13,7 +13,7 @@
13
"php": "^7.4 || ^8.0",
14
"elastic/transport": "^8.7",
15
"psr/http-client": "^1.0",
16
- "psr/http-message": "^1.0 || ^2.0",
+ "psr/http-message": "^1.1 || ^2.0",
17
"psr/log": "^1|^2|^3",
18
"guzzlehttp/guzzle": "^7.0"
19
},
tests/Response/ElasticsearchTest.php
@@ -200,4 +200,12 @@ public function testAccessAsObject()
200
201
$this->assertEquals($array['foo'], $this->elasticsearch->foo);
202
}
203
+
204
+ public function testWithStatusForPsr7Version1And2Compatibility()
205
+ {
206
+ $this->elasticsearch->setResponse($this->response200);
207
208
+ $this->elasticsearch = $this->elasticsearch->withStatus(400);
209
+ $this->assertEquals(400, $this->elasticsearch->getStatusCode());
210
+ }
211
0 commit comments