diff --git a/tests/browser/features/no_javascript.feature b/tests/browser/features/no_javascript.feature index f46fbc33a..327e1ce5a 100644 --- a/tests/browser/features/no_javascript.feature +++ b/tests/browser/features/no_javascript.feature @@ -2,7 +2,7 @@ Feature: Basic features for no-js functionality Background: - Given I am using user agent "Mozilla/4.0 (compatible; MSIE 5.5b1; Mac_PowerPC)" + Given I am using a nojs browser Scenario: Clicking alerts badge goes to Special:Notifications Given I am logged in diff --git a/tests/browser/features/step_definition/no_javascript.rb b/tests/browser/features/step_definition/no_javascript.rb index 32c042a92..4bd44355f 100644 --- a/tests/browser/features/step_definition/no_javascript.rb +++ b/tests/browser/features/step_definition/no_javascript.rb @@ -3,8 +3,11 @@ # Therefore it should run without any "when_present" clauses # If you need a "when_present" to make the test run, that is a bug -Given(/^I am using user agent "(.+)"$/) do |user_agent| - browser_factory.override(browser_user_agent: user_agent) +Given(/^I am using a nojs browser$/) do + # The following user-agent string contains: + # SymbianOS: for RL to NOT load the modern experience + # SMART-TV-SamsungBrowser: to bypass mobile-frontend and stay on the desktop site + browser_factory.override(browser_user_agent: 'SymbianOS,SMART-TV-SamsungBrowser') end Given(/^I am on Special Notifications page$/) do