mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 14:05:37 +02:00
Behat feature indentation (no content changes)
This commit is contained in:
parent
e6f7f637f3
commit
aa80c4eed2
@ -1,32 +1,33 @@
|
|||||||
@todo
|
@todo
|
||||||
Feature: Apply rich formatting to content
|
Feature: Apply rich formatting to content
|
||||||
As a cms author
|
As a cms author
|
||||||
I want to work with content in the way I'm used to from word processing software
|
I want to work with content in the way I'm used to from word processing software
|
||||||
So that I make it more appealing by creating structure and highlights
|
So that I make it more appealing by creating structure and highlights
|
||||||
|
|
||||||
Background:
|
Background:
|
||||||
Given a "page" "About Us"
|
Given a "page" "About Us"
|
||||||
Given I am logged in with "ADMIN" permissions
|
Given I am logged in with "ADMIN" permissions
|
||||||
Given "About Us" has the Content
|
Given "About Us" has the Content
|
||||||
"""<h1>My awesome headline</1>
|
"""<h1>My awesome headline</1>
|
||||||
<p>Some amazing content</p>"""
|
<p>Some amazing content</p>"""
|
||||||
And I go to "/admin/pages"
|
And I go to "/admin/pages"
|
||||||
Then I follow "About Us"
|
Then I follow "About Us"
|
||||||
And I focus the "Content" field
|
And I focus the "Content" field
|
||||||
|
|
||||||
Scenario: I can control alignment of selected content
|
Scenario: I can control alignment of selected content
|
||||||
Given I highlight the content "My awesome headline"
|
Given I highlight the content "My awesome headline"
|
||||||
When I press the "Align Right" button in the HTML editor
|
When I press the "Align Right" button in the HTML editor
|
||||||
Then the content "My awesome headline" should be right aligned
|
Then the content "My awesome headline" should be right aligned
|
||||||
But the content "Some amazing content" should be left aligned
|
But the content "Some amazing content" should be left aligned
|
||||||
Then I press the "Save draft" button in the HTML editor
|
Then I press the "Save draft" button in the HTML editor
|
||||||
Then the content "My awesome headline" should still be right aligned
|
Then the content "My awesome headline" should still be right aligned
|
||||||
|
|
||||||
Scenario: I can bold selected content
|
Scenario: I can bold selected content
|
||||||
Given I highlight the content "awesome"
|
Given I highlight the content "awesome"
|
||||||
When I press the "Bold" button in the HTML editor
|
When I press the "Bold" button in the HTML editor
|
||||||
Then the content "awesome" should be bold
|
Then the content "awesome" should be bold
|
||||||
But the content "My" should not be bold
|
But the content "My" should not be bold
|
||||||
When I press the "Save draft" button in the HTML editor
|
When I press the "Save draft" button in the HTML editor
|
||||||
Then the content "awesome" should still be bold
|
Then the content "awesome" should still be bold
|
||||||
But the content "My" should still not be bold
|
But the content "My" should still not be bold
|
||||||
|
|
@ -4,49 +4,49 @@ As a cms author
|
|||||||
I want to insert a link into my content
|
I want to insert a link into my content
|
||||||
So that I can link to a external website or a page on my site
|
So that I can link to a external website or a page on my site
|
||||||
|
|
||||||
Background:
|
Background:
|
||||||
Given a "page" "About Us"
|
Given a "page" "About Us"
|
||||||
Given I am logged in with "ADMIN" permissions
|
Given I am logged in with "ADMIN" permissions
|
||||||
Given "About Us" has text in content "You can fill this page out with your own content, or delete it and create your own pages."
|
Given "About Us" has text in content "You can fill this page out with your own content, or delete it and create your own pages."
|
||||||
And I go to "/admin/pages"
|
And I go to "/admin/pages"
|
||||||
Then I should see "About Us" in CMS Tree
|
Then I should see "About Us" in CMS Tree
|
||||||
|
|
||||||
@javascript
|
@javascript
|
||||||
Scenario: I can select text within the content and apply an internal sitetree url link using the add url button
|
Scenario: I can select text within the content and apply an internal sitetree url link using the add url button
|
||||||
When I follow "About Us"
|
When I follow "About Us"
|
||||||
Then I should see an edit page form
|
Then I should see an edit page form
|
||||||
|
|
||||||
When I highlight the text "pages"
|
When I highlight the text "pages"
|
||||||
And the "Insert Link" button activates
|
And the "Insert Link" button activates
|
||||||
When I press the "Insert Link" button
|
When I press the "Insert Link" button
|
||||||
Then I should see "Form_EditorToolbarLinkForm"
|
Then I should see "Form_EditorToolbarLinkForm"
|
||||||
|
|
||||||
When I check the "Form_EditorToolbarLinkForm_LinkType_internal" radio button
|
When I check the "Form_EditorToolbarLinkForm_LinkType_internal" radio button
|
||||||
And I select "home" in "treedropdownfield-title" field
|
And I select "home" in "treedropdownfield-title" field
|
||||||
And I enter "Test Link Description" in "Form_EditorToolbarLinkForm_Description" field
|
And I enter "Test Link Description" in "Form_EditorToolbarLinkForm_Description" field
|
||||||
And I check the "Form_EditorToolbarLinkForm_TargetBlank" tickbox
|
And I check the "Form_EditorToolbarLinkForm_TargetBlank" tickbox
|
||||||
And I press the "Form_EditorToolbarLinkForm_action_insert" button
|
And I press the "Form_EditorToolbarLinkForm_action_insert" button
|
||||||
Then I should see the "content" HTML field contains "pages" with tag "<a href="[sitetree_link,id=1]">pages</a>"
|
Then I should see the "content" HTML field contains "pages" with tag "<a href="[sitetree_link,id=1]">pages</a>"
|
||||||
|
|
||||||
# Required to avoid "unsaved changed" browser dialog
|
# Required to avoid "unsaved changed" browser dialog
|
||||||
Then I press the "Save draft" button
|
Then I press the "Save draft" button
|
||||||
|
|
||||||
@javascript
|
@javascript
|
||||||
Scenario: I can select text within the content and apply an external url link using the add url button
|
Scenario: I can select text within the content and apply an external url link using the add url button
|
||||||
When I follow "About Us"
|
When I follow "About Us"
|
||||||
Then I should see an edit page form
|
Then I should see an edit page form
|
||||||
|
|
||||||
When I highlight the text "pages"
|
When I highlight the text "pages"
|
||||||
And the "Insert Link" button activates
|
And the "Insert Link" button activates
|
||||||
When I press the "Insert Link" button
|
When I press the "Insert Link" button
|
||||||
Then I should see "Form_EditorToolbarLinkForm"
|
Then I should see "Form_EditorToolbarLinkForm"
|
||||||
|
|
||||||
When I check the "Form_EditorToolbarLinkForm_LinkType_external" radio button
|
When I check the "Form_EditorToolbarLinkForm_LinkType_external" radio button
|
||||||
And I enter "http://silverstripe.com" in "Form_EditorToolbarLinkForm_external" field
|
And I enter "http://silverstripe.com" in "Form_EditorToolbarLinkForm_external" field
|
||||||
And I enter "Test Link Description" in "Form_EditorToolbarLinkForm_Description" field
|
And I enter "Test Link Description" in "Form_EditorToolbarLinkForm_Description" field
|
||||||
And I check the "Form_EditorToolbarLinkForm_TargetBlank" tickbox
|
And I check the "Form_EditorToolbarLinkForm_TargetBlank" tickbox
|
||||||
And I press the "Form_EditorToolbarLinkForm_action_insert" button
|
And I press the "Form_EditorToolbarLinkForm_action_insert" button
|
||||||
Then I should see the "content" HTML field contains "pages" with tag "<a href="http://www.silverstripe.com">pages</a>"
|
Then I should see the "content" HTML field contains "pages" with tag "<a href="http://www.silverstripe.com">pages</a>"
|
||||||
|
|
||||||
# Required to avoid "unsaved changed" browser dialog
|
# Required to avoid "unsaved changed" browser dialog
|
||||||
Then I press the "Save draft" button
|
Then I press the "Save draft" button
|
@ -1,29 +1,29 @@
|
|||||||
@assets
|
@assets
|
||||||
Feature: Insert an image into a page
|
Feature: Insert an image into a page
|
||||||
As a cms author
|
As a cms author
|
||||||
I want to insert an image into a page
|
I want to insert an image into a page
|
||||||
So that I can insert them into my content efficiently
|
So that I can insert them into my content efficiently
|
||||||
|
|
||||||
Background:
|
Background:
|
||||||
Given a "page" "About Us"
|
Given a "page" "About Us"
|
||||||
Given I am logged in with "ADMIN" permissions
|
Given I am logged in with "ADMIN" permissions
|
||||||
And I go to "/admin/pages"
|
And I go to "/admin/pages"
|
||||||
Then I should see "About Us" in CMS Tree
|
Then I should see "About Us" in CMS Tree
|
||||||
|
|
||||||
@javascript
|
Scenario: I can insert images into the content
|
||||||
Scenario: I can insert images into the content
|
When I follow "About Us"
|
||||||
When I follow "About Us"
|
Then I should see an edit page form
|
||||||
Then I should see an edit page form
|
|
||||||
|
|
||||||
When I press the "Insert Media" button
|
When I press the "Insert Media" button
|
||||||
Then I should see "Choose files to upload..."
|
Then I should see "Choose files to upload..."
|
||||||
|
|
||||||
When I press the "From the web" button
|
When I press the "From the web" button
|
||||||
And I fill in "RemoteURL" with "http://www.silverstripe.com/themes/sscom/images/silverstripe_logo_web.png"
|
And I fill in "RemoteURL" with "http://www.silverstripe.com/themes/sscom/images/silverstripe_logo_web.png"
|
||||||
And I press the "Add url" button
|
And I press the "Add url" button
|
||||||
Then I should see "silverstripe_logo_web.png (www.silverstripe.com)" in the ".ss-assetuploadfield span.name" element
|
Then I should see "silverstripe_logo_web.png (www.silverstripe.com)" in the ".ss-assetuploadfield span.name" element
|
||||||
|
|
||||||
|
When I press the "Insert" button
|
||||||
|
Then the "Content" HTML field should contain "silverstripe_logo_web.png"
|
||||||
|
# Required to avoid "unsaved changed" browser dialog
|
||||||
|
Then I press the "Save draft" button
|
||||||
|
|
||||||
When I press the "Insert" button
|
|
||||||
Then the "Content" HTML field should contain "silverstripe_logo_web.png"
|
|
||||||
# Required to avoid "unsaved changed" browser dialog
|
|
||||||
Then I press the "Save draft" button
|
|
Loading…
Reference in New Issue
Block a user