function ColorLegacyTest::testColorSystemBrandingBlockAlterPreRender
Tests color_block_view_pre_render() deprecation.
@expectedDeprecation color_block_view_pre_render() is deprecated in Drupal 8.8.0 and will be removed before Drupal 9.0.0. Use \Drupal\color\ColorSystemBrandingBlockAlter::preRender() instead. See https://www.drupal.org/node/2966725
File
- 
              core/
modules/ color/ tests/ src/ Kernel/ ColorLegacyTest.php, line 37  
Class
- ColorLegacyTest
 - Tests Color module's legacy code.
 
Namespace
Drupal\Tests\color\KernelCode
public function testColorSystemBrandingBlockAlterPreRender() {
  $render = color_block_view_pre_render([]);
  $this->assertEquals([
    'config:color.theme.bartik',
  ], $render['#cache']['tags']);
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.