Skip to content

Commit

Permalink
Merge branch '4.6'
Browse files Browse the repository at this point in the history
  • Loading branch information
tomaszszopinski committed Jun 19, 2024
2 parents 50dc38e + d64be27 commit 849d089
Show file tree
Hide file tree
Showing 12 changed files with 108 additions and 1 deletion.
2 changes: 1 addition & 1 deletion behat_ibexa_oss.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ default:
pretty: true
extensions:
Behat\MinkExtension:
files_path: '%paths.base%/vendor/ibexa/admin-ui/src/lib/Behat/TestFiles/'
files_path: '%paths.base%/vendor/ibexa/behat/src/lib/Behat/TestFiles/'
base_url: '%env(string:WEB_HOST)%'
goutte: ~
javascript_session: 'selenium'
Expand Down
85 changes: 85 additions & 0 deletions src/lib/Behat/TestFiles/binary1.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,85 @@
Feature: Content fields setting and editing
As an administrator
In order to manage content on my site
I want to set, edit, copy and move content items.

@javascript @common @EZP-29291-excluded
Scenario Outline: Create content item with given field
Given a content type "<fieldName> CT" with an "<fieldInternalName>" field definition
And I am logged as "admin"
And I go to "Content structure" in "Content" tab
When I start creating a new content "<fieldName> CT"
And I set content fields
| label | <label1> | <label2> | <label3> |
| Field | <value1> | <value2> | <value3> |
And I click on the edit action bar button "Publish"
Then I should be on content item page "<contentItemName>" of type "<fieldName> CT" in root path
And success notification that "Content published." appears
And content attributes equal
| label | <label1> | <label2> | <label3> |
| Field | <value1> | <value2> | <value3> |

Examples:
| fieldInternalName | fieldName | label1 | value1 | label2 | value2 | label3 | value3 | contentItemName |
# | ezselection | Selection | value | Test-value | | | | | Test-value |
# | ezgmaplocation | Map location | latitude | 32 | longitude | 132 | address | Acapulco | Acapulco |
# | ezauthor | Authors | name | Test Name | email | [email protected] | | | Test Name |
# | ezboolean | Checkbox | value | true | | | | | 1 |
# | ezobjectrelation | Content relation (single) | value | Media/Images | | | | | Images |
# | ezobjectrelationlist | Content relations (multiple) | firstItem | Media/Images | secondItem | Media/Files | | | Images Files |
# | ezcountry | Country | value | Poland | | | | | Poland |
# | ezdate | Date | value | 11/23/2019 | | | | | Saturday 23 November 2019 |
# | ezdatetime | Date and time | date | 11/23/2019 | time | 14:45 | | | Sat 2019-23-11 14:45:00 |
# | ezemail | E-mail address | value | [email protected] | | | | | [email protected] |
# | ezfloat | Float | value | 11.11 | | | | | 11.11 |
# | ezisbn | ISBN | value | 978-3-16-148410-0 | | | | | 978-3-16-148410-0 |
# | ezinteger | Integer | value | 1111 | | | | | 1111 |
# | ezkeyword | Keywords | value | first keyword, second | | | | | first keyword, second |
# | ezrichtext | Rich text | value | Lorem ipsum dolor sit | | | | | Lorem ipsum dolor sit |
# | eztext | Text block | value | Lorem ipsum dolor | | | | | Lorem ipsum dolor |
# | ezstring | Text line | value | Lorem ipsum | | | | | Lorem ipsum |
# | eztime | Time | value | 14:45 | | | | | 2:45:00 pm |
# | ezurl | URL | text | Test URL | url | http://www.google.com | | | Test URL |
# | ezmedia | Media | value | ezplatform-admin-ui/src/bundle/Resources/public/img/login-background.jpg | | | || test |
| ezimage | Image | value | login-background.jpg | | | || test |
# | ezbinaryfile | File | value | ezplatform-admin-ui/src/bundle/Resources/public/img/login-background.jpg | | | || test |

