From 9eb121134f51f7f9b2fbb859444922b43e13dc28 Mon Sep 17 00:00:00 2001 From: Roan Kattouw Date: Mon, 21 Apr 2014 18:08:23 -0700 Subject: [PATCH] [Browser tests] Move "I can click the X on the save box" to shared_steps.rb Doesn't belong in headings_steps.rb because it's used in other *.feature files like bullets.feature Change-Id: I23d3772653140e6e4639785c3622fc9a2b446801 --- .../test/browser/features/step_definitions/headings_steps.rb | 4 ---- .../test/browser/features/step_definitions/shared_steps.rb | 4 ++++ 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/modules/ve-mw/test/browser/features/step_definitions/headings_steps.rb b/modules/ve-mw/test/browser/features/step_definitions/headings_steps.rb index 7461a10e1b..00838910e7 100644 --- a/modules/ve-mw/test/browser/features/step_definitions/headings_steps.rb +++ b/modules/ve-mw/test/browser/features/step_definitions/headings_steps.rb @@ -19,10 +19,6 @@ Then(/^(.+) should appear in the diff view$/) do |headings_string| end end -Then(/^I can click the X on the save box$/) do - on(VisualEditorPage).ex_element.when_present.click -end - When(/^I click Heading$/) do on(VisualEditorPage).heading_element.when_present.click end diff --git a/modules/ve-mw/test/browser/features/step_definitions/shared_steps.rb b/modules/ve-mw/test/browser/features/step_definitions/shared_steps.rb index e320d3a263..8bf2dd4d91 100644 --- a/modules/ve-mw/test/browser/features/step_definitions/shared_steps.rb +++ b/modules/ve-mw/test/browser/features/step_definitions/shared_steps.rb @@ -66,3 +66,7 @@ end Then(/^Page text should contain (.+)$/) do |output_string| on(VisualEditorPage).page_text_element.when_present.text.should match Regexp.escape(output_string + " #{@random_string}") end + +Then(/^I can click the X on the save box$/) do + on(VisualEditorPage).ex_element.when_present.click +end \ No newline at end of file