You are here

public function MinkTest::testSetDefaultSessionName in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 vendor/behat/mink/tests/MinkTest.php \Behat\Mink\Tests\MinkTest::testSetDefaultSessionName()

File

vendor/behat/mink/tests/MinkTest.php, line 102

Class

MinkTest

Namespace

Behat\Mink\Tests

Code

public function testSetDefaultSessionName() {
  $this
    ->assertNull($this->mink
    ->getDefaultSessionName());
  $session = $this
    ->getSessionMock();
  $this->mink
    ->registerSession('session_name', $session);
  $this->mink
    ->setDefaultSessionName('session_name');
  $this
    ->assertEquals('session_name', $this->mink
    ->getDefaultSessionName());
  $this
    ->setExpectedException('InvalidArgumentException');
  $this->mink
    ->setDefaultSessionName('not_registered');
}