You are here

protected function FeedsItemFormatterTestBase::assertFeedsItemFieldNotDisplayed in Feeds 8.3

Asserts that the feeds_item field is not displayed.

Potentially the Stark theme can output a feeds_item field as follows:


<div>
  <div>Feeds item</div>
  <div>05/11/2020 - 15:19</div>
</div>

Parameters

string $rendered_content: The rendered content.

string $input: A property value from the feeds_item field.

3 calls to FeedsItemFormatterTestBase::assertFeedsItemFieldNotDisplayed()
FeedsItemGuidFormatterTest::testFeedsItemGuidFormatter in tests/src/Functional/Plugin/Field/FieldFormatter/FeedsItemGuidFormatterTest.php
Test the feeds item guid formatter.
FeedsItemTargetIdFormatterTest::testFeedsItemTargetIdFormatter in tests/src/Functional/Plugin/Field/FieldFormatter/FeedsItemTargetIdFormatterTest.php
Tests the feeds target id formatter.
FeedsItemUrlFormatterTest::testFeedsItemUrlFormatter in tests/src/Functional/Plugin/Field/FieldFormatter/FeedsItemUrlFormatterTest.php
Test the feeds item url formatter.

File

tests/src/Functional/Plugin/Field/FieldFormatter/FeedsItemFormatterTestBase.php, line 82

Class

FeedsItemFormatterTestBase
Base class for the feeds item field formatter tests.

Namespace

Drupal\Tests\feeds\Functional\Plugin\Field\FieldFormatter

Code

protected function assertFeedsItemFieldNotDisplayed($rendered_content, $input) {
  $this
    ->assertStringNotContainsString('<div>Feeds item</div>', (string) $rendered_content);
  $this
    ->assertStringNotContainsString('<div>' . $input . '</div>', (string) $rendered_content);
}