You are here

public function SessionHandlerProxyTest::testOpen in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 vendor/symfony/http-foundation/Tests/Session/Storage/Proxy/SessionHandlerProxyTest.php \Symfony\Component\HttpFoundation\Tests\Session\Storage\Proxy\SessionHandlerProxyTest::testOpen()

File

vendor/symfony/http-foundation/Tests/Session/Storage/Proxy/SessionHandlerProxyTest.php, line 48

Class

SessionHandlerProxyTest
Tests for SessionHandlerProxy class.

Namespace

Symfony\Component\HttpFoundation\Tests\Session\Storage\Proxy

Code

public function testOpen() {
  $this->mock
    ->expects($this
    ->once())
    ->method('open')
    ->will($this
    ->returnValue(true));
  $this
    ->assertFalse($this->proxy
    ->isActive());
  $this->proxy
    ->open('name', 'id');
  if (PHP_VERSION_ID < 50400) {
    $this
      ->assertTrue($this->proxy
      ->isActive());
  }
  else {
    $this
      ->assertFalse($this->proxy
      ->isActive());
  }
}