You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

24 lines
561 B

12 months ago
<?php
namespace OSS\Tests;
use OSS\Result\HeaderResult;
use OSS\Http\ResponseCore;
/**
* Class HeaderResultTest
* @package OSS\Tests
*/
class HeaderResultTest extends \PHPUnit_Framework_TestCase
{
public function testGetHeader()
{
$response = new ResponseCore(array('key' => 'value'), "", 200);
$result = new HeaderResult($response);
$this->assertTrue($result->isOK());
$this->assertTrue(is_array($result->getData()));
$data = $result->getData();
$this->assertEquals($data['key'], 'value');
}
}