Zfilipin has uploaded a new change for review.
https://gerrit.wikimedia.org/r/63123
Change subject: Fixed Watchlist tests
......................................................................
Fixed Watchlist tests
Bug: 46922
Change-Id: Id353d9014ba9fdc33d08da5db1eb8c941391b972
---
M tests/acceptance/features/step_definitions/watchlist_steps.rb
M tests/acceptance/features/watchlist.feature
2 files changed, 8 insertions(+), 7 deletions(-)
git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/MobileFrontend
refs/changes/23/63123/1
diff --git a/tests/acceptance/features/step_definitions/watchlist_steps.rb
b/tests/acceptance/features/step_definitions/watchlist_steps.rb
index 13ea68d..4e7f02b 100644
--- a/tests/acceptance/features/step_definitions/watchlist_steps.rb
+++ b/tests/acceptance/features/step_definitions/watchlist_steps.rb
@@ -27,13 +27,11 @@
#Signup takes you to the sign in page... should it take you to the Mobile
Create Account page??
Given /^I am logged into the mobile website$/ do
- on(HomePage) do |page|
+ visit(HomePage) do |page|
page.mainmenu_button_element.when_present.click
page.login_button
end
- on(LoginPage) do |page|
- page.login_with(@mediawiki_username, @mediawiki_password)
- end
+ on(LoginPage).login_with(@mediawiki_username, @mediawiki_password)
end
When /^I go to random page$/ do
diff --git a/tests/acceptance/features/watchlist.feature
b/tests/acceptance/features/watchlist.feature
index 1be2ad4..3a33c85 100644
--- a/tests/acceptance/features/watchlist.feature
+++ b/tests/acceptance/features/watchlist.feature
@@ -1,18 +1,21 @@
Feature: Manage Watchlist
Scenario: I receive notification that I need to log in to use the watchlist
functionality
- Given I am not logged in
+ Given I am on the home page
+ And I am not logged in
When I select the watchlist icon
Then I receive notification that I need to log in to use the watchlist
functionality
Scenario: Login link leads to login page
- Given I am not logged in
+ Given I am on the home page
+ And I am not logged in
When I select the watchlist icon
And I click Login
Then Login page opens
Scenario: Sign up link leads to Sign up page
- Given I am not logged in
+ Given I am on the home page
+ And I am not logged in
When I select the watchlist icon
And I click Sign up
Then Sign up page opens
--
To view, visit https://gerrit.wikimedia.org/r/63123
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: Id353d9014ba9fdc33d08da5db1eb8c941391b972
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/MobileFrontend
Gerrit-Branch: master
Gerrit-Owner: Zfilipin <[email protected]>
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits