addStyle() public method

Adds a style to the style set.
See also: StyleSet::add()
public addStyle ( Style $style ) : static
$style Webmozart\Console\Api\Formatter\Style The style to add.
return static The current instance.
Exemplo n.º 1
0
 public function testAddStyle()
 {
     $style = Style::tag('custom');
     $this->config->addStyle($style);
     $styleSet = new DefaultStyleSet();
     $styleSet->add($style);
     $this->assertEquals($styleSet, $this->config->getStyleSet());
 }