jenkins-bot has submitted this change and it was merged.

Change subject: QA: Make the visit page rule more generic
......................................................................


QA: Make the visit page rule more generic

Allow it to present any kind of page.

Change-Id: I956cebe25dd72ac0ef4314b76567f12d4872a777
---
M tests/browser/features/step_definitions/common_steps.rb
M tests/browser/features/wikitext_editor.feature
2 files changed, 9 insertions(+), 9 deletions(-)

Approvals:
  Awjrichards: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/tests/browser/features/step_definitions/common_steps.rb 
b/tests/browser/features/step_definitions/common_steps.rb
index 15cde94..8acbf0b 100644
--- a/tests/browser/features/step_definitions/common_steps.rb
+++ b/tests/browser/features/step_definitions/common_steps.rb
@@ -63,10 +63,6 @@
   on(LoginPage).login_with(ENV["MEDIAWIKI_USER"], ENV["MEDIAWIKI_PASSWORD"])
 end
 
-When /^I go to the login page$/ do
-  visit(LoginPage)
-end
-
 Given /^I am in beta mode$/ do
   visit(MobileOptions) do |page|
     page.beta_element.when_present.click
@@ -93,16 +89,20 @@
   visit(RandomPage)
 end
 
-When(/^I go to an uncreated page using URL (.+)$/) do |article|
+When(/^I go to the "(.+)" page$/) do |article|
   visit(NonexistentPage, :using_params => {:article_name => article})
 end
 
-Then(/^the URL of of my page should contain (.+)$/) do |article|
-  on(NonexistentPage).current_url.should match article
+When /^I go to the login page$/ do
+  step 'I go to the "Special:Userlogin" page'
 end
 
 When(/^I am on the home page$/) do
-  visit(HomePage)
+  step 'I go to the "Main Page" page'
+end
+
+Then(/^the URL of of my page should contain "(.+)"$/) do |article|
+  on(NonexistentPage).current_url.should match article
 end
 
 Given(/^I visit a protected page$/) do
diff --git a/tests/browser/features/wikitext_editor.feature 
b/tests/browser/features/wikitext_editor.feature
index 933d40a..a1f2ef6 100644
--- a/tests/browser/features/wikitext_editor.feature
+++ b/tests/browser/features/wikitext_editor.feature
@@ -3,7 +3,7 @@
 
   Background:
     Given I am logged into the mobile website
-    When I go to an uncreated page using URL Nonexistent_page_ijewrcmhvg34773
+    When I go to the "Nonexistent_page_ijewrcmhvg34773" page
       And I click the edit button
 
   Scenario: Opening editor

-- 
To view, visit https://gerrit.wikimedia.org/r/111252
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I956cebe25dd72ac0ef4314b76567f12d4872a777
Gerrit-PatchSet: 3
Gerrit-Project: mediawiki/extensions/MobileFrontend
Gerrit-Branch: master
Gerrit-Owner: Jdlrobson <[email protected]>
Gerrit-Reviewer: Awjrichards <[email protected]>
Gerrit-Reviewer: Cmcmahon <[email protected]>
Gerrit-Reviewer: jenkins-bot <>

_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to