You are here

public function PluginTestBase::testStringExpression in Purge 8.3

Test if typecasting invalidation objects to strings gets us a string.

See also

\Drupal\purge\Plugin\Purge\Invalidation\InvalidationInterface::__toString

File

tests/src/Kernel/Invalidation/PluginTestBase.php, line 392

Class

PluginTestBase
Provides an abstract test class to thoroughly test invalidation types.

Namespace

Drupal\Tests\purge\Kernel\Invalidation

Code

public function testStringExpression() : void {
  $this
    ->assertEquals((string) $this
    ->getInstance(), $this->expressions[0], 'The __toString method returns $expression.');
}