protected function ParagraphsTestBase::removeDefaultParagraphType in Paragraphs 8
Same name in this branch
- 8 tests/src/Functional/WidgetLegacy/ParagraphsTestBase.php \Drupal\Tests\paragraphs\Functional\WidgetLegacy\ParagraphsTestBase::removeDefaultParagraphType()
- 8 tests/src/Functional/WidgetStable/ParagraphsTestBase.php \Drupal\Tests\paragraphs\Functional\WidgetStable\ParagraphsTestBase::removeDefaultParagraphType()
Removes the default paragraph type.
Parameters
$content_type: Content type name that contains the paragraphs field.
1 call to ParagraphsTestBase::removeDefaultParagraphType()
- ParagraphsAddModesTest::testSettingDefaultParagraphType in tests/
src/ Functional/ WidgetLegacy/ ParagraphsAddModesTest.php - Tests if setting for default paragraph type is working properly.
1 method overrides ParagraphsTestBase::removeDefaultParagraphType()
- ParagraphsTestBase::removeDefaultParagraphType in tests/
src/ Functional/ WidgetStable/ ParagraphsTestBase.php - Removes the default paragraph type.
File
- tests/
src/ Functional/ WidgetLegacy/ ParagraphsTestBase.php, line 182
Class
- ParagraphsTestBase
- Base class for tests.
Namespace
Drupal\Tests\paragraphs\Functional\WidgetLegacyCode
protected function removeDefaultParagraphType($content_type) {
$this
->drupalGet('node/add/' . $content_type);
$this
->submitForm([], 'Remove');
$this
->submitForm([], 'Confirm removal');
$this
->assertSession()
->pageTextNotContains('No paragraphs added yet.');
}