diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2020-04-23 03:09:41 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2020-04-23 03:09:41 +0300 |
commit | b158645575a569bd46de15b42355940501902166 (patch) | |
tree | ef7ab6549bf28779cf01cbfd84eab23b757a1592 /qa | |
parent | 22e60f1c61443a7efd8a2334f61556d19d6630be (diff) |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'qa')
-rw-r--r-- | qa/Gemfile | 2 | ||||
-rw-r--r-- | qa/Gemfile.lock | 4 | ||||
-rw-r--r-- | qa/qa/page/project/issue/index.rb | 21 | ||||
-rw-r--r-- | qa/qa/page/project/settings/ci_cd.rb | 10 | ||||
-rw-r--r-- | qa/qa/page/project/settings/repository.rb | 10 | ||||
-rw-r--r-- | qa/qa/resource/deploy_token.rb | 14 |
6 files changed, 41 insertions, 20 deletions
diff --git a/qa/Gemfile b/qa/Gemfile index 86d8aa5c025..95533a72e6c 100644 --- a/qa/Gemfile +++ b/qa/Gemfile @@ -1,7 +1,7 @@ source 'https://rubygems.org' gem 'gitlab-qa' -gem 'activesupport', '6.0.2' # This should stay in sync with the root's Gemfile +gem 'activesupport', '~> 6.0.2.2' # This should stay in sync with the root's Gemfile gem 'capybara', '~> 3.29.0' gem 'capybara-screenshot', '~> 1.0.23' gem 'rake', '~> 12.3.0' diff --git a/qa/Gemfile.lock b/qa/Gemfile.lock index ececdab80d5..75531573a50 100644 --- a/qa/Gemfile.lock +++ b/qa/Gemfile.lock @@ -1,7 +1,7 @@ GEM remote: https://rubygems.org/ specs: - activesupport (6.0.2) + activesupport (6.0.2.2) concurrent-ruby (~> 1.0, >= 1.0.2) i18n (>= 0.7, < 2) minitest (~> 5.1) @@ -114,7 +114,7 @@ PLATFORMS ruby DEPENDENCIES - activesupport (= 6.0.2) + activesupport (~> 6.0.2.2) airborne (~> 0.2.13) capybara (~> 3.29.0) capybara-screenshot (~> 1.0.23) diff --git a/qa/qa/page/project/issue/index.rb b/qa/qa/page/project/issue/index.rb index b5ad63ab8de..ace2537fc0e 100644 --- a/qa/qa/page/project/issue/index.rb +++ b/qa/qa/page/project/issue/index.rb @@ -9,6 +9,15 @@ module QA element :assignee_link end + view 'app/views/projects/issues/export_csv/_button.html.haml' do + element :export_as_csv_button + end + + view 'app/views/projects/issues/export_csv/_modal.html.haml' do + element :export_issues_button + element :export_issues_modal + end + view 'app/views/projects/issues/_issue.html.haml' do element :issue element :issue_link, 'link_to issue.title' # rubocop:disable QA/ElementWithPattern @@ -34,6 +43,18 @@ module QA click_element :closed_issues_link end + def click_export_as_csv_button + click_element(:export_as_csv_button) + end + + def click_export_issues_button + click_element(:export_issues_button) + end + + def export_issues_modal + find_element(:export_issues_modal) + end + def has_assignee_link_count?(count) all_elements(:assignee_link, count: count) end diff --git a/qa/qa/page/project/settings/ci_cd.rb b/qa/qa/page/project/settings/ci_cd.rb index b3cbf572cb7..c43974c10cb 100644 --- a/qa/qa/page/project/settings/ci_cd.rb +++ b/qa/qa/page/project/settings/ci_cd.rb @@ -13,20 +13,10 @@ module QA element :variables_settings_content end - view 'app/views/shared/deploy_tokens/_index.html.haml' do - element :deploy_tokens_settings - end - view 'app/views/projects/deploy_keys/_index.html.haml' do element :deploy_keys_settings end - def expand_deploy_tokens(&block) - expand_section(:deploy_tokens_settings) do - Settings::DeployTokens.perform(&block) - end - end - def expand_deploy_keys(&block) expand_section(:deploy_keys_settings) do Settings::DeployKeys.perform(&block) diff --git a/qa/qa/page/project/settings/repository.rb b/qa/qa/page/project/settings/repository.rb index 9b48e62a9f9..97dfc6497a4 100644 --- a/qa/qa/page/project/settings/repository.rb +++ b/qa/qa/page/project/settings/repository.rb @@ -15,6 +15,16 @@ module QA element :mirroring_repositories_settings_section end + view 'app/views/shared/deploy_tokens/_index.html.haml' do + element :deploy_tokens_settings + end + + def expand_deploy_tokens(&block) + expand_section(:deploy_tokens_settings) do + Settings::DeployTokens.perform(&block) + end + end + def expand_protected_branches(&block) expand_section(:protected_branches_settings) do ProtectedBranches.perform(&block) diff --git a/qa/qa/resource/deploy_token.rb b/qa/qa/resource/deploy_token.rb index b4baaa47349..0ba8dbbf287 100644 --- a/qa/qa/resource/deploy_token.rb +++ b/qa/qa/resource/deploy_token.rb @@ -6,16 +6,16 @@ module QA attr_accessor :name, :expires_at attribute :username do - Page::Project::Settings::CICD.perform do |cicd_page| - cicd_page.expand_deploy_tokens do |token| + Page::Project::Settings::Repository.perform do |repository_page| + repository_page.expand_deploy_tokens do |token| token.token_username end end end attribute :password do - Page::Project::Settings::CICD.perform do |cicd_page| - cicd_page.expand_deploy_tokens do |token| + Page::Project::Settings::Repository.perform do |repository_page| + repository_page.expand_deploy_tokens do |token| token.token_password end end @@ -31,10 +31,10 @@ module QA def fabricate! project.visit! - Page::Project::Menu.perform(&:go_to_ci_cd_settings) + Page::Project::Menu.perform(&:go_to_repository_settings) - Page::Project::Settings::CICD.perform do |cicd| - cicd.expand_deploy_tokens do |page| + Page::Project::Settings::Repository.perform do |setting| + setting.expand_deploy_tokens do |page| page.fill_token_name(name) page.fill_token_expires_at(expires_at) page.fill_scopes(read_repository: true, read_registry: false) |