From 3657649aaa46ffab6d29b046f1f04dc4f73bed1b Mon Sep 17 00:00:00 2001 From: Andrew Nicols Date: Wed, 11 Feb 2015 08:58:37 +0800 Subject: [PATCH] MDL-49144 blocks: Add behat test to ensury sanity of block title --- .../behat/configure_block_throughout_site.feature | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/blocks/tests/behat/configure_block_throughout_site.feature b/blocks/tests/behat/configure_block_throughout_site.feature index e3cfacb0e84..cd80c3e469f 100644 --- a/blocks/tests/behat/configure_block_throughout_site.feature +++ b/blocks/tests/behat/configure_block_throughout_site.feature @@ -56,3 +56,16 @@ Feature: Add and configure blocks throughout the site And I follow "Course 1" And I follow "Turn editing on" Then I should see "Assign roles in Search forums block" + + @javascript + Scenario: Blocks can safely be customised + Given I log in as "admin" + And I click on "My home" "link" in the "Navigation" "block" + And I press "Customise this page" + And I add the "HTML" block + And I configure the "(new HTML block)" block + And I set the following fields to these values: + | Block title | Foo " onload="document.getElementsByTagName('body')[0].remove()" alt=" + | Content | Example + When I press "Save changes" + Then I should see "Course overview"