MCPcopy Create free account
hub / github.com/apache/thrift / testRead

Method testRead

lib/php/test/Unit/Lib/Transport/TCurlClientTest.php:80–95  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

78 }
79
80 public function testRead()
81 {
82 $host = 'localhost';
83 $transport = new TCurlClient($host);
84
85 $this->setPropertyValue($transport, 'response_', '1234567890');
86
87 $response = $transport->read(5);
88 $this->assertEquals('12345', $response);
89 $this->assertEquals('67890', $this->getPropertyValue($transport, 'response_'));
90
91 $response = $transport->read(5);
92 $this->assertEquals('67890', $response);
93 # The response does not cleaned after reading full answer, maybe it should be fixed
94 $this->assertEquals('67890', $this->getPropertyValue($transport, 'response_'));
95 }
96
97 public function testReadAll()
98 {

Callers

nothing calls this directly

Calls 3

setPropertyValueMethod · 0.80
getPropertyValueMethod · 0.80
readMethod · 0.65

Tested by

no test coverage detected