Proyectos de Subversion Moodle

Rev

Rev 1 | Mostrar el archivo completo | | | Autoría | Ultima modificación | Ver Log |

Rev 1 Rev 11
Línea 1... Línea 1...
1
@editor @editor_tiny @tiny_link @_file_upload
1
@editor @editor_tiny @tiny_link
2
Feature: Add links to TinyMCE
2
Feature: Add links to TinyMCE
3
  To write rich text - I need to add links.
3
  To write rich text - I need to add links.
Línea 4... Línea 4...
4
 
4
 
5
  @javascript
5
  @javascript
6
  Scenario: Insert a link
6
  Scenario: Insert a link
7
    Given the following "blocks" exist:
7
    Given the following "user private file" exists:
8
      | blockname     | contextlevel | reference | pagetypepattern | defaultregion |
8
      | user     | admin                                                |
9
      | private_files | System       | 1         | my-index        | side-post     |
9
      | filepath | lib/editor/tiny/tests/behat/fixtures/moodle-logo.png |
10
    And I log in as "admin"
-
 
11
    And I follow "Manage private files..."
-
 
12
    And I upload "lib/editor/tiny/tests/behat/fixtures/moodle-logo.png" file to "Files" filemanager
-
 
13
    And I click on "Save changes" "button"
10
    And I log in as "admin"
14
    And I open my profile in edit mode
11
    And I open my profile in edit mode
15
    And I set the field "Description" to "Super cool"
12
    And I set the field "Description" to "Super cool"
16
    When I select the "p" element in position "0" of the "Description" TinyMCE editor
13
    When I select the "p" element in position "0" of the "Description" TinyMCE editor
17
    And I click on the "Link" button for the "Description" TinyMCE editor
14
    And I click on the "Link" button for the "Description" TinyMCE editor
Línea 98... Línea 95...
98
    And I click on "Update link" "button" in the "Create link" "dialogue"
95
    And I click on "Update link" "button" in the "Create link" "dialogue"
99
    And the field "Description" matches value "<p><a href=\"https://moodle.com/\">Moodle - Open-source learning platform</a></p>"
96
    And the field "Description" matches value "<p><a href=\"https://moodle.com/\">Moodle - Open-source learning platform</a></p>"
Línea 100... Línea 97...
100
 
97
 
101
  @javascript
98
  @javascript
102
  Scenario: Insert a link for an image using TinyMCE editor
99
  Scenario: Insert a link for an image using TinyMCE editor
103
    Given I log in as "admin"
100
    Given the following "user private file" exists:
104
    And I follow "Private files" in the user menu
101
      | user     | admin                                                |
105
    And I upload "lib/editor/tiny/tests/behat/fixtures/moodle-logo.png" file to "Files" filemanager
102
      | filepath | lib/editor/tiny/tests/behat/fixtures/moodle-logo.png |
106
    And I click on "Save changes" "button"
103
    And I log in as "admin"
107
    And I open my profile in edit mode
104
    And I open my profile in edit mode
108
    And I click on the "Image" button for the "Description" TinyMCE editor
105
    And I click on the "Image" button for the "Description" TinyMCE editor
109
    And I click on "Browse repositories" "button" in the "Insert image" "dialogue"
106
    And I click on "Browse repositories" "button" in the "Insert image" "dialogue"
110
    And I select "Private files" repository in file picker
107
    And I select "Private files" repository in file picker
111
    And I click on "moodle-logo.png" "link"
108
    And I click on "moodle-logo.png" "link"
112
    And I click on "Select this file" "button"
109
    And I click on "Select this file" "button"
113
    And I set the field "How would you describe this image to someone who can't see it:" to "It's the Moodle"
110
    And I set the field "How would you describe this image to someone who can't see it?" to "It's the Moodle"
114
    And I click on "Save" "button" in the "Image details" "dialogue"
111
    And I click on "Save" "button" in the "Image details" "dialogue"
115
    And I select the "img" element in position "0" of the "Description" TinyMCE editor
112
    And I select the "img" element in position "0" of the "Description" TinyMCE editor
116
    And I click on the "Link" button for the "Description" TinyMCE editor
113
    And I click on the "Link" button for the "Description" TinyMCE editor
117
    And I set the field "Enter a URL" to "https://moodle.org/"
114
    And I set the field "Enter a URL" to "https://moodle.org/"
Línea 130... Línea 127...
130
    And I set the field "Text editor" to "TinyMCE editor"
127
    And I set the field "Text editor" to "TinyMCE editor"
131
    And I press "Save changes"
128
    And I press "Save changes"
132
    And I click on "Edit profile" "link" in the "region-main" "region"
129
    And I click on "Edit profile" "link" in the "region-main" "region"
133
    And I select the "img" element in position "0" of the "Description" TinyMCE editor
130
    And I select the "img" element in position "0" of the "Description" TinyMCE editor
134
    And I click on the "Image" button for the "Description" TinyMCE editor
131
    And I click on the "Image" button for the "Description" TinyMCE editor
135
    And the field "How would you describe this image to someone who can't see it:" matches value "It's the Moodle"
132
    And the field "How would you describe this image to someone who can't see it?" matches value "It's the Moodle"
136
    And I click on "Close" "button" in the "Image details" "dialogue"
133
    And I click on "Close" "button" in the "Image details" "dialogue"
137
    And I click on the "Link" button for the "Description" TinyMCE editor
134
    And I click on the "Link" button for the "Description" TinyMCE editor
138
    And the field "Text to display" matches value "Moodle - Open-source learning platform"
135
    And the field "Text to display" matches value "Moodle - Open-source learning platform"
139
    And the field "Enter a URL" matches value "https://moodle.org/"
136
    And the field "Enter a URL" matches value "https://moodle.org/"