summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--app/assets/javascripts/groups/settings/components/access_dropdown.vue35
-rw-r--r--doc/administration/gitaly/recovery.md18
-rw-r--r--spec/features/merge_request/user_awards_emoji_spec.rb11
-rw-r--r--spec/features/projects/settings/repository_settings_spec.rb19
4 files changed, 59 insertions, 24 deletions
diff --git a/app/assets/javascripts/groups/settings/components/access_dropdown.vue b/app/assets/javascripts/groups/settings/components/access_dropdown.vue
index b8a269de98a..28f059fa23e 100644
--- a/app/assets/javascripts/groups/settings/components/access_dropdown.vue
+++ b/app/assets/javascripts/groups/settings/components/access_dropdown.vue
@@ -173,22 +173,23 @@ export default {
<template #header>
<gl-search-box-by-type ref="search" v-model.trim="query" :is-loading="loading" />
</template>
- <template v-if="groups.length">
- <gl-dropdown-section-header>{{
- $options.i18n.groupsSectionHeader
- }}</gl-dropdown-section-header>
- <gl-dropdown-item
- v-for="group in groups"
- :key="`${group.id}${group.name}`"
- fingerprint
- data-testid="group-dropdown-item"
- :avatar-url="group.avatar_url"
- is-check-item
- :is-checked="isSelected(group)"
- @click.native.capture.stop="onItemClick(group)"
- >
- {{ group.name }}
- </gl-dropdown-item>
- </template>
+ <div>
+ <template v-if="groups.length">
+ <gl-dropdown-section-header>{{
+ $options.i18n.groupsSectionHeader
+ }}</gl-dropdown-section-header>
+ <gl-dropdown-item
+ v-for="group in groups"
+ :key="`${group.id}${group.name}`"
+ data-testid="group-dropdown-item"
+ :avatar-url="group.avatar_url"
+ is-check-item
+ :is-checked="isSelected(group)"
+ @click.native.capture.stop="onItemClick(group)"
+ >
+ {{ group.name }}
+ </gl-dropdown-item>
+ </template>
+ </div>
</gl-dropdown>
</template>
diff --git a/doc/administration/gitaly/recovery.md b/doc/administration/gitaly/recovery.md
index ecd68234b01..2b5916be916 100644
--- a/doc/administration/gitaly/recovery.md
+++ b/doc/administration/gitaly/recovery.md
@@ -425,3 +425,21 @@ This command fails if:
- The repository is already being tracked by the Praefect database.
- The repository does not exist on disk.
+
+### List virtual storage details
+
+> [Introduced](https://gitlab.com/gitlab-org/gitaly/-/merge_requests/4609) in GitLab 15.1.
+
+The `list-storages` Praefect sub-command lists virtual storages and their associated storage nodes. If a virtual storage is:
+
+- Specified using `-virtual-storage`, it lists only storage nodes for the specified virtual storage.
+- Not specified, all virtual storages and their associated storage nodes are listed in tabular format.
+
+```shell
+sudo /opt/gitlab/embedded/bin/praefect -config /var/opt/gitlab/praefect/config.toml list-storages -virtual-storage <virtual_storage_name>
+```
+
+The command outputs:
+
+- Result to `STDOUT` and the command's logs.
+- Errors to `STDERR`.
diff --git a/spec/features/merge_request/user_awards_emoji_spec.rb b/spec/features/merge_request/user_awards_emoji_spec.rb
index 81a88cad458..6fdc1a29174 100644
--- a/spec/features/merge_request/user_awards_emoji_spec.rb
+++ b/spec/features/merge_request/user_awards_emoji_spec.rb
@@ -11,27 +11,35 @@ RSpec.describe 'Merge request > User awards emoji', :js do
describe 'logged in' do
before do
sign_in(user)
- visit project_merge_request_path(project, merge_request)
+ visit project_merge_request_path(project, merge_request)
wait_for_requests
end
it 'adds award to merge request' do
first('[data-testid="award-button"]').click
+ wait_for_requests
expect(page).to have_selector('[data-testid="award-button"].selected')
expect(first('[data-testid="award-button"]')).to have_content '1'
visit project_merge_request_path(project, merge_request)
+ wait_for_requests
+
expect(first('[data-testid="award-button"]')).to have_content '1'
end
it 'removes award from merge request' do
first('[data-testid="award-button"]').click
+ wait_for_requests
expect(first('[data-testid="award-button"]')).to have_content '1'
+
find('[data-testid="award-button"].selected').click
+ wait_for_requests
expect(first('[data-testid="award-button"]')).to have_content '0'
visit project_merge_request_path(project, merge_request)
+ wait_for_requests
+
expect(first('[data-testid="award-button"]')).to have_content '0'
end
@@ -62,6 +70,7 @@ RSpec.describe 'Merge request > User awards emoji', :js do
describe 'logged out' do
before do
visit project_merge_request_path(project, merge_request)
+ wait_for_requests
end
it 'does not see award menu button' do
diff --git a/spec/features/projects/settings/repository_settings_spec.rb b/spec/features/projects/settings/repository_settings_spec.rb
index cfdd3d9224d..72ada356225 100644
--- a/spec/features/projects/settings/repository_settings_spec.rb
+++ b/spec/features/projects/settings/repository_settings_spec.rb
@@ -141,6 +141,8 @@ RSpec.describe 'Projects > Settings > Repository settings' do
end
context 'remote mirror settings' do
+ let(:ssh_url) { 'ssh://user@localhost/project.git' }
+
before do
visit project_settings_repository_path(project)
end
@@ -150,11 +152,12 @@ RSpec.describe 'Projects > Settings > Repository settings' do
end
it 'creates a push mirror that mirrors all branches', :js do
- expect(find('.js-mirror-protected-hidden', visible: false).value).to eq('0')
+ expect(page).to have_css('.js-mirror-protected-hidden[value="0"]', visible: false)
- fill_in 'url', with: 'ssh://user@localhost/project.git'
- select 'SSH public key', from: 'Authentication method'
+ fill_in 'url', with: ssh_url
+ expect(page).to have_css(".js-mirror-url-hidden[value=\"#{ssh_url}\"]", visible: false)
+ select 'SSH public key', from: 'Authentication method'
select_direction
Sidekiq::Testing.fake! do
@@ -170,9 +173,11 @@ RSpec.describe 'Projects > Settings > Repository settings' do
it 'creates a push mirror that only mirrors protected branches', :js do
find('#only_protected_branches').click
- expect(find('.js-mirror-protected-hidden', visible: false).value).to eq('1')
+ expect(page).to have_css('.js-mirror-protected-hidden[value="1"]', visible: false)
+
+ fill_in 'url', with: ssh_url
+ expect(page).to have_css(".js-mirror-url-hidden[value=\"#{ssh_url}\"]", visible: false)
- fill_in 'url', with: 'ssh://user@localhost/project.git'
select 'SSH public key', from: 'Authentication method'
select_direction
@@ -190,7 +195,9 @@ RSpec.describe 'Projects > Settings > Repository settings' do
it 'creates a push mirror that keeps divergent refs', :js do
select_direction
- fill_in 'url', with: 'ssh://user@localhost/project.git'
+ fill_in 'url', with: ssh_url
+ expect(page).to have_css(".js-mirror-url-hidden[value=\"#{ssh_url}\"]", visible: false)
+
fill_in 'Password', with: 'password'
check 'Keep divergent refs'