function ImageTest::testInvalidGetKeywordOffset

@legacy-covers ::getKeywordOffset

File

core/tests/Drupal/Tests/Component/Utility/ImageTest.php, line 166

Class

ImageTest
Tests Drupal\Component\Utility\Image.

Namespace

Drupal\Tests\Component\Utility

Code

public function testInvalidGetKeywordOffset() : void {
  $this->expectException(\InvalidArgumentException::class);
  $this->expectExceptionMessage('Invalid anchor \'foo\' provided to getKeywordOffset()');
  Image::getKeywordOffset('foo', 0, 0);
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.