public function ParagraphsSetsFunctionalTestTrait::addTextFieldInParagraphType in Paragraphs Sets 8.2
Create a text field in a given paragraph bundle.
Parameters
string $textFieldName: The machine name for the text field.
string $paragraphType: The machine name for the paragraph type.
1 call to ParagraphsSetsFunctionalTestTrait::addTextFieldInParagraphType()
- ParagraphSetBasicFunctionality::setUp in tests/
src/ Functional/ ParagraphSetBasicFunctionality.php
File
- tests/
src/ Traits/ ParagraphsSetsFunctionalTestTrait.php, line 52
Class
- ParagraphsSetsFunctionalTestTrait
- Contains functions common to functional paragraphs sets tests.
Namespace
Drupal\Tests\paragraphs_sets\TraitsCode
public function addTextFieldInParagraphType(string $textFieldName, string $paragraphType) {
$this
->addFieldtoParagraphType($paragraphType, $textFieldName, 'string', []);
}