Skip to content

Commit

Permalink
added behat test
Browse files Browse the repository at this point in the history
  • Loading branch information
yeniatencio committed Dec 18, 2024
1 parent 70d380c commit 9b1f2ce
Showing 1 changed file with 49 additions and 0 deletions.
49 changes: 49 additions & 0 deletions modules/tide_landing_page/tests/behat/features/fields.feature
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,8 @@ Feature: Fields for Landing Page content type
And the "#edit-field-bottom-graphical-image" element should contain "Bottom Corner Graphic"
And I should see an "input#edit-field-bottom-graphical-image-entity-browser-target" element

And I should see a "select#edit-field-landing-page-hero-theme" element

And I click on the horizontal tab "Header extras"
And I should see text matching "Header components"
And I press the "edit-field-landing-page-header-add-more-add-modal-form-area-add-more" button
Expand Down Expand Up @@ -164,6 +166,8 @@ Feature: Fields for Landing Page content type
And the "#edit-field-bottom-graphical-image" element should contain "Bottom Corner Graphic"
And I should see an "input#edit-field-bottom-graphical-image-entity-browser-target" element

And I should see a "select#edit-field-landing-page-hero-theme" element

And I click on the horizontal tab "Header extras"
And I should see text matching "Header components"
And I press the "edit-field-landing-page-header-add-more-add-modal-form-area-add-more" button
Expand Down Expand Up @@ -300,3 +304,48 @@ Feature: Fields for Landing Page content type
# This field can be "seen" but not visible.
And I see field "field_landing_page_component[0][subform][field_customise][value]"
And save screenshot


@api @javascript
Scenario: Selecting Corner graphics value from header style.
Given I am logged in as a user with the "editor" role
When I visit "node/add/landing_page"
And I click on the horizontal tab "Customised Header"
Then I should see an "#edit-header-style-options-corner" element
And I select "corner" from "edit-header-style-options-corner"
Then I should see an "#edit-field-landing-page-hero-theme" element
And I should see text matching "Default"
And save screenshot

@api @javascript
Scenario: Selecting Default appearance value from header style.
Given I am logged in as a user with the "editor" role
When I visit "node/add/landing_page"
And I click on the horizontal tab "Customised Header"
Then I should see an "#edit-header-style-options-default" element
And I select "corner" from "edit-header-style-options-default"
Then I should see an "#edit-field-landing-page-hero-theme" element
And I should see text matching "Default"
And save screenshot

@api @javascript
Scenario: Selecting Full-width background image value from header style.
Given I am logged in as a user with the "editor" role
When I visit "node/add/landing_page"
And I click on the horizontal tab "Customised Header"
Then I should see an "#edit-header-style-options-fullwidtht" element
And I select "corner" from "edit-header-style-options-fullwidth"
Then I should see an "#edit-field-landing-page-hero-theme" element
And I should see text matching "Reverse blocked text"
And save screenshot

@api @javascript
Scenario: Selecting Call to action banner value from header style.
Given I am logged in as a user with the "editor" role
When I visit "node/add/landing_page"
And I click on the horizontal tab "Customised Header"
Then I should see an "#edit-header-style-options-cta" element
And I select "corner" from "edit-header-style-options-cta"
Then I should see an "#edit-field-landing-page-hero-theme" element
And I should see text matching "Default"
And save screenshot

0 comments on commit 9b1f2ce

Please sign in to comment.