public function ParagraphsFieldSettingsTest::testNonParagraphFieldSettings

Test leaving target_type empty for non-paragraphs fields.

File

paragraphs/tests/src/Unit/migrate/ParagraphsFieldSettingsTest.php, line 40

Class

ParagraphsFieldSettingsTest
Test the ParagraphFieldSettings Process Plugin.

Namespace

Drupal\Tests\paragraphs\Unit\migrate

Code

public function testNonParagraphFieldSettings() {
  $this->row
    ->expects($this
    ->any())
    ->method('getSourceProperty')
    ->with('type')
    ->willReturn('something_else');
  $value = $this->plugin
    ->transform([], $this->migrateExecutable, $this->row, 'settings');
  $this
    ->assertEmpty($value);
}