mirror of
https://github.com/yiisoft/yii2.git
synced 2025-11-01 11:39:41 +08:00
* Fixed HeaderCollection::fromArray() key case * Added CHANGELOG.md line for #18883 (Fixed HeaderCollection::fromArray() key case)
28 lines
615 B
PHP
28 lines
615 B
PHP
<?php
|
|
/**
|
|
* @link http://www.yiiframework.com/
|
|
* @copyright Copyright (c) 2008 Yii Software LLC
|
|
* @license http://www.yiiframework.com/license/
|
|
*/
|
|
|
|
namespace yiiunit\framework\web;
|
|
|
|
use yii\web\HeaderCollection;
|
|
use yiiunit\TestCase;
|
|
|
|
/**
|
|
* @group web
|
|
*/
|
|
class HeaderCollectionTest extends TestCase
|
|
{
|
|
public function testFromArray()
|
|
{
|
|
$headerCollection = new HeaderCollection();
|
|
$location = 'my-test-location';
|
|
$headerCollection->fromArray([
|
|
'Location' => [$location],
|
|
]);
|
|
$this->assertEquals($location, $headerCollection->get('Location'));
|
|
}
|
|
}
|