@javascript @common @EZP-29291-excluded
Scenario Outline: Edit content item with given field
Given I am logged as "admin"
And I navigate to content "<oldContentItemName>" of type "<fieldName> CT" in root path
When I click on the edit action bar button "Edit"
And I set content fields
| label | <label1> | <label2> | <label3> |
| Field | <value1> | <value2> | <value3> |
And I click on the edit action bar button "Publish"
Then I should be on content item page "<newContentItemName>" of type "<fieldName> CT" in root path
And success notification that "Content published." appears
And content attributes equal
| label | <label1> | <label2> | <label3> |
| Field | <value1> | <value2> | <value3> |

Examples:
| fieldName | label1 | value1 | label2 | value2 | label3 | value3 | oldContentItemName | newContentItemName |
# | Selection | value | Bielefeld | | | | | Test-value | Bielefeld |
# | Map location | latitude | 56 | longitude | 101 | address | Ohio | Acapulco | Ohio |
# | Authors | name | Test Name Edited | email | [email protected] | | | Test Name | Test Name Edited |
# | Checkbox | value | false | | | | | 1 | 0 |
# | Content relation (single) | value | Media/Files | | | | | Images | Files |
# | Content relations (multiple) | firstItem | Users/Editors | secondItem | Media/Multimedia | | | Images Files | Editors Multimedia |
# | Country | value | Sweden | | | | | Poland | Sweden |
# | Date | value | 12/30/2019 | | | | | Saturday 23 November 2019 | Monday 30 December 2019 |
# | Date and time | date | 12/30/2019 | time | 15:15 | | | Sat 2019-23-11 14:45:00 | Mon 2019-30-12 15:15:00 |
# | E-mail address | value | [email protected] | | | | | [email protected] | [email protected] |
# | Float | value | 12.34 | | | | | 11.11 | 12.34 |
# | ISBN | value | 0-13-048257-9 | | | | | 978-3-16-148410-0 | 0-13-048257-9 |
# | Integer | value | 1234 | | | | | 1111 | 1234 |
# | Keywords | value | first keyword, second, edit | | | | | first keyword, second | first keyword, second, edit |
# | Rich text | value | Edited Lorem ipsum dolor sit | | | | | Lorem ipsum dolor sit | Edited Lorem ipsum dolor sit |
# | Text block | value | Edited Lorem ipsum dolor | | | | | Lorem ipsum dolor | Edited Lorem ipsum dolor |
# | Text line | value | Edited Lorem ipsum | | | | | Lorem ipsum | Edited Lorem ipsum |
# | Time | value | 15:15 | | | | | 2:45:00 pm | 3:15:00 pm |
# | URL | text | Edited Test URL | url | http://www.ez.no | | | Test URL | Edited Test URL |
# | Media | value | ezplatform-admin-ui/src/bundle/Resources/public/img/errors/500.png | | | | | test | test |
| Image | value | errors/500.png | | | | | test | test |
# | File | value | ezplatform-admin-ui/src/bundle/Resources/public/img/errors/500.png | | | | | test | test |
18 changes: 18 additions & 0 deletions src/lib/Behat/TestFiles/binary2.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
Feature: Verify that Admin Panel is available only for authenticated users

@javascript @common
Scenario: Should be redirected to Dashboard after successful login
Given I open Login page
When I login as admin with password publish
Then I should be on Dashboard page

@javascript @common
Scenario: Should be redirected to Login page from Dashboard when not logged in
When I try to open Dashboard page
Then I should be on Login page

@javascript @common
Scenario: Should be redirected to Login page after unsuccessful login
Given I open Login page
When I login as admin with password notpublish
Then I should be on Login page
Empty file.
Binary file added src/lib/Behat/TestFiles/image1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added src/lib/Behat/TestFiles/image2.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added src/lib/Behat/TestFiles/imageasset1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added src/lib/Behat/TestFiles/imageasset2.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
CODE;QTY
Product1;10
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
CODE;QTY
nonexistentProduct1;10
Binary file added src/lib/Behat/TestFiles/video1.mp4
Binary file not shown.
Binary file added src/lib/Behat/TestFiles/video2.mp4
Binary file not shown.

0 comments on commit 849d089

Please sign in to comment.