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

Change subject: MobileFrontend and UW share upload steps.
......................................................................


MobileFrontend and UW share upload steps.

This patch will be valid when the mediawiki_selenium gem
version 2.16 is available

Change-Id: I8557a2e9315b0f47447dd5ce7208b58de0c680e8
---
M tests/browser/Gemfile.lock
M tests/browser/features/step_definitions/upload_wizard_steps.rb
2 files changed, 1 insertion(+), 14 deletions(-)

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



diff --git a/tests/browser/Gemfile.lock b/tests/browser/Gemfile.lock
index 5f91754..61e06fb 100644
--- a/tests/browser/Gemfile.lock
+++ b/tests/browser/Gemfile.lock
@@ -23,7 +23,7 @@
     headless (1.0.1)
     i18n (0.6.9)
     json (1.8.1)
-    mediawiki_selenium (0.2.9)
+    mediawiki_selenium (0.2.16)
       cucumber (~> 1.3, >= 1.3.10)
       headless (~> 1.0, >= 1.0.1)
       json (~> 1.8, >= 1.8.1)
diff --git a/tests/browser/features/step_definitions/upload_wizard_steps.rb 
b/tests/browser/features/step_definitions/upload_wizard_steps.rb
index 5898ea2..fc83382 100644
--- a/tests/browser/features/step_definitions/upload_wizard_steps.rb
+++ b/tests/browser/features/step_definitions/upload_wizard_steps.rb
@@ -43,20 +43,7 @@
 When(/^thumbnail should be visible$/) do
   on(ReleaseRightsPage).thumbnail_element.when_present.should be_visible
 end
-When(/^upload file (.+)$/) do |file_name|
-  require "tempfile"
-  path = "#{Dir.tmpdir}/#{file_name}"
 
-  require "chunky_png"
-  ChunkyPNG::Image.new(Random.new.rand(255), Random.new.rand(255), 
Random.new.rand(255)).save path
-
-  if @browser.driver.browser == :chrome
-    @browser.execute_script 
"document.getElementsByName('file')[0].removeAttribute('class');"
-    @browser.execute_script 
"document.getElementsByName('file')[0].removeAttribute('style');"
-  end
-
-  on(UploadPage).select_file = path
-end
 Then(/^(.+) checkbox should be there$/) do |_|
   on(LearnPage).skip_element.when_present.should be_visible
 end

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I8557a2e9315b0f47447dd5ce7208b58de0c680e8
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/extensions/UploadWizard
Gerrit-Branch: master
Gerrit-Owner: Cmcmahon <[email protected]>
Gerrit-Reviewer: Cmcmahon <[email protected]>
Gerrit-Reviewer: Zfilipin <[email protected]>
Gerrit-Reviewer: jenkins-bot <>

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

Reply via email to