You are here

public function CachingStreamTest::testRewindUsesSeek in Zircon Profile 8.0

Same name and namespace in other branches
  1. 8 vendor/guzzlehttp/psr7/tests/CachingStreamTest.php \GuzzleHttp\Tests\Psr7\CachingStreamTest::testRewindUsesSeek()

File

vendor/guzzlehttp/psr7/tests/CachingStreamTest.php, line 74

Class

CachingStreamTest
@covers GuzzleHttp\Psr7\CachingStream

Namespace

GuzzleHttp\Tests\Psr7

Code

public function testRewindUsesSeek() {
  $a = Psr7\stream_for('foo');
  $d = $this
    ->getMockBuilder('GuzzleHttp\\Psr7\\CachingStream')
    ->setMethods(array(
    'seek',
  ))
    ->setConstructorArgs(array(
    $a,
  ))
    ->getMock();
  $d
    ->expects($this
    ->once())
    ->method('seek')
    ->with(0)
    ->will($this
    ->returnValue(true));
  $d
    ->seek(0);
}