MDL-39051 behat: Using new steps definitions

This commit is contained in:
David Monllao
2013-05-09 14:27:41 +08:00
parent b55248d5ad
commit a07ad80ae6
3 changed files with 10 additions and 14 deletions
@@ -28,20 +28,20 @@ Feature: Toggle activities groups mode from the course page
When I press "Save changes"
Then "No groups (Click to change)" "link" should exists
And ".//a//img[contains(@src, 'groupn')]" "xpath_element" should exists
And I click on "No groups (Click to change)" "link" in the "li.activity.forum" "css_element"
And I click on "No groups (Click to change)" "link" in the "Test forum name" activity
And I wait "3" seconds
And "Separate groups (Click to change)" "link" should exists
And ".//a//img[contains(@src, 'groups')]" "xpath_element" should exists
And I reload the page
And "Separate groups (Click to change)" "link" should exists
And ".//a//img[contains(@src, 'groups')]" "xpath_element" should exists
And I click on "Separate groups (Click to change)" "link" in the "li.activity.forum" "css_element"
And I click on "Separate groups (Click to change)" "link" in the "Test forum name" activity
And I wait "3" seconds
And "Visible groups (Click to change)" "link" should exists
And ".//a//img[contains(@src, 'groupv')]" "xpath_element" should exists
And I reload the page
And "Visible groups (Click to change)" "link" should exists
And ".//a//img[contains(@src, 'groupv')]" "xpath_element" should exists
And I click on "Visible groups (Click to change)" "link" in the "li.activity.forum" "css_element"
And I click on "Visible groups (Click to change)" "link" in the "Test forum name" activity
And "No groups (Click to change)" "link" should exists
And ".//a//img[contains(@src, 'groupn')]" "xpath_element" should exists
@@ -23,19 +23,15 @@ Feature: Indent items on the course page
And I add a "Glossary" to section "1" and I fill the form with:
| Name | Test glossary name |
| Description | Test glossary description |
When I click on "Move right" "link" in the "#section-1 li.glossary" "css_element"
And I wait "2" seconds
When I indent right "Test glossary name" activity
Then "#section-1 li.glossary div.mod-indent-1" "css_element" should exists
And I click on "Move right" "link" in the "#section-1 li.glossary" "css_element"
And I wait "2" seconds
And I indent right "Test glossary name" activity
And "//*[@id='section-1']/descendant::li[contains(concat(' ', @class, ' '), ' glossary ')]/descendant::a[@title='Move left']" "xpath_element" should exists
And "#section-1 li.glossary div.mod-indent-2" "css_element" should exists
And I reload the page
And "#section-1 li.glossary div.mod-indent-2" "css_element" should exists
And I click on "Move left" "link" in the "#section-1 li.glossary" "css_element"
And I wait "2" seconds
And I click on "Move left" "link" in the "#section-1 li.glossary" "css_element"
And I wait "2" seconds
And I indent left "Test glossary name" activity
And I indent left "Test glossary name" activity
And "#section-1 li.glossary div.mod-indent-2" "css_element" should not exists
And "#section-1 li.glossary div.mod-indent-1" "css_element" should not exists
And "//*[@id='section-1']/descendant::li[contains(concat(' ', @class, ' '), ' glossary ')]/descendant::a[@title='Move left']" "xpath_element" should not exists
@@ -24,11 +24,11 @@ Feature: Toggle activities visibility from the course page
| Forum name | Test forum name |
| Description | Test forum description |
| Visible | Show |
When I click on "Hide" "link" in the "li.activity.forum" "css_element"
When I click on "Hide" "link" in the "Test forum name" activity
Then "Test forum name" activity should be hidden
And I click on "Show" "link" in the "li.activity.forum" "css_element"
And I click on "Show" "link" in the "Test forum name" activity
And "Test forum name" activity should be visible
And I click on "Hide" "link" in the "li.activity.forum" "css_element"
And I click on "Hide" "link" in the "Test forum name" activity
And "Test forum name" activity should be hidden
And I reload the page
And "Test forum name" activity should be hidden