Add latest changes from gitlab-org/gitlab@master
This commit is contained in:
parent
0b79f8dae4
commit
9438e2d741
|
|
@ -118,8 +118,6 @@ export default {
|
|||
'app/assets/javascripts/ml/model_registry/components/delete_model_disclosure_dropdown_item.vue',
|
||||
'app/assets/javascripts/ml/model_registry/components/model_detail.vue',
|
||||
'app/assets/javascripts/ml/model_registry/components/model_edit.vue',
|
||||
'app/assets/javascripts/notebook/cells/output/error.vue',
|
||||
'app/assets/javascripts/notebook/cells/prompt.vue',
|
||||
'app/assets/javascripts/notes/components/comment_form.vue',
|
||||
'app/assets/javascripts/notes/components/comment_type_dropdown.vue',
|
||||
'app/assets/javascripts/notes/components/diff_discussion_header.vue',
|
||||
|
|
@ -306,20 +304,6 @@ export default {
|
|||
'ee/app/assets/javascripts/security_dashboard/components/shared/vulnerability_report/vulnerability_list_graphql.vue',
|
||||
'ee/app/assets/javascripts/security_dashboard/components/shared/vulnerability_report/vulnerability_report_tab.vue',
|
||||
'ee/app/assets/javascripts/security_dashboard/components/shared/vulnerability_report/vulnerability_report_tabs.vue',
|
||||
'ee/app/assets/javascripts/security_orchestration/components/policy_editor/branch_selector_modal.vue',
|
||||
'ee/app/assets/javascripts/security_orchestration/components/policy_editor/editor_layout.vue',
|
||||
'ee/app/assets/javascripts/security_orchestration/components/policy_editor/editor_wrapper.vue',
|
||||
'ee/app/assets/javascripts/security_orchestration/components/policy_editor/pipeline_execution/editor_component.vue',
|
||||
'ee/app/assets/javascripts/security_orchestration/components/policy_editor/scan_execution/editor_component.vue',
|
||||
'ee/app/assets/javascripts/security_orchestration/components/policy_editor/scan_result/editor_component.vue',
|
||||
'ee/app/assets/javascripts/security_orchestration/components/policy_editor/scan_result/rule/default_rule_builder.vue',
|
||||
'ee/app/assets/javascripts/security_orchestration/components/policy_editor/scan_result/rule/deny_allow_list_modal.vue',
|
||||
'ee/app/assets/javascripts/security_orchestration/components/policy_editor/scan_result/settings/block_group_branch_modification.vue',
|
||||
'ee/app/assets/javascripts/security_orchestration/components/policy_editor/scope/scope_group_selector.vue',
|
||||
'ee/app/assets/javascripts/security_orchestration/components/policy_editor/scope/scope_section.vue',
|
||||
'ee/app/assets/javascripts/security_orchestration/components/policy_editor/vulnerability_management/editor_component.vue',
|
||||
'ee/app/assets/javascripts/security_orchestration/components/shared/linked_items_dropdown.vue',
|
||||
'ee/app/assets/javascripts/security_orchestration/components/shared/multiple_groups_projects_dropdown.vue',
|
||||
'ee/app/assets/javascripts/sidebar/components/health_status/health_status_dropdown.vue',
|
||||
'ee/app/assets/javascripts/sidebar/components/incidents/escalation_status.vue',
|
||||
'ee/app/assets/javascripts/sidebar/components/weight/sidebar_weight_widget.vue',
|
||||
|
|
|
|||
|
|
@ -1,6 +1,8 @@
|
|||
<script>
|
||||
import { GlIcon, GlLink, GlBadge } from '@gitlab/ui';
|
||||
import timeagoMixin from '~/vue_shared/mixins/timeago';
|
||||
import { createAlert, VARIANT_WARNING } from '~/alert';
|
||||
import { __ } from '~/locale';
|
||||
import mergeRequestsWidgetMetadataQuery from '../graphql/queries/merge_requests_widget_metadata.query.graphql';
|
||||
|
||||
export default {
|
||||
|
|
@ -24,6 +26,7 @@ export default {
|
|||
data() {
|
||||
return {
|
||||
metadata: {},
|
||||
hasFetchError: false,
|
||||
};
|
||||
},
|
||||
apollo: {
|
||||
|
|
@ -32,6 +35,17 @@ export default {
|
|||
update({ currentUser }) {
|
||||
return currentUser;
|
||||
},
|
||||
error(error) {
|
||||
this.hasFetchError = true;
|
||||
createAlert({
|
||||
title: __('Number of merge requests not available'),
|
||||
message: __(
|
||||
'The number of merge requests is not available. Please refresh the page to try again.',
|
||||
),
|
||||
variant: VARIANT_WARNING,
|
||||
error,
|
||||
});
|
||||
},
|
||||
},
|
||||
},
|
||||
computed: {
|
||||
|
|
@ -39,13 +53,25 @@ export default {
|
|||
return this.$apollo.queries.metadata.loading;
|
||||
},
|
||||
reviewRequestedCount() {
|
||||
return this.metadata?.reviewRequestedMergeRequests?.count ?? 0;
|
||||
if (
|
||||
this.isLoadingMetadata ||
|
||||
this.hasFetchError ||
|
||||
this.metadata.reviewRequestedMergeRequests?.count === undefined
|
||||
)
|
||||
return '-';
|
||||
return this.metadata.reviewRequestedMergeRequests.count;
|
||||
},
|
||||
reviewRequestedLastUpdatedAt() {
|
||||
return this.metadata?.reviewRequestedMergeRequests?.nodes?.[0]?.updatedAt ?? null;
|
||||
},
|
||||
assignedCount() {
|
||||
return this.metadata?.assignedMergeRequests?.count ?? 0;
|
||||
if (
|
||||
this.isLoadingMetadata ||
|
||||
this.hasFetchError ||
|
||||
this.metadata.assignedMergeRequests?.count === undefined
|
||||
)
|
||||
return '-';
|
||||
return this.metadata.assignedMergeRequests.count;
|
||||
},
|
||||
assignedLastUpdatedAt() {
|
||||
return this.metadata?.assignedMergeRequests?.nodes?.[0]?.updatedAt ?? null;
|
||||
|
|
@ -60,29 +86,41 @@ export default {
|
|||
<gl-icon name="merge-request" :size="16" />{{ __('Merge requests') }}
|
||||
</h4>
|
||||
<ul class="gl-list-none gl-p-0">
|
||||
<li class="gl-flex gl-items-center gl-gap-3">
|
||||
<gl-link :href="reviewRequestedPath">{{ __('Review requested') }}</gl-link>
|
||||
<template v-if="!isLoadingMetadata">
|
||||
<li>
|
||||
<gl-link
|
||||
class="gl-flex gl-items-center gl-gap-3 !gl-no-underline hover:gl-bg-gray-10 dark:hover:gl-bg-alpha-light-8"
|
||||
variant="meta"
|
||||
:href="reviewRequestedPath"
|
||||
>
|
||||
{{ __('Review requested') }}
|
||||
<gl-badge data-testid="review-requested-count">{{ reviewRequestedCount }}</gl-badge>
|
||||
<span
|
||||
v-if="reviewRequestedLastUpdatedAt"
|
||||
data-testid="review-requested-last-updated-at"
|
||||
class="gl-ml-auto gl-text-subtle"
|
||||
>{{ timeFormatted(reviewRequestedLastUpdatedAt) }}</span
|
||||
>
|
||||
</template>
|
||||
<template v-if="!isLoadingMetadata">
|
||||
<span
|
||||
v-if="reviewRequestedLastUpdatedAt"
|
||||
data-testid="review-requested-last-updated-at"
|
||||
class="gl-ml-auto gl-text-subtle"
|
||||
>{{ timeFormatted(reviewRequestedLastUpdatedAt) }}</span
|
||||
>
|
||||
</template>
|
||||
</gl-link>
|
||||
</li>
|
||||
<li class="gl-flex gl-items-center gl-gap-3">
|
||||
<gl-link :href="assignedToYouPath">{{ __('Assigned to you') }}</gl-link>
|
||||
<template v-if="!isLoadingMetadata">
|
||||
<li>
|
||||
<gl-link
|
||||
class="gl-flex gl-items-center gl-gap-3 !gl-no-underline hover:gl-bg-gray-10 dark:hover:gl-bg-alpha-light-8"
|
||||
variant="meta"
|
||||
:href="assignedToYouPath"
|
||||
>
|
||||
{{ __('Assigned to you') }}
|
||||
<gl-badge data-testid="assigned-count">{{ assignedCount }}</gl-badge>
|
||||
<span
|
||||
v-if="assignedLastUpdatedAt"
|
||||
data-testid="assigned-last-updated-at"
|
||||
class="gl-ml-auto gl-text-subtle"
|
||||
>{{ timeFormatted(assignedLastUpdatedAt) }}</span
|
||||
>
|
||||
</template>
|
||||
<template v-if="!isLoadingMetadata">
|
||||
<span
|
||||
v-if="assignedLastUpdatedAt"
|
||||
data-testid="assigned-last-updated-at"
|
||||
class="gl-ml-auto gl-text-subtle"
|
||||
>{{ timeFormatted(assignedLastUpdatedAt) }}</span
|
||||
>
|
||||
</template>
|
||||
</gl-link>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -17,10 +17,6 @@ export default {
|
|||
type: Array,
|
||||
required: true,
|
||||
},
|
||||
index: {
|
||||
type: Number,
|
||||
required: true,
|
||||
},
|
||||
},
|
||||
computed: {
|
||||
parsedError() {
|
||||
|
|
|
|||
|
|
@ -19,9 +19,6 @@ export default {
|
|||
},
|
||||
},
|
||||
computed: {
|
||||
hasKeys() {
|
||||
return this.type !== '' && this.count;
|
||||
},
|
||||
showTypeText() {
|
||||
return this.type && this.count && this.showOutput;
|
||||
},
|
||||
|
|
|
|||
|
|
@ -202,15 +202,15 @@ export default {
|
|||
<span ref="actionText" class="system-note-separator">
|
||||
<template v-if="actionText">{{ actionText }}</template>
|
||||
</span>
|
||||
<a
|
||||
<time-ago-tooltip
|
||||
v-if="noteTimestampLink"
|
||||
ref="noteTimestampLink"
|
||||
:href="noteTimestampLink"
|
||||
class="note-timestamp system-note-separator"
|
||||
:time="createdAt"
|
||||
tooltip-placement="bottom"
|
||||
@click="updateTargetNoteHash"
|
||||
>
|
||||
<time-ago-tooltip :time="createdAt" tooltip-placement="bottom" />
|
||||
</a>
|
||||
/>
|
||||
<time-ago-tooltip v-else ref="noteTimestamp" :time="createdAt" tooltip-placement="bottom" />
|
||||
</template>
|
||||
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
<script>
|
||||
import { GlTruncate, GlTooltipDirective } from '@gitlab/ui';
|
||||
import { GlLink, GlTruncate, GlTooltipDirective } from '@gitlab/ui';
|
||||
|
||||
import { DATE_TIME_FORMATS, DEFAULT_DATE_TIME_FORMAT } from '~/lib/utils/datetime_utility';
|
||||
import timeagoMixin from '../mixins/timeago';
|
||||
|
|
@ -13,6 +13,7 @@ export default {
|
|||
GlTooltip: GlTooltipDirective,
|
||||
},
|
||||
components: {
|
||||
GlLink,
|
||||
GlTruncate,
|
||||
},
|
||||
mixins: [timeagoMixin],
|
||||
|
|
@ -47,6 +48,11 @@ export default {
|
|||
required: false,
|
||||
default: true,
|
||||
},
|
||||
href: {
|
||||
type: String,
|
||||
required: false,
|
||||
default: '',
|
||||
},
|
||||
},
|
||||
computed: {
|
||||
timeAgo() {
|
||||
|
|
@ -61,7 +67,23 @@ export default {
|
|||
};
|
||||
</script>
|
||||
<template>
|
||||
<gl-link
|
||||
v-if="href"
|
||||
v-gl-tooltip.viewport="{ placement: tooltipPlacement }"
|
||||
:href="href"
|
||||
:title="tooltipText"
|
||||
:aria-label="tooltipText"
|
||||
@click="$emit('click', $event)"
|
||||
>
|
||||
<time :class="cssClass" :datetime="time"
|
||||
><slot :time-ago="timeAgo"
|
||||
><template v-if="enableTruncation"><gl-truncate :text="timeAgo" with-tooltip /></template
|
||||
><template v-else>{{ timeAgo }}</template></slot
|
||||
></time
|
||||
>
|
||||
</gl-link>
|
||||
<time
|
||||
v-else
|
||||
v-gl-tooltip.viewport="{ placement: tooltipPlacement }"
|
||||
tabindex="0"
|
||||
:class="cssClass"
|
||||
|
|
|
|||
|
|
@ -7,16 +7,17 @@
|
|||
|
||||
- add_page_startup_api_call milestone_tab_path(@milestone, 'issues', show_project_name: false)
|
||||
|
||||
= render 'shared/milestones/header', milestone: @milestone
|
||||
= render 'shared/milestones/description', milestone: @milestone
|
||||
|
||||
- if @milestone.complete? && @milestone.active?
|
||||
- if @milestone.complete? && @milestone.active? && can?(current_user, :admin_milestone, @group || @project)
|
||||
= render Pajamas::AlertComponent.new(variant: :success,
|
||||
alert_options: { data: { testid: 'all-issues-closed-alert' }},
|
||||
alert_options: { data: { testid: 'all-issues-closed-alert' }, class: 'gl-mt-5' },
|
||||
dismissible: false) do |c|
|
||||
- c.with_body do
|
||||
= _('All issues for this milestone are closed. You may close this milestone now.')
|
||||
|
||||
= render 'shared/milestones/header', milestone: @milestone
|
||||
|
||||
= render 'shared/milestones/description', milestone: @milestone
|
||||
|
||||
= render_if_exists 'shared/milestones/burndown', milestone: @milestone, project: @project
|
||||
|
||||
= render 'shared/milestones/tabs', milestone: @milestone
|
||||
|
|
|
|||
|
|
@ -5,4 +5,4 @@ feature_category: requirements_management
|
|||
introduced_by_url: https://gitlab.com/gitlab-org/gitlab/-/merge_requests/180838
|
||||
milestone: '17.9'
|
||||
queued_migration_version: 20250209005908
|
||||
finalized_by: # version of the migration that finalized this BBM
|
||||
finalized_by: '20250620171734'
|
||||
|
|
|
|||
|
|
@ -0,0 +1,19 @@
|
|||
# frozen_string_literal: true
|
||||
|
||||
# See https://docs.gitlab.com/ee/development/migration_style_guide.html
|
||||
# for more information on how to write migrations for GitLab.
|
||||
|
||||
class RemoveNewEpicWorkerJobInstances < Gitlab::Database::Migration[2.3]
|
||||
DEPRECATED_JOB_CLASS = %w[
|
||||
NewEpicWorker
|
||||
]
|
||||
|
||||
disable_ddl_transaction!
|
||||
milestone '18.2'
|
||||
|
||||
def up
|
||||
sidekiq_remove_jobs(job_klasses: DEPRECATED_JOB_CLASS)
|
||||
end
|
||||
|
||||
def down; end
|
||||
end
|
||||
|
|
@ -0,0 +1,20 @@
|
|||
# frozen_string_literal: true
|
||||
|
||||
class FinalizeBackfillRequirementsManagementTestReportsProjectId < Gitlab::Database::Migration[2.3]
|
||||
milestone '18.2'
|
||||
disable_ddl_transaction!
|
||||
|
||||
restrict_gitlab_migration gitlab_schema: :gitlab_main_cell
|
||||
|
||||
def up
|
||||
ensure_batched_background_migration_is_finished(
|
||||
job_class_name: 'BackfillRequirementsManagementTestReportsProjectId',
|
||||
table_name: :requirements_management_test_reports,
|
||||
column_name: :id,
|
||||
job_arguments: [:project_id, :issues, :project_id, :issue_id],
|
||||
finalize: true
|
||||
)
|
||||
end
|
||||
|
||||
def down; end
|
||||
end
|
||||
|
|
@ -0,0 +1 @@
|
|||
8f63311a141431187a05ec158aceefaa4b11f3815cbc4813424352e896f5095d
|
||||
|
|
@ -0,0 +1 @@
|
|||
478911fc0952751471107d2d2b5d7d9eed7fc1b1c6d7ed02b7e221826075055d
|
||||
|
|
@ -53,6 +53,12 @@ By default, the `SHA256` digest of the tokens are stored in the database, if no
|
|||
|
||||
{{< /alert >}}
|
||||
|
||||
{{< alert type="note" >}}
|
||||
|
||||
The `token_field_encrypted` column should always be indexed, because it is used to perform uniqueness checks and lookups on the token.
|
||||
|
||||
{{< /alert >}}
|
||||
|
||||
### Other options
|
||||
|
||||
- `unique: false`: Doesn't enforce token uniqueness and disables the generation of `find_by_token_field` (where `token_field` is the attribute name). Default is `true`.
|
||||
|
|
|
|||
|
|
@ -64,12 +64,12 @@ the PostgreSQL server should have:
|
|||
|
||||
For the following versions of GitLab, use these PostgreSQL versions:
|
||||
|
||||
| GitLab version | Minimum PostgreSQL version | Maximum PostgreSQL version |
|
||||
| -------------- | -------------------------- | -------------------------- |
|
||||
| 18.x | 16.x | To be determined |
|
||||
| 17.x | 14.x | 16.x ([tested against GitLab 16.10 and later](https://gitlab.com/gitlab-org/gitlab/-/merge_requests/145298)) |
|
||||
| 16.x | 13.6 | 15.x ([tested against GitLab 16.1 and later](https://gitlab.com/gitlab-org/gitlab/-/merge_requests/119344)) |
|
||||
| 15.x | 12.10 | 14.x ([tested against GitLab 15.11 only](https://gitlab.com/gitlab-org/gitlab/-/merge_requests/114624)), 13.x |
|
||||
| GitLab version | Helm chart version | Minimum PostgreSQL version | Maximum PostgreSQL version |
|
||||
| -------------- | ------------------ | -------------------------- | -------------------------- |
|
||||
| 18.x | 9.x | 16.x | To be determined |
|
||||
| 17.x | 8.x | 14.x | 16.x ([tested against GitLab 16.10 and later](https://gitlab.com/gitlab-org/gitlab/-/merge_requests/145298)) |
|
||||
| 16.x | 7.x | 13.6 | 15.x ([tested against GitLab 16.1 and later](https://gitlab.com/gitlab-org/gitlab/-/merge_requests/119344)) |
|
||||
| 15.x | 6.x | 12.10 | 14.x ([tested against GitLab 15.11 only](https://gitlab.com/gitlab-org/gitlab/-/merge_requests/114624)), 13.x |
|
||||
|
||||
Minor PostgreSQL releases [include only bug and security fixes](https://www.postgresql.org/support/versioning/).
|
||||
Always use the latest minor version to avoid known issues in PostgreSQL.
|
||||
|
|
@ -134,6 +134,9 @@ Here are some required settings for externally managed PostgreSQL instances.
|
|||
| `shared_buffers` | minimum `2 GB` | You require more for larger database servers. The Linux package default is set to 25% of server RAM. |
|
||||
| `statement_timeout` | maximum 1 min | A statement timeout prevents runaway issues with locks and the database rejecting new clients. One minute matches the Puma rack timeout setting. |
|
||||
|
||||
You can configure some PostgreSQL settings for the specific database, rather than for all databases on the server. You might limit configuration to specific databases when hosting
|
||||
multiple databases on the same server. For guidance on where to apply configuration, consult your database administrator.
|
||||
|
||||
## Puma
|
||||
|
||||
The recommended [Puma](https://puma.io/) settings depend on your [installation](install_methods.md).
|
||||
|
|
|
|||
|
|
@ -44,4 +44,4 @@ GitLab Metrics and KPI Dashboard and Solution
|
|||
|
||||
## Compliance and Best Practice
|
||||
|
||||
[Guild on Separation of Duties](guild_on_sod.md)
|
||||
[Guide on Separation of Duties](guide_on_sod.md)
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
stage: Solutions Architecture
|
||||
group: Solutions Architecture
|
||||
info: This page is owned by the Solutions Architecture team.
|
||||
title: GitLab Tutorial Guild on Separation of Duties
|
||||
title: GitLab Tutorial Guide on Separation of Duties
|
||||
---
|
||||
|
||||
{{< details >}}
|
||||
|
|
@ -375,6 +375,10 @@ In GitLab 17.8, three new secrets have been added to support the new encryption
|
|||
|
||||
If you have a multi-node configuration, you must [ensure these secrets are the same on all nodes](#unify-new-encryption-secrets).
|
||||
|
||||
### Geo installations 17.11.0
|
||||
|
||||
- GitLab versions 17.11 through 18.1 have a known issue where Git operations proxied from a secondary Geo site fail with HTTP 500 errors. To resolve this issue, upgrade to GitLab 17.11.5 or later.
|
||||
|
||||
## 17.10.0
|
||||
|
||||
### New encryption secrets
|
||||
|
|
@ -387,6 +391,10 @@ In GitLab 17.8, three new secrets have been added to support the new encryption
|
|||
|
||||
If you have a multi-node configuration, you must [ensure these secrets are the same on all nodes](#unify-new-encryption-secrets).
|
||||
|
||||
### Geo installations 17.10.0
|
||||
|
||||
- GitLab versions 17.10 through 18.1 have a known issue where Git operations proxied from a secondary Geo site fail with HTTP 500 errors. To resolve this issue, upgrade to GitLab 17.11.5 or later.
|
||||
|
||||
## 17.9.0
|
||||
|
||||
### New encryption secrets
|
||||
|
|
@ -467,7 +475,7 @@ to identify and assess the compatibility of your external integrations.
|
|||
- Cloud Native GitLab (CNG) already upgraded to OpenSSL 3 in GitLab 16.7.0. If you are using Cloud Native GitLab, no
|
||||
action is needed. However, [Cloud Native Hybrid](../../administration/reference_architectures/_index.md#recommended-cloud-providers-and-services) installations
|
||||
use the Linux packages for stateful components, such as Gitaly. For those components, you will need to verify
|
||||
the TLS versions, ciphers, and certificates that are used to work with the security level changes
|
||||
the TLS versions, ciphers, and certificates that are used to work with the security level changes
|
||||
in the following discussion.
|
||||
|
||||
With the upgrade to OpenSSL 3:
|
||||
|
|
|
|||
|
|
@ -20,6 +20,12 @@ Ensure you review these instructions for:
|
|||
|
||||
For more information about upgrading GitLab Helm Chart, see [the release notes for 9.0](https://docs.gitlab.com/charts/releases/9_0/).
|
||||
|
||||
## 18.1.0
|
||||
|
||||
### Geo installations 18.1.0
|
||||
|
||||
- GitLab versions 18.0 through 18.1 have a known issue where Git operations proxied from a secondary Geo site fail with HTTP 500 errors. To resolve, upgrade to GitLab 18.0.3 or later.
|
||||
|
||||
## 18.0.0
|
||||
|
||||
### Geo installations 18.0.0
|
||||
|
|
@ -45,6 +51,8 @@ For more information about upgrading GitLab Helm Chart, see [the release notes f
|
|||
| ----------------------- | ----------------------- | -------- |
|
||||
| 18.0 | 18.0.0 - 18.0.1 | 18.0.2 |
|
||||
|
||||
- GitLab versions 18.0 through 18.1 have a known issue where Git operations proxied from a secondary Geo site fail with HTTP 500 errors. To resolve, upgrade to GitLab 18.0.3 or later.
|
||||
|
||||
### PRNG is not seeded error on Docker installations
|
||||
|
||||
If you run GitLab on a Docker installation with a FIPS-enabled host, you
|
||||
|
|
|
|||
|
|
@ -42250,6 +42250,9 @@ msgstr ""
|
|||
msgid "Number of files touched"
|
||||
msgstr ""
|
||||
|
||||
msgid "Number of merge requests not available"
|
||||
msgstr ""
|
||||
|
||||
msgid "Number of namespaces per indexing rollout"
|
||||
msgstr ""
|
||||
|
||||
|
|
@ -56914,6 +56917,9 @@ msgstr ""
|
|||
msgid "SecurityOrchestration|in timezone %{timezone}"
|
||||
msgstr ""
|
||||
|
||||
msgid "SecurityOrchestration|instance policy"
|
||||
msgstr ""
|
||||
|
||||
msgid "SecurityOrchestration|latest"
|
||||
msgstr ""
|
||||
|
||||
|
|
@ -62340,6 +62346,9 @@ msgstr ""
|
|||
msgid "The number of direct members in the current group. Members in subgroups are not included. %{link_start}What is a direct member%{link_end}?"
|
||||
msgstr ""
|
||||
|
||||
msgid "The number of merge requests is not available. Please refresh the page to try again."
|
||||
msgstr ""
|
||||
|
||||
msgid "The number of merge requests merged by month."
|
||||
msgstr ""
|
||||
|
||||
|
|
|
|||
|
|
@ -282,7 +282,7 @@
|
|||
"eslint-formatter-gitlab": "^6.0.1",
|
||||
"eslint-import-resolver-jest": "3.0.2",
|
||||
"eslint-import-resolver-webpack": "0.13.10",
|
||||
"eslint-plugin-import": "^2.31.0",
|
||||
"eslint-plugin-import": "^2.32.0",
|
||||
"eslint-plugin-local-rules": "^3.0.2",
|
||||
"eslint-plugin-no-jquery": "3.1.1",
|
||||
"eslint-plugin-no-unsanitized": "^4.1.2",
|
||||
|
|
|
|||
|
|
@ -58,6 +58,9 @@ function run_rspec {
|
|||
function run_jest {
|
||||
trap onexit_err ERR
|
||||
|
||||
printf "\n\n${BBlue}Running 'yarn check --integrity' and 'yarn install' if needed${Color_Off}\n\n"
|
||||
yarn check --integrity || yarn install
|
||||
|
||||
printf "\n\n${BBlue}Running MLOps frontend Jest specs${Color_Off}\n\n"
|
||||
git ls-files -- '**/ml/**/*_spec.js' | xargs yarn jest
|
||||
}
|
||||
|
|
@ -84,7 +87,7 @@ function main {
|
|||
|
||||
# Convenience ENV vars to run focused sections, copy and paste as a prefix to script command, and remove the one(s) you want to run focused
|
||||
# SKIP_RUBOCOP=1 SKIP_RSPEC=1 SKIP_JEST=1
|
||||
|
||||
|
||||
print_success_message
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -82,6 +82,9 @@ function run_rspec_fast {
|
|||
function run_jest {
|
||||
trap onexit_err ERR
|
||||
|
||||
printf "\n\n${BBlue}Running 'yarn check --integrity' and 'yarn install' if needed${Color_Off}\n\n"
|
||||
yarn check --integrity || yarn install
|
||||
|
||||
printf "\n\n${BBlue}Running Remote Development frontend Jest specs${Color_Off}\n\n"
|
||||
yarn jest ee/spec/frontend/workspaces
|
||||
}
|
||||
|
|
|
|||
|
|
@ -48,6 +48,7 @@ exports[`Design management list item component with notes renders item with mult
|
|||
<timeago-stub
|
||||
cssclass=""
|
||||
datetimeformat="asDateTime"
|
||||
href=""
|
||||
showdatewhenoverayear="true"
|
||||
time="01-01-2019"
|
||||
tooltipplacement="bottom"
|
||||
|
|
@ -112,6 +113,7 @@ exports[`Design management list item component with notes renders item with sing
|
|||
<timeago-stub
|
||||
cssclass=""
|
||||
datetimeformat="asDateTime"
|
||||
href=""
|
||||
showdatewhenoverayear="true"
|
||||
time="01-01-2019"
|
||||
tooltipplacement="bottom"
|
||||
|
|
|
|||
|
|
@ -7,8 +7,11 @@ import createMockApollo from 'helpers/mock_apollo_helper';
|
|||
import { useFakeDate } from 'helpers/fake_date';
|
||||
import MergeRequestsWidget from '~/homepage/components/merge_requests_widget.vue';
|
||||
import mergeRequestsWidgetMetadataQuery from '~/homepage/graphql/queries/merge_requests_widget_metadata.query.graphql';
|
||||
import { createAlert, VARIANT_WARNING } from '~/alert';
|
||||
import { withItems, withoutItems } from './mocks/merge_requests_widget_metadata_query_mocks';
|
||||
|
||||
jest.mock('~/alert');
|
||||
|
||||
describe('MergeRequestsWidget', () => {
|
||||
Vue.use(VueApollo);
|
||||
|
||||
|
|
@ -18,7 +21,8 @@ describe('MergeRequestsWidget', () => {
|
|||
|
||||
useFakeDate(MOCK_CURRENT_TIME);
|
||||
|
||||
const mergeRequestsWidgetMetadataQueryHandler = (data) => jest.fn().mockResolvedValue(data);
|
||||
const mergeRequestsWidgetMetadataQuerySuccessHandler = (data) =>
|
||||
jest.fn().mockResolvedValue(data);
|
||||
|
||||
let wrapper;
|
||||
|
||||
|
|
@ -29,12 +33,13 @@ describe('MergeRequestsWidget', () => {
|
|||
const findAssignedCount = () => wrapper.findByTestId('assigned-count');
|
||||
const findAssignedLastUpdatedAt = () => wrapper.findByTestId('assigned-last-updated-at');
|
||||
|
||||
function createWrapper({ mergeRequestsWidgetMetadataQueryMock = withItems } = {}) {
|
||||
function createWrapper({
|
||||
mergeRequestsWidgetMetadataQueryHandler = mergeRequestsWidgetMetadataQuerySuccessHandler(
|
||||
withItems,
|
||||
),
|
||||
} = {}) {
|
||||
const mockApollo = createMockApollo([
|
||||
[
|
||||
mergeRequestsWidgetMetadataQuery,
|
||||
mergeRequestsWidgetMetadataQueryHandler(mergeRequestsWidgetMetadataQueryMock),
|
||||
],
|
||||
[mergeRequestsWidgetMetadataQuery, mergeRequestsWidgetMetadataQueryHandler],
|
||||
]);
|
||||
wrapper = shallowMountExtended(MergeRequestsWidget, {
|
||||
apolloProvider: mockApollo,
|
||||
|
|
@ -60,13 +65,14 @@ describe('MergeRequestsWidget', () => {
|
|||
});
|
||||
|
||||
describe('metadata', () => {
|
||||
it('does not show any metadata until the query has resolved', () => {
|
||||
it("shows the counts' loading state and no timestamp until the query has resolved", () => {
|
||||
createWrapper();
|
||||
|
||||
expect(findReviewRequestedCount().exists()).toBe(false);
|
||||
expect(findReviewRequestedLastUpdatedAt().exists()).toBe(false);
|
||||
expect(findAssignedCount().exists()).toBe(false);
|
||||
expect(findAssignedLastUpdatedAt().exists()).toBe(false);
|
||||
|
||||
expect(findReviewRequestedCount().text()).toBe('-');
|
||||
expect(findAssignedCount().text()).toBe('-');
|
||||
});
|
||||
|
||||
it('shows the metadata once the query has resolved', async () => {
|
||||
|
|
@ -80,16 +86,38 @@ describe('MergeRequestsWidget', () => {
|
|||
});
|
||||
|
||||
it('shows partial metadata when the user has no relevant items', async () => {
|
||||
createWrapper({ mergeRequestsWidgetMetadataQueryMock: withoutItems });
|
||||
createWrapper({
|
||||
mergeRequestsWidgetMetadataQueryHandler:
|
||||
mergeRequestsWidgetMetadataQuerySuccessHandler(withoutItems),
|
||||
});
|
||||
await waitForPromises();
|
||||
|
||||
expect(findReviewRequestedCount().exists()).toBe(true);
|
||||
expect(findReviewRequestedLastUpdatedAt().exists()).toBe(false);
|
||||
expect(findAssignedCount().exists()).toBe(true);
|
||||
expect(findAssignedLastUpdatedAt().exists()).toBe(false);
|
||||
|
||||
expect(findReviewRequestedCount().text()).toBe('0');
|
||||
expect(findAssignedCount().text()).toBe('0');
|
||||
});
|
||||
|
||||
it('shows an alert if the query errors out', async () => {
|
||||
createWrapper({
|
||||
mergeRequestsWidgetMetadataQueryHandler: () => jest.fn().mockRejectedValue(),
|
||||
});
|
||||
await waitForPromises();
|
||||
|
||||
expect(findReviewRequestedLastUpdatedAt().exists()).toBe(false);
|
||||
expect(findAssignedLastUpdatedAt().exists()).toBe(false);
|
||||
|
||||
expect(findReviewRequestedCount().text()).toBe('-');
|
||||
expect(findAssignedCount().text()).toBe('-');
|
||||
|
||||
expect(createAlert).toHaveBeenCalledWith({
|
||||
error: expect.any(Object),
|
||||
title: 'Number of merge requests not available',
|
||||
message:
|
||||
'The number of merge requests is not available. Please refresh the page to try again.',
|
||||
variant: VARIANT_WARNING,
|
||||
});
|
||||
});
|
||||
});
|
||||
});
|
||||
|
|
|
|||
|
|
@ -11,7 +11,6 @@ describe('notebook/cells/output/error.vue', () => {
|
|||
wrapper = mount(ErrorOutput, {
|
||||
propsData: {
|
||||
rawCode: errorOutputContent,
|
||||
index: 1,
|
||||
count: 2,
|
||||
},
|
||||
provide: { relativeRawPath },
|
||||
|
|
|
|||
|
|
@ -111,7 +111,7 @@ describe('NoteHeader component', () => {
|
|||
createdAt: '2017-08-02T10:51:58.559Z',
|
||||
noteId: 123,
|
||||
});
|
||||
findTimestampLink().trigger('click');
|
||||
findTimestampLink().vm.$emit('click');
|
||||
|
||||
expect(actions.setTargetNoteHash).toHaveBeenCalled();
|
||||
});
|
||||
|
|
|
|||
|
|
@ -52,6 +52,7 @@ exports[`Repository table row component renders a symlink table row 1`] = `
|
|||
<timeago-tooltip-stub
|
||||
cssclass=""
|
||||
datetimeformat="asDateTime"
|
||||
href=""
|
||||
time="2019-01-01"
|
||||
tooltipplacement="top"
|
||||
/>
|
||||
|
|
@ -112,6 +113,7 @@ exports[`Repository table row component renders table row 1`] = `
|
|||
<timeago-tooltip-stub
|
||||
cssclass=""
|
||||
datetimeformat="asDateTime"
|
||||
href=""
|
||||
time="2019-01-01"
|
||||
tooltipplacement="top"
|
||||
/>
|
||||
|
|
@ -172,6 +174,7 @@ exports[`Repository table row component renders table row for path with special
|
|||
<timeago-tooltip-stub
|
||||
cssclass=""
|
||||
datetimeformat="asDateTime"
|
||||
href=""
|
||||
time="2019-01-01"
|
||||
tooltipplacement="top"
|
||||
/>
|
||||
|
|
|
|||
|
|
@ -49,6 +49,7 @@ exports[`Design item component with notes renders item with multiple comments 1`
|
|||
<timeago-stub
|
||||
cssclass=""
|
||||
datetimeformat="asDateTime"
|
||||
href=""
|
||||
showdatewhenoverayear="true"
|
||||
time="01-01-2019"
|
||||
tooltipplacement="bottom"
|
||||
|
|
@ -116,6 +117,7 @@ exports[`Design item component with notes renders item with single comment 1`] =
|
|||
<timeago-stub
|
||||
cssclass=""
|
||||
datetimeformat="asDateTime"
|
||||
href=""
|
||||
showdatewhenoverayear="true"
|
||||
time="01-01-2019"
|
||||
tooltipplacement="bottom"
|
||||
|
|
|
|||
Loading…
Reference in New Issue