Skip to content

Commit

Permalink
OP-326: Behat - deleting content element
Browse files Browse the repository at this point in the history
  • Loading branch information
jkindly committed Jul 10, 2024
1 parent d5f795c commit f14c55a
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 6 deletions.
4 changes: 2 additions & 2 deletions features/admin/managing_blocks.feature
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ Feature: Managing cms blocks

@ui
Scenario: Updating block textarea content element
Given there is a block with "store_phone_number" code and "textarea" content element
Given there is a block with "store_phone_number" code and "Textarea" content element
When I go to the update "store_phone_number" block page
And I fill the name with "Store phone number" if the name field is empty
And I change textarea content element value to "New content"
Expand All @@ -36,7 +36,7 @@ Feature: Managing cms blocks

@ui @javascript
Scenario: Deleting content element in block
Given there is a block with "store_phone_number" code and "textarea" content element
Given there is a block with "store_phone_number" code and "Textarea" content element
When I go to the update "store_phone_number" block page
And I delete the content element
And I update it
Expand Down
4 changes: 2 additions & 2 deletions features/admin/managing_pages.feature
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ Feature: Managing cms pages

@ui
Scenario: Updating page with textarea content element
Given there is a page in the store with "textarea" content element
Given there is a page in the store with "Textarea" content element
When I want to edit this page
And I fill "Code, Name" fields
And I change textarea content element value to "New content"
Expand All @@ -42,7 +42,7 @@ Feature: Managing cms pages

@ui @javascript
Scenario: Deleting content element in page
Given there is a page in the store with "textarea" content element
Given there is a page in the store with "Textarea" content element
When I want to edit this page
And I delete the content element
And I update it
Expand Down
2 changes: 1 addition & 1 deletion tests/Behat/Context/Setup/BlockContext.php
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ private function createBlockWithContentElement(string $code, string $contentElem
$block = $this->createBlock($code);

$contentConfiguration = new ContentConfiguration();
$contentConfiguration->setType($contentElement);
$contentConfiguration->setType(mb_strtolower($contentElement));
$contentConfiguration->setConfiguration(ContentElementHelper::getExampleConfigurationByContentElement($contentElement));
$contentConfiguration->setBlock($block);

Expand Down
2 changes: 1 addition & 1 deletion tests/Behat/Context/Setup/PageContext.php
Original file line number Diff line number Diff line change
Expand Up @@ -210,7 +210,7 @@ private function createPageWithContentElement(string $contentElement): PageInter

/** @var ContentConfigurationInterface $contentConfiguration */
$contentConfiguration = new ContentConfiguration();
$contentConfiguration->setType($contentElement);
$contentConfiguration->setType(mb_strtolower($contentElement));
$contentConfiguration->setConfiguration(ContentElementHelper::getExampleConfigurationByContentElement($contentElement));
$contentConfiguration->setPage($page);

Expand Down

0 comments on commit f14c55a

Please sign in to comment.