You are here

public function FunctionsTest::testReturnsCustomMetadata in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 vendor/guzzlehttp/psr7/tests/FunctionsTest.php \GuzzleHttp\Tests\Psr7\FunctionsTest::testReturnsCustomMetadata()

File

vendor/guzzlehttp/psr7/tests/FunctionsTest.php, line 402

Class

FunctionsTest

Namespace

GuzzleHttp\Tests\Psr7

Code

public function testReturnsCustomMetadata() {
  $s = Psr7\stream_for('foo', [
    'metadata' => [
      'hwm' => 3,
    ],
  ]);
  $this
    ->assertEquals(3, $s
    ->getMetadata('hwm'));
  $this
    ->assertArrayHasKey('hwm', $s
    ->getMetadata());
}