original_string: public function theServerShouldReturnHeaders(TableNode $headers)
      {
          Assertions::assertNotNull($this->response, 'Missing response. Can you not send request?');
          $responseHeaders = [];
  
          foreach ($this->response->getHeaders() as $name => $value) {
              $responseHeaders[strtolower($name)] = $value;
          }
  
          foreach ($headers->getRowsHash() as $headerName => $headerValue) {
              $headerName = strtolower($headerName);
  
              Assertions::assertArrayHasKey($headerName, $responseHeaders, 'Missing header in response.');
  
              $responseHeader = $responseHeaders[$headerName];
              $responseHeader = implode('; ', $responseHeader);
  
              Assertions::assertEquals($headerValue, $responseHeader, 'The header is not equals.');
          }
      }
code: public function theServerShouldReturnHeaders(TableNode $headers)
      {
          Assertions::assertNotNull($this->response, 'Missing response. Can you not send request?');
          $responseHeaders = [];
  
          foreach ($this->response->getHeaders() as $name => $value) {
              $responseHeaders[strtolower($name)] = $value;
          }
  
          foreach ($headers->getRowsHash() as $headerName => $headerValue) {
              $headerName = strtolower($headerName);
  
              Assertions::assertArrayHasKey($headerName, $responseHeaders, 'Missing header in response.');
  
              $responseHeader = $responseHeaders[$headerName];
              $responseHeader = implode('; ', $responseHeader);
  
              Assertions::assertEquals($headerValue, $responseHeader, 'The header is not equals.');
          }
      }
code_tokens: public function theServerShouldReturnHeaders ( TableNode $ headers ) { Assertions :: assertNotNull ( $ this -> response , 'Missing response. Can you not send request?' ) ; $ responseHeaders = [ ] ; foreach ( $ this -> response -> getHeaders ( ) as $ name => $ value ) { $ responseHeaders [ strtolower ( $ name ) ] = $ value ; } foreach ( $ headers -> getRowsHash ( ) as $ headerName => $ headerValue ) { $ headerName = strtolower ( $ headerName ) ; Assertions :: assertArrayHasKey ( $ headerName , $ responseHeaders , 'Missing header in response.' ) ; $ responseHeader = $ responseHeaders [ $ headerName ] ; $ responseHeader = implode ( '; ' , $ responseHeader ) ; Assertions :: assertEquals ( $ headerValue , $ responseHeader , 'The header is not equals.' ) ; } }
docstring: The server should return headers
  
  @param TableNode $headers
  
  @Then /^(?:the )?server should return headers:$/
docstring_tokens: The server should return headers