[MediaWiki-commits] [Gerrit] Moved tests to UploadWizard repository - change (qa/browsertests)
jenkins-bot has submitted this change and it was merged. Change subject: Moved tests to UploadWizard repository .. Moved tests to UploadWizard repository See also the commit[1] in UploadWizard repository that moves the tests there and the commit[2] in mediawiki/selenium repository that documents changes in Jenkins jobs. 1: https://gerrit.wikimedia.org/r/#/c/112895/ 2: https://gerrit.wikimedia.org/r/#/c/112899/ Bug: 56419 Change-Id: I3f53483791a5e6427a5e8348ccc5a346c0cb60b7 --- M tests/browser/Gemfile M tests/browser/Gemfile.lock D tests/browser/features/step_definitions/upload_wizard_steps.rb D tests/browser/features/support/pages/describe_page.rb D tests/browser/features/support/pages/learn_page.rb D tests/browser/features/support/pages/release_rights_page.rb D tests/browser/features/support/pages/upload_page.rb D tests/browser/features/support/pages/upload_wizard_page.rb D tests/browser/features/support/pages/use_page.rb D tests/browser/features/upload_wizard.feature 10 files changed, 0 insertions(+), 347 deletions(-) Approvals: Cmcmahon: Looks good to me, approved jenkins-bot: Verified diff --git a/tests/browser/Gemfile b/tests/browser/Gemfile index 8f379eb..f7ea33d 100755 --- a/tests/browser/Gemfile +++ b/tests/browser/Gemfile @@ -3,5 +3,4 @@ source "https://rubygems.org"; -gem "chunky_png" gem "mediawiki_selenium" diff --git a/tests/browser/Gemfile.lock b/tests/browser/Gemfile.lock index 2f48062..f1a6d86 100644 --- a/tests/browser/Gemfile.lock +++ b/tests/browser/Gemfile.lock @@ -4,7 +4,6 @@ builder (3.2.2) childprocess (0.4.0) ffi (~> 1.0, >= 1.0.11) -chunky_png (1.3.0) cucumber (1.3.10) builder (>= 2.1.2) diff-lcs (>= 1.1.3) @@ -66,5 +65,4 @@ x86-mingw32 DEPENDENCIES - chunky_png mediawiki_selenium diff --git a/tests/browser/features/step_definitions/upload_wizard_steps.rb b/tests/browser/features/step_definitions/upload_wizard_steps.rb deleted file mode 100644 index 9b38d1e..000 --- a/tests/browser/features/step_definitions/upload_wizard_steps.rb +++ /dev/null @@ -1,87 +0,0 @@ -# -# This file is subject to the license terms in the LICENSE file found in the -# qa-browsertests top-level directory and at -# https://git.wikimedia.org/blob/qa%2Fbrowsertests/HEAD/LICENSE. No part of -# qa-browsertests, including this file, may be copied, modified, propagated, or -# distributed except according to the terms contained in the LICENSE file. -# -# Copyright 2012-2014 by the Mediawiki developers. See the CREDITS file in the -# qa-browsertests top-level directory and at -# https://git.wikimedia.org/blob/qa%2Fbrowsertests/HEAD/CREDITS -# -When(/^click button Continue$/) do - on(UploadPage).continue_element.when_present(15).click -end -When(/^I click Next button$/) do - on(UploadWizardPage).next_element.when_present(15).click -end -When(/^I click Next button at Describe page$/) do - sleep 1 # todo # I can not figure out at the moment how to make this work without using sleep - on(DescribePage).next_element.when_present(15).click -end -When(/^I click Next button at Learn page$/) do - on(LearnPage).next_element.when_present(15).click -end -When(/^I click Next button at Release rights page$/) do - on(ReleaseRightsPage).next_element.when_present(15).click -end -When(/^I click This file is my own work$/) do - on(ReleaseRightsPage).select_my_own_work -end -When(/^I enter category$/) do - on(DescribePage).category = "Test" -end -When(/^I enter description$/) do - on(DescribePage).description = "description" -end -When(/^I enter title$/) do - on(DescribePage).title = "Title #{Random.new.rand}" -end -When(/^I navigate to Upload Wizard$/) do - visit UploadWizardPage -end -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 -Then(/^Describe page should open$/) do - @browser.url.should match /Special:UploadWizard/ -end -Then(/^Learn page should appear$/) do - @browser.url.should match /Special:UploadWizard/ -end -Then(/^Release rights page should open$/) do - @browser.url.should match /Special:UploadWizard/ -end -Then(/^Select a media file to donate button should be there$/) do - sleep 1 - on(UploadPage).select_file_element.when_present.should be_visible -end -Then(/^title text fi
[MediaWiki-commits] [Gerrit] Moved tests to UploadWizard repository - change (qa/browsertests)
Zfilipin has uploaded a new change for review. https://gerrit.wikimedia.org/r/112894 Change subject: Moved tests to UploadWizard repository .. Moved tests to UploadWizard repository Bug: 56419 Change-Id: I3f53483791a5e6427a5e8348ccc5a346c0cb60b7 --- M tests/browser/Gemfile M tests/browser/Gemfile.lock D tests/browser/features/step_definitions/upload_wizard_steps.rb D tests/browser/features/support/pages/describe_page.rb D tests/browser/features/support/pages/learn_page.rb D tests/browser/features/support/pages/release_rights_page.rb D tests/browser/features/support/pages/upload_page.rb D tests/browser/features/support/pages/upload_wizard_page.rb D tests/browser/features/support/pages/use_page.rb D tests/browser/features/upload_wizard.feature 10 files changed, 0 insertions(+), 347 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/qa/browsertests refs/changes/94/112894/1 diff --git a/tests/browser/Gemfile b/tests/browser/Gemfile index 8f379eb..f7ea33d 100755 --- a/tests/browser/Gemfile +++ b/tests/browser/Gemfile @@ -3,5 +3,4 @@ source "https://rubygems.org"; -gem "chunky_png" gem "mediawiki_selenium" diff --git a/tests/browser/Gemfile.lock b/tests/browser/Gemfile.lock index 2f48062..f1a6d86 100644 --- a/tests/browser/Gemfile.lock +++ b/tests/browser/Gemfile.lock @@ -4,7 +4,6 @@ builder (3.2.2) childprocess (0.4.0) ffi (~> 1.0, >= 1.0.11) -chunky_png (1.3.0) cucumber (1.3.10) builder (>= 2.1.2) diff-lcs (>= 1.1.3) @@ -66,5 +65,4 @@ x86-mingw32 DEPENDENCIES - chunky_png mediawiki_selenium diff --git a/tests/browser/features/step_definitions/upload_wizard_steps.rb b/tests/browser/features/step_definitions/upload_wizard_steps.rb deleted file mode 100644 index ab67e9f..000 --- a/tests/browser/features/step_definitions/upload_wizard_steps.rb +++ /dev/null @@ -1,87 +0,0 @@ -# -# This file is subject to the license terms in the LICENSE file found in the -# qa-browsertests top-level directory and at -# https://git.wikimedia.org/blob/qa%2Fbrowsertests/HEAD/LICENSE. No part of -# qa-browsertests, including this file, may be copied, modified, propagated, or -# distributed except according to the terms contained in the LICENSE file. -# -# Copyright 2012-2013 by the Mediawiki developers. See the CREDITS file in the -# qa-browsertests top-level directory and at -# https://git.wikimedia.org/blob/qa%2Fbrowsertests/HEAD/CREDITS -# -When(/^click button Continue$/) do - on(UploadPage).continue_element.when_present(15).click -end -When(/^I click Next button$/) do - on(UploadWizardPage).next_element.when_present(15).click -end -When(/^I click Next button at Describe page$/) do - sleep 1 # todo # I can not figure out at the moment how to make this work without using sleep - on(DescribePage).next_element.when_present(15).click -end -When(/^I click Next button at Learn page$/) do - on(LearnPage).next_element.when_present(15).click -end -When(/^I click Next button at Release rights page$/) do - on(ReleaseRightsPage).next_element.when_present(15).click -end -When(/^I click This file is my own work$/) do - on(ReleaseRightsPage).select_my_own_work -end -When(/^I enter category$/) do - on(DescribePage).category = "Test" -end -When(/^I enter description$/) do - on(DescribePage).description = "description" -end -When(/^I enter title$/) do - on(DescribePage).title = "Title #{Random.new.rand}" -end -When(/^I navigate to Upload Wizard$/) do - visit UploadWizardPage -end -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 -Then(/^Describe page should open$/) do - @browser.url.should match /Special:UploadWizard/ -end -Then(/^Learn page should appear$/) do - @browser.url.should match /Special:UploadWizard/ -end -Then(/^Release rights page should open$/) do - @browser.url.should match /Special:UploadWizard/ -end -Then(/^Select a media file to donate button should be there$/) do - sleep 1 - on(UploadPage).select_file_element.when_present.should be_visible -end -Then(/^title text field should be there$/) do - on(DescribePage).title_element.when_present.should be_visible -end -Then(/^Upload more files button should be there$/) do - on(UsePage).upload_more_files_element.when_present.should be_visible