public function testBackground() { $style = new OutputFormatterStyle(); $style->setBackground('black'); $this->assertEquals("[40m", $style->getBeginStyle()); $this->assertEquals("[0m", $style->getEndStyle()); $style->setBackground('yellow'); $this->assertEquals("[43m", $style->getBeginStyle()); $this->setExpectedException('InvalidArgumentException'); $style->setBackground('undefined-color'); }