From 3ceaea2638bcda6b7b31e2b311d7413888dc2e28 Mon Sep 17 00:00:00 2001 From: Luke Carrier Date: Thu, 16 Jun 2016 11:09:25 +0100 Subject: [PATCH 1/2] MDL-54940 behat: rectify section edit regression in MDL-53381 --- course/tests/behat/behat_course.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/course/tests/behat/behat_course.php b/course/tests/behat/behat_course.php index ed78f9801d5..cf006b9c3cc 100644 --- a/course/tests/behat/behat_course.php +++ b/course/tests/behat/behat_course.php @@ -401,7 +401,7 @@ class behat_course extends behat_base { public function i_edit_the_section_and_i_fill_the_form_with($sectionnumber, TableNode $data) { // Edit given section. - $this->execute("behat_course::i_edit_the_section"); + $this->execute("behat_course::i_edit_the_section", $sectionnumber); // Set form fields. $this->execute("behat_forms::i_set_the_following_fields_to_these_values", $data); From a48f2d3d907560dbd34fc49d38ddbc338ecb7b4b Mon Sep 17 00:00:00 2001 From: Luke Carrier Date: Sun, 19 Jun 2016 17:22:17 +0100 Subject: [PATCH 2/2] MDL-54940 behat: use the fixed step --- .../format/topics/tests/behat/edit_delete_sections.feature | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/course/format/topics/tests/behat/edit_delete_sections.feature b/course/format/topics/tests/behat/edit_delete_sections.feature index 1e6a7ddf6dc..69e9dfbfe0b 100644 --- a/course/format/topics/tests/behat/edit_delete_sections.feature +++ b/course/format/topics/tests/behat/edit_delete_sections.feature @@ -41,15 +41,13 @@ Feature: Sections can be edited and deleted in topics format Then I should see "Use default section name [Topic 2]" Scenario: Edit section summary in topics format - When I edit the section "2" - And I set the following fields to these values: + When I edit the section "2" and I fill the form with: | Summary | Welcome to section 2 | And I press "Save changes" Then I should see "Welcome to section 2" in the "li#section-2" "css_element" Scenario: Edit section default name in topics format - When I edit the section "2" - And I set the following fields to these values: + When I edit the section "2" and I fill the form with: | Use default section name | 0 | | name | This is the second topic | And I press "Save changes"