Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLukas Eipert <leipert@gitlab.com>2018-05-07 21:21:34 +0300
committerClement Ho <clemmakesapps@gmail.com>2018-05-07 21:21:34 +0300
commit5e436de6e4137494710d0f3f4ac5610f4f35e6a6 (patch)
tree7970cd8838fbac7acd3a74be40b365a7de16b75f /spec/features
parent924ea97aab21ba265634aca11d36f37210de8442 (diff)
Make deploy keys table more clearly structured
Diffstat (limited to 'spec/features')
-rw-r--r--spec/features/projects/deploy_keys_spec.rb6
-rw-r--r--spec/features/projects/settings/repository_settings_spec.rb10
2 files changed, 10 insertions, 6 deletions
diff --git a/spec/features/projects/deploy_keys_spec.rb b/spec/features/projects/deploy_keys_spec.rb
index 886c56e7163..43a23c42f83 100644
--- a/spec/features/projects/deploy_keys_spec.rb
+++ b/spec/features/projects/deploy_keys_spec.rb
@@ -18,12 +18,12 @@ describe 'Project deploy keys', :js do
visit project_settings_repository_path(project)
page.within(find('.deploy-keys')) do
- expect(page).to have_selector('.deploy-keys li', count: 1)
+ expect(page).to have_selector('.deploy-key', count: 1)
- accept_confirm { find(:button, text: 'Remove').send_keys(:return) }
+ accept_confirm { find('.ic-remove').click() }
expect(page).not_to have_selector('.fa-spinner', count: 0)
- expect(page).to have_selector('.deploy-keys li', count: 0)
+ expect(page).to have_selector('.deploy-key', count: 0)
end
end
end
diff --git a/spec/features/projects/settings/repository_settings_spec.rb b/spec/features/projects/settings/repository_settings_spec.rb
index 162aee63942..08b40653764 100644
--- a/spec/features/projects/settings/repository_settings_spec.rb
+++ b/spec/features/projects/settings/repository_settings_spec.rb
@@ -54,7 +54,7 @@ describe 'Projects > Settings > Repository settings' do
project.deploy_keys << private_deploy_key
visit project_settings_repository_path(project)
- find('li', text: private_deploy_key.title).click_link('Edit')
+ find('.deploy-key', text: private_deploy_key.title).find('.ic-pencil').click()
fill_in 'deploy_key_title', with: 'updated_deploy_key'
check 'deploy_key_deploy_keys_projects_attributes_0_can_push'
@@ -71,11 +71,15 @@ describe 'Projects > Settings > Repository settings' do
visit project_settings_repository_path(project)
- find('li', text: private_deploy_key.title).click_link('Edit')
+ find('.js-deployKeys-tab-available_project_keys').click()
+
+ find('.deploy-key', text: private_deploy_key.title).find('.ic-pencil').click()
fill_in 'deploy_key_title', with: 'updated_deploy_key'
click_button 'Save changes'
+ find('.js-deployKeys-tab-available_project_keys').click()
+
expect(page).to have_content('updated_deploy_key')
end
@@ -83,7 +87,7 @@ describe 'Projects > Settings > Repository settings' do
project.deploy_keys << private_deploy_key
visit project_settings_repository_path(project)
- accept_confirm { find('li', text: private_deploy_key.title).click_button('Remove') }
+ accept_confirm { find('.deploy-key', text: private_deploy_key.title).find('.ic-remove').click() }
expect(page).not_to have_content(private_deploy_key.title)
end