Behat\Gherkin\Keywords\KeywordsDumper::dumpBackground PHP Method

dumpBackground() protected method

Dumps background example.
protected dumpBackground ( string $keyword, boolean $short = true, $excludeAsterisk = false ) : string
$keyword string Item keyword
$short boolean Dump short version?
return string
    protected function dumpBackground($keyword, $short = true, $excludeAsterisk = false)
    {
        $dump = <<<GHERKIN
  {$keyword}:

GHERKIN;
        // Given
        $dump .= $this->dumpStep($this->keywords->getGivenKeywords(), 'there is agent A', $short, $excludeAsterisk);
        // And
        $dump .= $this->dumpStep($this->keywords->getAndKeywords(), 'there is agent B', $short, $excludeAsterisk);
        return $dump . "\n";
    }