diff options
author | Mark Lapierre <mlapierre@gitlab.com> | 2019-09-12 06:25:13 +0300 |
---|---|---|
committer | Mark Lapierre <mlapierre@gitlab.com> | 2019-09-12 06:25:13 +0300 |
commit | 615d6bea9585c80a86947ee3e871112781be733f (patch) | |
tree | 7144a376685b784109f355c84aa196f1093e59e6 /qa | |
parent | fc01371fbe5cf37b21f3926508c2e58ee44e6323 (diff) | |
parent | 5e79e74fa58caeeee7539b3ffee5e3ce23142d9f (diff) |
Merge branch 'qa-wiki-ssh-spec' into 'master'
CE backport of E2E Test wiki SSH push to Geo primary node
See merge request gitlab-org/gitlab-ce!32885
Diffstat (limited to 'qa')
-rw-r--r-- | qa/qa/page/profile/ssh_keys.rb | 8 | ||||
-rw-r--r-- | qa/qa/page/project/wiki/show.rb | 10 | ||||
-rw-r--r-- | qa/qa/resource/repository/wiki_push.rb | 11 |
3 files changed, 29 insertions, 0 deletions
diff --git a/qa/qa/page/profile/ssh_keys.rb b/qa/qa/page/profile/ssh_keys.rb index ce1813b14d0..082202f91ca 100644 --- a/qa/qa/page/profile/ssh_keys.rb +++ b/qa/qa/page/profile/ssh_keys.rb @@ -14,6 +14,10 @@ module QA element :delete_key_button end + view 'app/views/profiles/keys/_key_table.html.haml' do + element :ssh_keys_list + end + def add_key(public_key, title) fill_element :key_public_key_field, public_key fill_element :key_title_field, title @@ -28,6 +32,10 @@ module QA click_element :delete_key_button end end + + def keys_list + find_element(:ssh_keys_list).text + end end end end diff --git a/qa/qa/page/project/wiki/show.rb b/qa/qa/page/project/wiki/show.rb index f79ad510084..44619d177b1 100644 --- a/qa/qa/page/project/wiki/show.rb +++ b/qa/qa/page/project/wiki/show.rb @@ -11,11 +11,21 @@ module QA element :clone_repository_link, 'Clone repository' # rubocop:disable QA/ElementWithPattern end + view 'app/views/projects/wikis/show.html.haml' do + element :wiki_page_content + end + def click_clone_repository click_on 'Clone repository' end + + def wiki_text + find_element(:wiki_page_content).text + end end end end end end + +QA::Page::Project::Wiki::Show.prepend_if_ee('QA::EE::Page::Project::Wiki::Show') diff --git a/qa/qa/resource/repository/wiki_push.rb b/qa/qa/resource/repository/wiki_push.rb index 95712300854..06cca85cbb2 100644 --- a/qa/qa/resource/repository/wiki_push.rb +++ b/qa/qa/resource/repository/wiki_push.rb @@ -31,6 +31,17 @@ module QA end end + def repository_ssh_uri + @repository_ssh_uri ||= begin + wiki.visit! + Page::Project::Wiki::Show.act do + click_clone_repository + choose_repository_clone_ssh + repository_location.uri + end + end + end + def fabricate! super wiki.visit! |