You are here

public function WebAssertTest::testResponseHeaderNotMatches in Zircon Profile 8

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

File

vendor/behat/mink/tests/WebAssertTest.php, line 308

Class

WebAssertTest

Namespace

Behat\Mink\Tests

Code

public function testResponseHeaderNotMatches() {
  $this->session
    ->expects($this
    ->any())
    ->method('getResponseHeader')
    ->will($this
    ->returnValueMap(array(
    array(
      'foo',
      'bar',
    ),
    array(
      'bar',
      'baz',
    ),
  )));
  $this
    ->assertCorrectAssertion('responseHeaderNotMatches', array(
    'foo',
    '/bz/',
  ));
  $this
    ->assertWrongAssertion('responseHeaderNotMatches', array(
    'bar',
    '/b[ab]z/',
  ), 'Behat\\Mink\\Exception\\ExpectationException', 'The pattern "/b[ab]z/" was found in the text of the "bar" response header, but it should not.');
}