diff options
117 files changed, 605 insertions, 1110 deletions
diff --git a/.gitlab/issue_templates/AI Project Proposal.md b/.gitlab/issue_templates/AI Project Proposal.md index 97b885b7cbd..979f52075d5 100644 --- a/.gitlab/issue_templates/AI Project Proposal.md +++ b/.gitlab/issue_templates/AI Project Proposal.md @@ -114,4 +114,5 @@ _What tasks or actions should the user be capable of performing with this featur /label ~wg-ai-integration -/cc @tmccaslin @hbenson @wayne @pedroms @jmandell
\ No newline at end of file +/cc @tmccaslin @hbenson @wayne @pedroms @jmandell +/ confidential
\ No newline at end of file diff --git a/.gitlab/merge_request_templates/Stable Branch.md b/.gitlab/merge_request_templates/Stable Branch.md index 655d60f92a6..949aa6386ab 100644 --- a/.gitlab/merge_request_templates/Stable Branch.md +++ b/.gitlab/merge_request_templates/Stable Branch.md @@ -18,6 +18,7 @@ This checklist encourages us to confirm any changes have been analyzed to reduce * [ ] This MR is backporting a bug fix, documentation update, or spec fix, previously merged in the default branch. * [ ] The original MR has been deployed to GitLab.com (not applicable for documentation or spec changes). * [ ] This MR has a [severity label] assigned (if applicable). +* [ ] This MR has been approved by a maintainer (only one approval is required). * [ ] Ensure the `e2e:package-and-test-ee` job has either succeeded or been approved by a Software Engineer in Test. #### Note to the merge request author and maintainer diff --git a/.rubocop_todo/rspec/context_wording.yml b/.rubocop_todo/rspec/context_wording.yml index 560c99e3b1d..e586bcc384e 100644 --- a/.rubocop_todo/rspec/context_wording.yml +++ b/.rubocop_todo/rspec/context_wording.yml @@ -2429,7 +2429,6 @@ RSpec/ContextWording: - 'spec/requests/api/deployments_spec.rb' - 'spec/requests/api/environments_spec.rb' - 'spec/requests/api/error_tracking/collector_spec.rb' - - 'spec/requests/api/error_tracking/project_settings_spec.rb' - 'spec/requests/api/files_spec.rb' - 'spec/requests/api/generic_packages_spec.rb' - 'spec/requests/api/graphql/ci/runner_spec.rb' @@ -347,7 +347,7 @@ gem 'gitlab-labkit', '~> 0.31.1' gem 'thrift', '>= 0.16.0' # I18n -gem 'ruby_parser', '~> 3.19', require: false +gem 'ruby_parser', '~> 3.20', require: false gem 'rails-i18n', '~> 7.0' gem 'gettext_i18n_rails', '~> 1.8.0' gem 'gettext_i18n_rails_js', '~> 1.3' diff --git a/Gemfile.checksum b/Gemfile.checksum index ae0ba670fcf..24a9dc34f6f 100644 --- a/Gemfile.checksum +++ b/Gemfile.checksum @@ -539,7 +539,7 @@ {"name":"ruby-saml","version":"1.13.0","platform":"ruby","checksum":"d31cbdf5fb8fdd6aa3187e48dba3085cfeb751af30276a5739aa3659a66f069c"}, {"name":"ruby-statistics","version":"3.0.0","platform":"ruby","checksum":"610301370346931cb701e3a8d3d3e28eb65681162cae6066c0c11abf20efdc81"}, {"name":"ruby2_keywords","version":"0.0.5","platform":"ruby","checksum":"ffd13740c573b7301cf7a2e61fc857b2a8e3d3aff32545d6f8300d8bae10e3ef"}, -{"name":"ruby_parser","version":"3.19.2","platform":"ruby","checksum":"aaadcedd9263e6c32e0e667f10d4f97dac0a5de313323d1dbb5db612605ff896"}, +{"name":"ruby_parser","version":"3.20.0","platform":"ruby","checksum":"17d0c8bbef7fcdf99b1070bb2555d49111758f75d312e8799f66df831ebdcbe3"}, {"name":"rubyntlm","version":"0.6.3","platform":"ruby","checksum":"5b321456dba3130351f7451f8669f1afa83a0d26fd63cdec285b7b88e667102d"}, {"name":"rubypants","version":"0.2.0","platform":"ruby","checksum":"f07e38eac793655a0323fe91946081052341b9e69807026fcf102346589eedee"}, {"name":"rubyzip","version":"2.3.2","platform":"ruby","checksum":"3f57e3935dc2255c414484fbf8d673b4909d8a6a57007ed754dde39342d2373f"}, diff --git a/Gemfile.lock b/Gemfile.lock index 89c80be71d0..4ac289feccf 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -1368,7 +1368,7 @@ GEM rexml ruby-statistics (3.0.0) ruby2_keywords (0.0.5) - ruby_parser (3.19.2) + ruby_parser (3.20.0) sexp_processor (~> 4.16) rubyntlm (0.6.3) rubypants (0.2.0) @@ -1900,7 +1900,7 @@ DEPENDENCIES ruby-openai (~> 3.7) ruby-progressbar (~> 1.10) ruby-saml (~> 1.13.0) - ruby_parser (~> 3.19) + ruby_parser (~> 3.20) rubyzip (~> 2.3.2) rugged (~> 1.5) sanitize (~> 6.0) diff --git a/app/assets/javascripts/content_editor/components/formatting_toolbar.vue b/app/assets/javascripts/content_editor/components/formatting_toolbar.vue index 5b01d15a099..11b3a5a3069 100644 --- a/app/assets/javascripts/content_editor/components/formatting_toolbar.vue +++ b/app/assets/javascripts/content_editor/components/formatting_toolbar.vue @@ -1,5 +1,4 @@ <script> -import { GlTabs, GlTab } from '@gitlab/ui'; import trackUIControl from '../services/track_ui_control'; import ToolbarButton from './toolbar_button.vue'; import ToolbarAttachmentButton from './toolbar_attachment_button.vue'; @@ -10,8 +9,6 @@ import ToolbarMoreDropdown from './toolbar_more_dropdown.vue'; export default { components: { - GlTabs, - GlTab, ToolbarButton, ToolbarTextStyleDropdown, ToolbarLinkButton, @@ -27,83 +24,77 @@ export default { }; </script> <template> - <gl-tabs content-class="gl-display-none"> - <gl-tab title-link-class="gl-py-4 gl-px-3" :title="__('Write')" /> - <template #tabs-end> - <div class="gl-ml-auto gl-py-2 gl-display-flex gl-flex-wrap-wrap gl-align-items-end"> - <toolbar-text-style-dropdown - data-testid="text-styles" - @execute="trackToolbarControlExecution" - /> - <toolbar-button - data-testid="bold" - content-type="bold" - icon-name="bold" - editor-command="toggleBold" - :label="__('Bold text')" - @execute="trackToolbarControlExecution" - /> - <toolbar-button - data-testid="italic" - content-type="italic" - icon-name="italic" - editor-command="toggleItalic" - :label="__('Italic text')" - @execute="trackToolbarControlExecution" - /> - <toolbar-button - data-testid="blockquote" - content-type="blockquote" - icon-name="quote" - editor-command="toggleBlockquote" - :label="__('Insert a quote')" - @execute="trackToolbarControlExecution" - /> - <toolbar-button - data-testid="code" - content-type="code" - icon-name="code" - editor-command="toggleCode" - :label="__('Code')" - @execute="trackToolbarControlExecution" - /> - <toolbar-link-button data-testid="link" @execute="trackToolbarControlExecution" /> - <toolbar-button - data-testid="bullet-list" - content-type="bulletList" - icon-name="list-bulleted" - class="gl-display-none gl-sm-display-inline" - editor-command="toggleBulletList" - :label="__('Add a bullet list')" - @execute="trackToolbarControlExecution" - /> - <toolbar-button - data-testid="ordered-list" - content-type="orderedList" - icon-name="list-numbered" - class="gl-display-none gl-sm-display-inline" - editor-command="toggleOrderedList" - :label="__('Add a numbered list')" - @execute="trackToolbarControlExecution" - /> - <toolbar-button - data-testid="task-list" - content-type="taskList" - icon-name="list-task" - class="gl-display-none gl-sm-display-inline" - editor-command="toggleTaskList" - :label="__('Add a checklist')" - @execute="trackToolbarControlExecution" - /> - <toolbar-table-button data-testid="table" @execute="trackToolbarControlExecution" /> - <toolbar-attachment-button - data-testid="attachment" - @execute="trackToolbarControlExecution" - /> - <toolbar-more-dropdown data-testid="more" @execute="trackToolbarControlExecution" /> - </div> - </template> - </gl-tabs> + <div class="gl-w-full gl-border-b gl-display-flex gl-justify-content-end"> + <div class="gl-py-2 gl-display-flex gl-flex-wrap-wrap gl-align-items-end"> + <toolbar-text-style-dropdown + data-testid="text-styles" + @execute="trackToolbarControlExecution" + /> + <toolbar-button + data-testid="bold" + content-type="bold" + icon-name="bold" + editor-command="toggleBold" + :label="__('Bold text')" + @execute="trackToolbarControlExecution" + /> + <toolbar-button + data-testid="italic" + content-type="italic" + icon-name="italic" + editor-command="toggleItalic" + :label="__('Italic text')" + @execute="trackToolbarControlExecution" + /> + <toolbar-button + data-testid="blockquote" + content-type="blockquote" + icon-name="quote" + editor-command="toggleBlockquote" + :label="__('Insert a quote')" + @execute="trackToolbarControlExecution" + /> + <toolbar-button + data-testid="code" + content-type="code" + icon-name="code" + editor-command="toggleCode" + :label="__('Code')" + @execute="trackToolbarControlExecution" + /> + <toolbar-link-button data-testid="link" @execute="trackToolbarControlExecution" /> + <toolbar-button + data-testid="bullet-list" + content-type="bulletList" + icon-name="list-bulleted" + class="gl-display-none gl-sm-display-inline" + editor-command="toggleBulletList" + :label="__('Add a bullet list')" + @execute="trackToolbarControlExecution" + /> + <toolbar-button + data-testid="ordered-list" + content-type="orderedList" + icon-name="list-numbered" + class="gl-display-none gl-sm-display-inline" + editor-command="toggleOrderedList" + :label="__('Add a numbered list')" + @execute="trackToolbarControlExecution" + /> + <toolbar-button + data-testid="task-list" + content-type="taskList" + icon-name="list-task" + class="gl-display-none gl-sm-display-inline" + editor-command="toggleTaskList" + :label="__('Add a checklist')" + @execute="trackToolbarControlExecution" + /> + <toolbar-table-button data-testid="table" @execute="trackToolbarControlExecution" /> + <toolbar-attachment-button data-testid="attachment" @execute="trackToolbarControlExecution" /> + <toolbar-more-dropdown data-testid="more" @execute="trackToolbarControlExecution" /> + </div> + </div> </template> <style> .gl-spinner-container { diff --git a/app/assets/javascripts/issues/constants.js b/app/assets/javascripts/issues/constants.js index 371db4eacc3..d35355a8f26 100644 --- a/app/assets/javascripts/issues/constants.js +++ b/app/assets/javascripts/issues/constants.js @@ -26,8 +26,3 @@ export const IssuableStatusText = { [STATUS_MERGED]: __('Merged'), [STATUS_LOCKED]: __('Open'), }; - -export const IssuableTypeText = { - [TYPE_ISSUE]: __('issue'), - [TYPE_MERGE_REQUEST]: __('merge request'), -}; diff --git a/app/assets/javascripts/issues/show/components/header_actions.vue b/app/assets/javascripts/issues/show/components/header_actions.vue index b929c4dbae0..84def374d13 100644 --- a/app/assets/javascripts/issues/show/components/header_actions.vue +++ b/app/assets/javascripts/issues/show/components/header_actions.vue @@ -2,36 +2,23 @@ import { GlButton, GlDropdown, - GlDropdownDivider, GlDropdownItem, GlLink, GlModal, GlModalDirective, GlTooltipDirective, } from '@gitlab/ui'; -import * as Sentry from '@sentry/browser'; import { mapActions, mapGetters, mapState } from 'vuex'; import { createAlert, VARIANT_SUCCESS } from '~/alert'; import { EVENT_ISSUABLE_VUE_APP_CHANGE } from '~/issuable/constants'; -import { STATUS_CLOSED, TYPE_INCIDENT, TYPE_ISSUE, IssuableTypeText } from '~/issues/constants'; -import { - ISSUE_STATE_EVENT_CLOSE, - ISSUE_STATE_EVENT_REOPEN, - NEW_ACTIONS_POPOVER_KEY, -} from '~/issues/show/constants'; +import { STATUS_CLOSED, TYPE_INCIDENT, TYPE_ISSUE } from '~/issues/constants'; +import { ISSUE_STATE_EVENT_CLOSE, ISSUE_STATE_EVENT_REOPEN } from '~/issues/show/constants'; import { capitalizeFirstCharacter } from '~/lib/utils/text_utility'; -import { getCookie, parseBoolean, setCookie } from '~/lib/utils/common_utils'; import { visitUrl } from '~/lib/utils/url_utility'; import { s__, __, sprintf } from '~/locale'; import eventHub from '~/notes/event_hub'; import Tracking from '~/tracking'; -import toast from '~/vue_shared/plugins/global_toast'; import AbuseCategorySelector from '~/abuse_reports/components/abuse_category_selector.vue'; -import NewHeaderActionsPopover from '~/issues/show/components/new_header_actions_popover.vue'; -import SidebarSubscriptionsWidget from '~/sidebar/components/subscriptions/sidebar_subscriptions_widget.vue'; -import IssuableLockForm from '~/sidebar/components/lock/issuable_lock_form.vue'; -import glFeatureFlagMixin from '~/vue_shared/mixins/gl_feature_flags_mixin'; -import issueReferenceQuery from '~/sidebar/queries/issue_reference.query.graphql'; import issuesEventHub from '../event_hub'; import promoteToEpicMutation from '../queries/promote_to_epic.mutation.graphql'; import updateIssueMutation from '../queries/update_issue.mutation.graphql'; @@ -57,27 +44,21 @@ export default { 'The issue was successfully promoted to an epic. Redirecting to epic...', ), reportAbuse: __('Report abuse to administrator'), - referenceFetchError: __('An error occurred while fetching reference'), - copyReferenceText: __('Copy reference'), }, components: { DeleteIssueModal, GlButton, GlDropdown, - GlDropdownDivider, GlDropdownItem, GlLink, GlModal, AbuseCategorySelector, - NewHeaderActionsPopover, - SidebarSubscriptionsWidget, - IssuableLockForm, }, directives: { GlModal: GlModalDirective, GlTooltip: GlTooltipDirective, }, - mixins: [trackingMixin, glFeatureFlagMixin()], + mixins: [trackingMixin], inject: { canCreateIssue: { default: false, @@ -124,46 +105,15 @@ export default { reportedFromUrl: { default: '', }, - issuableEmailAddress: { - default: '', - }, - fullPath: { - default: '', - }, }, data() { return { isReportAbuseDrawerOpen: false, }; }, - apollo: { - issuableReference: { - query: issueReferenceQuery, - variables() { - return { - fullPath: this.fullPath, - iid: this.iid, - }; - }, - update(data) { - return data.workspace?.issuable?.reference || ''; - }, - skip() { - return !this.isMrSidebarMoved; - }, - error(error) { - createAlert({ message: this.$options.i18n.referenceFetchError }); - Sentry.captureException(error); - }, - }, - }, computed: { ...mapState(['isToggleStateButtonLoading']), ...mapGetters(['openState', 'getBlockedByIssues']), - ...mapGetters(['getNoteableData']), - isLocked() { - return this.getNoteableData.discussion_locked; - }, isClosed() { return this.openState === STATUS_CLOSED; }, @@ -207,17 +157,6 @@ export default { hasMobileDropdown() { return this.hasDesktopDropdown || this.showToggleIssueStateButton; }, - copyMailAddressText() { - return sprintf(__('Copy %{issueType} email address'), { - issueType: IssuableTypeText[this.issueType], - }); - }, - isMrSidebarMoved() { - return this.glFeatures.movedMrSidebar; - }, - showLockIssueOption() { - return this.isMrSidebarMoved && this.issueType === TYPE_ISSUE; - }, }, created() { eventHub.$on('toggle.issuable.state', this.toggleIssueState); @@ -227,7 +166,6 @@ export default { }, methods: { ...mapActions(['toggleStateButtonLoading']), - ...mapActions(['updateLockedAttribute']), toggleIssueState() { if (!this.isClosed && this.getBlockedByIssues?.length) { this.$refs.blockedByIssuesModal.show(); @@ -306,19 +244,7 @@ export default { edit() { issuesEventHub.$emit('open.form'); }, - dismissPopover() { - if (this.isMrSidebarMoved && !parseBoolean(getCookie(`${NEW_ACTIONS_POPOVER_KEY}`))) { - setCookie(NEW_ACTIONS_POPOVER_KEY, true); - } - }, - copyReference() { - toast(__('Reference copied')); - }, - copyEmailAddress() { - toast(__('Email address copied')); - }, }, - TYPE_ISSUE, }; </script> @@ -333,21 +259,6 @@ export default { data-testid="mobile-dropdown" :loading="isToggleStateButtonLoading" > - <template v-if="isMrSidebarMoved"> - <sidebar-subscriptions-widget - :iid="String(iid)" - :full-path="fullPath" - :issuable-type="$options.TYPE_ISSUE" - data-testid="notification-toggle" - /> - - <gl-dropdown-divider /> - </template> - - <template v-if="showLockIssueOption"> - <issuable-lock-form :is-editable="false" data-testid="lock-issue-toggle" /> - </template> - <gl-dropdown-item v-if="canUpdateIssue" @click="edit"> {{ $options.i18n.edit }} </gl-dropdown-item> @@ -364,21 +275,9 @@ export default { <gl-dropdown-item v-if="canPromoteToEpic" @click="promoteToEpic"> {{ __('Promote to epic') }} </gl-dropdown-item> - <template v-if="isMrSidebarMoved"> - <gl-dropdown-item - :data-clipboard-text="issuableReference" - data-testid="copy-reference" - @click="copyReference" - >{{ $options.i18n.copyReferenceText }}</gl-dropdown-item - > - <gl-dropdown-item - v-if="issuableEmailAddress" - :data-clipboard-text="issuableEmailAddress" - data-testid="copy-email" - @click="copyEmailAddress" - >{{ copyMailAddressText }}</gl-dropdown-item - > - </template> + <gl-dropdown-item v-if="!isIssueAuthor" @click="toggleReportAbuseDrawer(true)"> + {{ $options.i18n.reportAbuse }} + </gl-dropdown-item> <gl-dropdown-item v-if="canReportSpam" :href="submitAsSpamPath" @@ -388,7 +287,6 @@ export default { {{ __('Submit as spam') }} </gl-dropdown-item> <template v-if="canDestroyIssue"> - <gl-dropdown-divider /> <gl-dropdown-item v-gl-modal="$options.deleteModalId" variant="danger" @@ -397,13 +295,6 @@ export default { {{ deleteButtonText }} </gl-dropdown-item> </template> - <gl-dropdown-item - v-if="!isIssueAuthor" - data-testid="report-abuse-item" - @click="toggleReportAbuseDrawer(true)" - > - {{ $options.i18n.reportAbuse }} - </gl-dropdown-item> </gl-dropdown> <gl-button @@ -431,7 +322,6 @@ export default { <gl-dropdown v-if="hasDesktopDropdown" - id="new-actions-header-dropdown" v-gl-tooltip.hover class="gl-display-none gl-sm-display-inline-flex! gl-sm-ml-3" icon="ellipsis_v" @@ -444,19 +334,7 @@ export default { data-testid="desktop-dropdown" no-caret right - @shown="dismissPopover" > - <template v-if="isMrSidebarMoved"> - <sidebar-subscriptions-widget - :iid="String(iid)" - :full-path="fullPath" - :issuable-type="$options.TYPE_ISSUE" - data-testid="notification-toggle" - /> - - <gl-dropdown-divider /> - </template> - <gl-dropdown-item v-if="canCreateIssue" :href="newIssuePath"> {{ newIssueTypeText }} </gl-dropdown-item> @@ -468,24 +346,9 @@ export default { > {{ __('Promote to epic') }} </gl-dropdown-item> - <template v-if="showLockIssueOption"> - <issuable-lock-form :is-editable="false" data-testid="lock-issue-toggle" /> - </template> - <template v-if="isMrSidebarMoved"> - <gl-dropdown-item - :data-clipboard-text="issuableReference" - data-testid="copy-reference" - @click="copyReference" - >{{ $options.i18n.copyReferenceText }}</gl-dropdown-item - > - <gl-dropdown-item - v-if="issuableEmailAddress" - :data-clipboard-text="issuableEmailAddress" - data-testid="copy-email" - @click="copyEmailAddress" - >{{ copyMailAddressText }}</gl-dropdown-item - > - </template> + <gl-dropdown-item v-if="!isIssueAuthor" @click="toggleReportAbuseDrawer(true)"> + {{ $options.i18n.reportAbuse }} + </gl-dropdown-item> <gl-dropdown-item v-if="canReportSpam" :href="submitAsSpamPath" @@ -494,8 +357,8 @@ export default { > {{ __('Submit as spam') }} </gl-dropdown-item> + <template v-if="canDestroyIssue"> - <gl-dropdown-divider /> <gl-dropdown-item v-gl-modal="$options.deleteModalId" variant="danger" @@ -505,16 +368,8 @@ export default { {{ deleteButtonText }} </gl-dropdown-item> </template> - <gl-dropdown-item - v-if="!isIssueAuthor" - data-testid="report-abuse-item" - @click="toggleReportAbuseDrawer(true)" - > - {{ $options.i18n.reportAbuse }} - </gl-dropdown-item> </gl-dropdown> - <new-header-actions-popover v-if="isMrSidebarMoved" :issue-type="issueType" /> <gl-modal ref="blockedByIssuesModal" modal-id="blocked-by-issues-modal" diff --git a/app/assets/javascripts/issues/show/components/new_header_actions_popover.vue b/app/assets/javascripts/issues/show/components/new_header_actions_popover.vue deleted file mode 100644 index 975661c7d32..00000000000 --- a/app/assets/javascripts/issues/show/components/new_header_actions_popover.vue +++ /dev/null @@ -1,77 +0,0 @@ -<script> -import { GlPopover, GlButton } from '@gitlab/ui'; -import { s__, sprintf } from '~/locale'; -import { getCookie, parseBoolean, setCookie } from '~/lib/utils/common_utils'; -import { NEW_ACTIONS_POPOVER_KEY } from '~/issues/show/constants'; -import { IssuableTypeText } from '~/issues/constants'; - -export default { - name: 'NewHeaderActionsPopover', - i18n: { - popoverText: s__( - 'HeaderAction|Notifications and other %{issueType} actions have moved to this menu.', - ), - confirmButtonText: s__('HeaderAction|Okay!'), - }, - components: { - GlPopover, - GlButton, - }, - props: { - issueType: { - type: String, - required: true, - }, - }, - data() { - return { - dismissKey: NEW_ACTIONS_POPOVER_KEY, - popoverDismissed: parseBoolean(getCookie(`${NEW_ACTIONS_POPOVER_KEY}`)), - }; - }, - computed: { - popoverText() { - return sprintf(this.$options.i18n.popoverText, { - issueType: IssuableTypeText[this.issueType], - }); - }, - showPopover() { - return !this.popoverDismissed; - }, - }, - methods: { - dismissPopover() { - this.popoverDismissed = true; - setCookie(this.dismissKey, this.popoverDismissed); - }, - }, -}; -</script> - -<template> - <div> - <gl-popover - v-if="showPopover" - target="new-actions-header-dropdown" - container="viewport" - placement="left" - :show="showPopover" - triggers="manual" - content="text" - :css-classes="['gl-p-2 new-header-popover']" - > - <template #title> - <div class="gl-font-base gl-font-weight-normal"> - {{ popoverText }} - </div> - </template> - <gl-button - data-testid="confirm-button" - variant="confirm" - type="submit" - @click="dismissPopover" - >{{ $options.i18n.confirmButtonText }}</gl-button - > - </gl-popover> - </div> -</template> diff --git a/app/assets/javascripts/issues/show/constants.js b/app/assets/javascripts/issues/show/constants.js index 6320e4ef266..4d8c11f9669 100644 --- a/app/assets/javascripts/issues/show/constants.js +++ b/app/assets/javascripts/issues/show/constants.js @@ -17,5 +17,3 @@ export const issueState = { issueType: undefined, isDirty: false, }; - -export const NEW_ACTIONS_POPOVER_KEY = 'new-actions-popover-viewed'; diff --git a/app/assets/javascripts/issues/show/index.js b/app/assets/javascripts/issues/show/index.js index 100abcbe1e5..e677328cd2e 100644 --- a/app/assets/javascripts/issues/show/index.js +++ b/app/assets/javascripts/issues/show/index.js @@ -174,8 +174,6 @@ export function initHeaderActions(store, type = '') { reportedUserId: parseInt(el.dataset.reportedUserId, 10), reportedFromUrl: el.dataset.reportedFromUrl, submitAsSpamPath: el.dataset.submitAsSpamPath, - issuableEmailAddress: el.dataset.issuableEmailAddress, - fullPath: el.dataset.projectPath, }, render: (createElement) => createElement(HeaderActions), }); diff --git a/app/assets/javascripts/right_sidebar.js b/app/assets/javascripts/right_sidebar.js index 58e4553d00d..297b8ae1fc2 100644 --- a/app/assets/javascripts/right_sidebar.js +++ b/app/assets/javascripts/right_sidebar.js @@ -56,10 +56,8 @@ Sidebar.prototype.addEventListeners = function () { const layoutPage = document.querySelector('.layout-page'); const rightSidebar = document.querySelector('.js-right-sidebar'); - if (rightSidebar.classList.contains('right-sidebar-merge-requests')) { - updateSidebarClasses(layoutPage, rightSidebar); - window.addEventListener('resize', () => updateSidebarClasses(layoutPage, rightSidebar)); - } + updateSidebarClasses(layoutPage, rightSidebar); + window.addEventListener('resize', () => updateSidebarClasses(layoutPage, rightSidebar)); } }; diff --git a/app/assets/javascripts/sidebar/components/lock/issuable_lock_form.vue b/app/assets/javascripts/sidebar/components/lock/issuable_lock_form.vue index 06876546fa4..1eff4db3970 100644 --- a/app/assets/javascripts/sidebar/components/lock/issuable_lock_form.vue +++ b/app/assets/javascripts/sidebar/components/lock/issuable_lock_form.vue @@ -1,9 +1,8 @@ <script> import { GlIcon, GlTooltipDirective, GlOutsideDirective as Outside } from '@gitlab/ui'; import { mapGetters, mapActions } from 'vuex'; -import { TYPE_ISSUE } from '~/issues/constants'; +import { TYPE_ISSUE, TYPE_MERGE_REQUEST } from '~/issues/constants'; import { __, sprintf } from '~/locale'; -import { capitalizeFirstCharacter } from '~/lib/utils/text_utility'; import glFeatureFlagMixin from '~/vue_shared/mixins/gl_feature_flags_mixin'; import { createAlert } from '~/alert'; import toast from '~/vue_shared/plugins/global_toast'; @@ -46,8 +45,10 @@ export default { }, computed: { ...mapGetters(['getNoteableData']), - isMovedMrSidebar() { - return this.glFeatures.movedMrSidebar; + isMergeRequest() { + return ( + this.getNoteableData.targetType === TYPE_MERGE_REQUEST && this.glFeatures.movedMrSidebar + ); }, issuableDisplayName() { const isInIssuePage = this.getNoteableData.targetType === TYPE_ISSUE; @@ -59,6 +60,7 @@ export default { lockStatus() { return this.isLocked ? this.$options.locked : this.$options.unlocked; }, + tooltipLabel() { return this.isLocked ? __('Locked') : __('Unlocked'); }, @@ -87,13 +89,8 @@ export default { fullPath: this.fullPath, }) .then(() => { - if (this.isMovedMrSidebar) { - toast( - sprintf(__('%{issuableDisplayName} %{lockStatus}.'), { - issuableDisplayName: capitalizeFirstCharacter(this.issuableDisplayName), - lockStatus: this.isLocked ? __('locked') : __('unlocked'), - }), - ); + if (this.isMergeRequest) { + toast(this.isLocked ? __('Merge request locked.') : __('Merge request unlocked.')); } }) .catch(() => { @@ -116,14 +113,14 @@ export default { </script> <template> - <li v-if="isMovedMrSidebar" class="gl-dropdown-item"> - <button type="button" class="dropdown-item" data-testid="issuable-lock" @click="toggleLocked"> + <li v-if="isMergeRequest" class="gl-dropdown-item"> + <button type="button" class="dropdown-item" @click="toggleLocked"> <span class="gl-dropdown-item-text-wrapper"> <template v-if="isLocked"> - {{ sprintf(__('Unlock %{issuableType}'), { issuableType: issuableDisplayName }) }} + {{ __('Unlock merge request') }} </template> <template v-else> - {{ sprintf(__('Lock %{issuableType}'), { issuableType: issuableDisplayName }) }} + {{ __('Lock merge request') }} </template> </span> </button> diff --git a/app/assets/javascripts/sidebar/components/subscriptions/sidebar_subscriptions_widget.vue b/app/assets/javascripts/sidebar/components/subscriptions/sidebar_subscriptions_widget.vue index f2b960ed02c..344fa880131 100644 --- a/app/assets/javascripts/sidebar/components/subscriptions/sidebar_subscriptions_widget.vue +++ b/app/assets/javascripts/sidebar/components/subscriptions/sidebar_subscriptions_widget.vue @@ -1,7 +1,12 @@ <script> import { GlDropdownForm, GlIcon, GlLoadingIcon, GlToggle, GlTooltipDirective } from '@gitlab/ui'; import { createAlert } from '~/alert'; -import { TYPE_EPIC, WORKSPACE_GROUP, WORKSPACE_PROJECT } from '~/issues/constants'; +import { + TYPE_EPIC, + TYPE_MERGE_REQUEST, + WORKSPACE_GROUP, + WORKSPACE_PROJECT, +} from '~/issues/constants'; import { isLoggedIn } from '~/lib/utils/common_utils'; import { __, sprintf } from '~/locale'; import glFeatureFlagMixin from '~/vue_shared/mixins/gl_feature_flags_mixin'; @@ -86,8 +91,8 @@ export default { }, }, computed: { - isMovedMrSidebar() { - return this.glFeatures.movedMrSidebar; + isMergeRequest() { + return this.issuableType === TYPE_MERGE_REQUEST && this.glFeatures.movedMrSidebar; }, isLoading() { return this.$apollo.queries?.subscribed?.loading || this.loading; @@ -143,7 +148,7 @@ export default { }); } - if (this.isMovedMrSidebar) { + if (this.isMergeRequest) { toast(subscribed ? __('Notifications turned on.') : __('Notifications turned off.')); } }, @@ -182,7 +187,7 @@ export default { </script> <template> - <gl-dropdown-form v-if="isMovedMrSidebar" class="gl-dropdown-item"> + <gl-dropdown-form v-if="isMergeRequest" class="gl-dropdown-item"> <div class="gl-px-5 gl-pb-2 gl-pt-1"> <gl-toggle :value="subscribed" diff --git a/app/assets/javascripts/sidebar/mount_sidebar.js b/app/assets/javascripts/sidebar/mount_sidebar.js index 1542c2e441d..2c56dc34701 100644 --- a/app/assets/javascripts/sidebar/mount_sidebar.js +++ b/app/assets/javascripts/sidebar/mount_sidebar.js @@ -17,7 +17,6 @@ import { __ } from '~/locale'; import { apolloProvider } from '~/graphql_shared/issuable_client'; import Translate from '~/vue_shared/translate'; import UserSelect from '~/vue_shared/components/user_select/user_select.vue'; -import NewHeaderActionsPopover from '~/issues/show/components/new_header_actions_popover.vue'; import CollapsedAssigneeList from './components/assignees/collapsed_assignee_list.vue'; import SidebarAssignees from './components/assignees/sidebar_assignees.vue'; import SidebarAssigneesWidget from './components/assignees/sidebar_assignees_widget.vue'; @@ -788,21 +787,6 @@ export function mountAssigneesDropdown() { }); } -function mountNewIssuePopover() { - const el = document.querySelector('.js-sidebar-header-popover'); - - if (!el) { - return null; - } - - return new Vue({ - el, - name: 'NewHeaderActionsPopover', - render: (createElement) => - createElement(NewHeaderActionsPopover, { props: { issueType: TYPE_MERGE_REQUEST } }), - }); -} - const isAssigneesWidgetShown = (isInIssuePage() || isInDesignPage() || isInMRPage()) && gon.features.issueAssigneesWidget; @@ -830,7 +814,6 @@ export function mountSidebar(mediator, store) { mountSidebarSeverityWidget(); mountSidebarEscalationStatus(); mountMoveIssueButton(); - mountNewIssuePopover(); } export { getSidebarOptions }; diff --git a/app/assets/stylesheets/page_bundles/issuable.scss b/app/assets/stylesheets/page_bundles/issuable.scss index 1b98fd4df07..e0fb95a1359 100644 --- a/app/assets/stylesheets/page_bundles/issuable.scss +++ b/app/assets/stylesheets/page_bundles/issuable.scss @@ -165,13 +165,3 @@ border: 0; } } - -.merge-request-notification-toggle { - .gl-toggle { - @include gl-ml-auto; - } - - .gl-toggle-label { - @include gl-font-weight-normal; - } -} diff --git a/app/assets/stylesheets/pages/detail_page.scss b/app/assets/stylesheets/pages/detail_page.scss index 74f61faa9ae..de8142924f9 100644 --- a/app/assets/stylesheets/pages/detail_page.scss +++ b/app/assets/stylesheets/pages/detail_page.scss @@ -74,7 +74,3 @@ color: $gl-text-color; } } - -.new-header-popover { - z-index: 999; -} diff --git a/app/controllers/projects/incidents_controller.rb b/app/controllers/projects/incidents_controller.rb index 7121096bd77..3842a88d15b 100644 --- a/app/controllers/projects/incidents_controller.rb +++ b/app/controllers/projects/incidents_controller.rb @@ -10,7 +10,6 @@ class Projects::IncidentsController < Projects::ApplicationController push_force_frontend_feature_flag(:work_items, @project&.work_items_feature_flag_enabled?) push_force_frontend_feature_flag(:work_items_mvc, @project&.work_items_mvc_feature_flag_enabled?) push_force_frontend_feature_flag(:work_items_mvc_2, @project&.work_items_mvc_2_feature_flag_enabled?) - push_frontend_feature_flag(:moved_mr_sidebar, project) end feature_category :incident_management diff --git a/app/controllers/projects/issues_controller.rb b/app/controllers/projects/issues_controller.rb index d50f681beec..efe88d17cab 100644 --- a/app/controllers/projects/issues_controller.rb +++ b/app/controllers/projects/issues_controller.rb @@ -67,7 +67,6 @@ class Projects::IssuesController < Projects::ApplicationController push_force_frontend_feature_flag(:work_items_mvc, project&.work_items_mvc_feature_flag_enabled?) push_force_frontend_feature_flag(:work_items_mvc_2, project&.work_items_mvc_2_feature_flag_enabled?) push_frontend_feature_flag(:epic_widget_edit_confirmation, project) - push_frontend_feature_flag(:moved_mr_sidebar, project) end around_action :allow_gitaly_ref_name_caching, only: [:discussions] diff --git a/app/graphql/types/ci/job_trace_type.rb b/app/graphql/types/ci/job_trace_type.rb new file mode 100644 index 00000000000..a68e26106b8 --- /dev/null +++ b/app/graphql/types/ci/job_trace_type.rb @@ -0,0 +1,19 @@ +# frozen_string_literal: true + +# rubocop: disable Graphql/AuthorizeTypes +module Types + module Ci + class JobTraceType < BaseObject + graphql_name 'CiJobTrace' + + field :html_summary, GraphQL::Types::String, null: false, + alpha: { milestone: '15.11' }, # As we want the option to change from 10 if needed + description: "HTML summary containing the last 10 lines of the trace." + + def html_summary + object.html(last_lines: 10).html_safe + end + end + end +end +# rubocop: enable Graphql/AuthorizeTypes diff --git a/app/graphql/types/ci/job_type.rb b/app/graphql/types/ci/job_type.rb index 61f2d0cdb51..1d12c296b2e 100644 --- a/app/graphql/types/ci/job_type.rb +++ b/app/graphql/types/ci/job_type.rb @@ -101,6 +101,8 @@ module Types description: 'Short SHA1 ID of the commit.' field :stuck, GraphQL::Types::Boolean, null: false, method: :stuck?, description: 'Indicates the job is stuck.' + field :trace, Types::Ci::JobTraceType, null: true, + description: 'Trace generated by the job.' field :triggered, GraphQL::Types::Boolean, null: true, description: 'Whether the job was triggered.' field :web_path, GraphQL::Types::String, null: true, @@ -144,6 +146,10 @@ module Types end end + def trace + object.trace if object.has_trace? + end + def previous_stage_jobs_or_needs if object.scheduling_type == 'stage' Gitlab::Graphql::Lazy.with_value(previous_stage_jobs) do |jobs| diff --git a/app/helpers/issuables_helper.rb b/app/helpers/issuables_helper.rb index fc2c927a2b1..179ce01ae44 100644 --- a/app/helpers/issuables_helper.rb +++ b/app/helpers/issuables_helper.rb @@ -12,8 +12,8 @@ module IssuablesHelper end end - def sidebar_gutter_collapsed_class(is_merge_request_with_flag) - return "right-sidebar-expanded" if is_merge_request_with_flag + def sidebar_gutter_collapsed_class + return "right-sidebar-expanded" if moved_mr_sidebar_enabled? "right-sidebar-#{sidebar_gutter_collapsed? ? 'collapsed' : 'expanded'}" end diff --git a/app/helpers/issues_helper.rb b/app/helpers/issues_helper.rb index 98c378db7d3..e82f09a0a97 100644 --- a/app/helpers/issues_helper.rb +++ b/app/helpers/issues_helper.rb @@ -153,7 +153,7 @@ module IssuesHelper issue.moved_from.project.service_desk_enabled? && !issue.project.service_desk_enabled? end - def issue_header_actions_data(project, issuable, current_user, issuable_sidebar) + def issue_header_actions_data(project, issuable, current_user) new_issuable_params = { issue: {}, add_related_issue: issuable.iid } if issuable.incident? new_issuable_params[:issuable_template] = 'incident' @@ -176,8 +176,7 @@ module IssuesHelper report_abuse_path: add_category_abuse_reports_path, reported_user_id: issuable.author.id, reported_from_url: issue_url(issuable), - submit_as_spam_path: mark_as_spam_project_issue_path(project, issuable), - issuable_email_address: issuable_sidebar.nil? ? '' : issuable_sidebar[:create_note_email] + submit_as_spam_path: mark_as_spam_project_issue_path(project, issuable) } end diff --git a/app/helpers/merge_requests_helper.rb b/app/helpers/merge_requests_helper.rb index 5cacc8e2199..a36d61378a0 100644 --- a/app/helpers/merge_requests_helper.rb +++ b/app/helpers/merge_requests_helper.rb @@ -179,10 +179,6 @@ module MergeRequestsHelper end end - def moved_mr_sidebar_enabled? - Feature.enabled?(:moved_mr_sidebar, @project) - end - def diffs_tab_pane_data(project, merge_request, params) { "is-locked": merge_request.discussion_locked?, @@ -260,6 +256,10 @@ module MergeRequestsHelper _('%{author} requested to merge %{source_branch} %{copy_button} into %{target_branch} %{created_at}').html_safe % { author: link_to_author.html_safe, source_branch: merge_request_source_branch(merge_request).html_safe, copy_button: copy_button.html_safe, target_branch: target_branch.html_safe, created_at: time_ago_with_tooltip(merge_request.created_at, html_class: 'gl-display-inline-block').html_safe } end + def moved_mr_sidebar_enabled? + Feature.enabled?(:moved_mr_sidebar, @project) && defined?(@merge_request) + end + def sticky_header_data data = { iid: @merge_request.iid, diff --git a/app/helpers/nav_helper.rb b/app/helpers/nav_helper.rb index bd8627b9530..59ffe6a183e 100644 --- a/app/helpers/nav_helper.rb +++ b/app/helpers/nav_helper.rb @@ -38,7 +38,7 @@ module NavHelper end def page_gutter_class - moved_sidebar_enabled = @is_merge_request_with_flag + moved_sidebar_enabled = current_controller?('merge_requests') && moved_mr_sidebar_enabled? if (page_has_markdown? || current_path?('projects/merge_requests#diffs')) && !current_controller?('conflicts') if cookies[:collapsed_gutter] == 'true' diff --git a/app/views/projects/merge_requests/_close_reopen_draft_report_toggle.html.haml b/app/views/projects/merge_requests/_close_reopen_draft_report_toggle.html.haml index 9b6263f2145..92b0a5a0b90 100644 --- a/app/views/projects/merge_requests/_close_reopen_draft_report_toggle.html.haml +++ b/app/views/projects/merge_requests/_close_reopen_draft_report_toggle.html.haml @@ -1,8 +1,7 @@ - display_issuable_type = issuable_display_type(@merge_request) .btn-group.gl-md-ml-3.gl-display-flex.dropdown.gl-dropdown.gl-md-w-auto.gl-w-full - %span.js-sidebar-header-popover - = button_tag type: 'button', id: "new-actions-header-dropdown", class: "btn dropdown-toggle btn-default btn-md gl-button gl-dropdown-toggle btn-default-tertiary dropdown-icon-only dropdown-toggle-no-caret has-tooltip gl-display-none! gl-md-display-inline-flex! gl-rounded-base!", data: { toggle: 'dropdown', title: _('Merge request actions'), testid: 'merge-request-actions', 'aria-label': _('Merge request actions') } do + = button_tag type: 'button', class: "btn dropdown-toggle btn-default btn-md gl-button gl-dropdown-toggle btn-default-tertiary dropdown-icon-only dropdown-toggle-no-caret has-tooltip gl-display-none! gl-md-display-inline-flex!", data: { toggle: 'dropdown', title: _('Merge request actions'), testid: 'merge-request-actions', 'aria-label': _('Merge request actions') } do = sprite_icon "ellipsis_v", size: 16, css_class: "dropdown-icon gl-icon" = button_tag type: 'button', class: "btn dropdown-toggle btn-default btn-md btn-block gl-button gl-dropdown-toggle gl-md-display-none!", data: { 'toggle' => 'dropdown' } do %span.gl-dropdown-button-text= _('Merge request actions') diff --git a/app/views/projects/merge_requests/creations/_new_submit.html.haml b/app/views/projects/merge_requests/creations/_new_submit.html.haml index 5b12ce7b28d..b6b4d15564b 100644 --- a/app/views/projects/merge_requests/creations/_new_submit.html.haml +++ b/app/views/projects/merge_requests/creations/_new_submit.html.haml @@ -10,12 +10,24 @@ - if params[:nav_source].present? = hidden_field_tag(:nav_source, params[:nav_source]) -.mr-compare.merge-request.js-merge-request-new-submit{ 'data-mr-submit-action': "#{j params[:tab].presence || 'new'}" } +.mr-compare.merge-request.js-merge-request-new-submit.gl-mt-5{ 'data-mr-submit-action': "#{j params[:tab].presence || 'new'}" } - if @commits.empty? - .commits-empty - %h4 - = _("There are no commits yet.") - = custom_icon ('illustration_no_commits') + .merge-request-tabs-holder{ class: ("js-tabs-affix" unless ENV['RAILS_ENV'] == 'test') } + .merge-request-tabs-container.gl-display-flex.gl-justify-content-space-between + .scrolling-tabs-container.inner-page-scroll-tabs.is-smaller + .fade-left= sprite_icon('chevron-lg-left', size: 12) + .fade-right= sprite_icon('chevron-lg-right', size: 12) + %ul.merge-request-tabs.nav.nav-tabs.nav-links.no-top.no-bottom.gl-display-flex.gl-flex-wrap-nowrap.gl-m-0.gl-p-0.js-tabs-affix + %li.commits-tab.new-tab + = link_to url_for(safe_params), data: {target: 'div#commits', action: 'new', toggle: 'tabvue'} do + = _("Commits") + = gl_badge_tag @total_commit_count, { size: :sm }, { class: 'gl-tab-counter-badge' } + + #diff-notes-app.tab-content + #new.commits.tab-pane.active + .commits-empty.gl-text-left.gl-my-5.gl-text-gray-500 + %p + = _("There are no commits yet.") - else .merge-request-tabs-holder{ class: ("js-tabs-affix" unless ENV['RAILS_ENV'] == 'test') } .merge-request-tabs-container.gl-display-flex.gl-justify-content-space-between diff --git a/app/views/shared/issuable/_sidebar.html.haml b/app/views/shared/issuable/_sidebar.html.haml index 82e95a6a8e8..f54354674e2 100644 --- a/app/views/shared/issuable/_sidebar.html.haml +++ b/app/views/shared/issuable/_sidebar.html.haml @@ -9,15 +9,14 @@ - reviewers = local_assigns.fetch(:reviewers, nil) - in_group_context_with_iterations = @project.group.present? && issuable_sidebar[:supports_iterations] - is_merge_request = issuable_type === 'merge_request' -- moved_sidebar_enabled = moved_mr_sidebar_enabled? -- is_merge_request_with_flag = is_merge_request && moved_sidebar_enabled +- moved_sidebar_enabled = moved_mr_sidebar_enabled? && is_merge_request -%aside.right-sidebar.js-right-sidebar.js-issuable-sidebar{ data: { signed: { in: signed_in }, issuable_type: issuable_type }, class: "#{sidebar_gutter_collapsed_class(is_merge_request_with_flag)} #{'right-sidebar-merge-requests' if is_merge_request_with_flag}", 'aria-live' => 'polite', 'aria-label': issuable_type } - .issuable-sidebar{ class: "#{'is-merge-request' if is_merge_request_with_flag}" } - .issuable-sidebar-header{ class: "#{'gl-pb-2! gl-md-display-flex gl-justify-content-end gl-lg-display-none!' if is_merge_request_with_flag}" } +%aside.right-sidebar.js-right-sidebar.js-issuable-sidebar{ data: { signed: { in: signed_in }, issuable_type: issuable_type }, class: "#{sidebar_gutter_collapsed_class} #{'right-sidebar-merge-requests' if moved_sidebar_enabled}", 'aria-live' => 'polite', 'aria-label': issuable_type } + .issuable-sidebar{ class: "#{'is-merge-request' if moved_sidebar_enabled}" } + .issuable-sidebar-header{ class: "#{'gl-pb-2! gl-md-display-flex gl-justify-content-end gl-lg-display-none!' if moved_sidebar_enabled}" } %button.btn.gl-button.gutter-toggle.float-right.js-sidebar-toggle.has-tooltip{ type: "reset", class: "gl-shadow-none! #{'gl-display-block' if moved_sidebar_enabled}", "aria-label" => _('Toggle sidebar'), title: sidebar_gutter_tooltip_text, data: { container: 'body', placement: 'left', boundary: 'viewport' } } = sidebar_gutter_toggle_icon - - if signed_in && !is_merge_request_with_flag + - if signed_in && !moved_sidebar_enabled .js-sidebar-todo-widget-root{ data: { project_path: issuable_sidebar[:project_full_path], iid: issuable_sidebar[:iid], id: issuable_sidebar[:id] } } = form_for issuable_type, url: issuable_sidebar[:issuable_json_path], remote: true, html: { class: 'issuable-context-form inline-update js-issuable-update' } do |f| @@ -82,17 +81,17 @@ .js-sidebar-participants-widget-root - - if !moved_sidebar_enabled - .block.with-sub-blocks + .block.with-sub-blocks + - if !moved_sidebar_enabled .js-sidebar-reference-widget-root - - if is_merge_request && !moved_sidebar_enabled - .sub-block.js-sidebar-source-branch - .sidebar-collapsed-icon.js-dont-change-state - = clipboard_button(text: source_branch, title: _('Copy branch name'), placement: "left", boundary: 'viewport', class: 'btn-clipboard gl-button btn-default-tertiary btn-icon btn-sm js-source-branch-copy') - .gl-display-flex.gl-align-items-center.gl-justify-content-space-between.gl-mb-2.hide-collapsed - %span.gl-overflow-hidden.gl-text-overflow-ellipsis.gl-white-space-nowrap - = _('Source branch: %{source_branch_open}%{source_branch}%{source_branch_close}').html_safe % { source_branch_open: "<span class='gl-font-monospace' data-testid='ref-name' title='#{html_escape(source_branch)}'>".html_safe, source_branch_close: "</span>".html_safe, source_branch: html_escape(source_branch) } - = clipboard_button(text: source_branch, title: _('Copy branch name'), placement: "left", boundary: 'viewport', class: 'btn-clipboard gl-button btn-default-tertiary btn-icon btn-sm js-source-branch-copy') + - if issuable_type == 'merge_request' && !moved_sidebar_enabled + .sub-block.js-sidebar-source-branch + .sidebar-collapsed-icon.js-dont-change-state + = clipboard_button(text: source_branch, title: _('Copy branch name'), placement: "left", boundary: 'viewport', class: 'btn-clipboard gl-button btn-default-tertiary btn-icon btn-sm js-source-branch-copy') + .gl-display-flex.gl-align-items-center.gl-justify-content-space-between.gl-mb-2.hide-collapsed + %span.gl-overflow-hidden.gl-text-overflow-ellipsis.gl-white-space-nowrap + = _('Source branch: %{source_branch_open}%{source_branch}%{source_branch_close}').html_safe % { source_branch_open: "<span class='gl-font-monospace' data-testid='ref-name' title='#{html_escape(source_branch)}'>".html_safe, source_branch_close: "</span>".html_safe, source_branch: html_escape(source_branch) } + = clipboard_button(text: source_branch, title: _('Copy branch name'), placement: "left", boundary: 'viewport', class: 'btn-clipboard gl-button btn-default-tertiary btn-icon btn-sm js-source-branch-copy') - if show_forwarding_email .block diff --git a/app/views/shared/issue_type/_details_header.html.haml b/app/views/shared/issue_type/_details_header.html.haml index 0326f35a12b..ccb501dae11 100644 --- a/app/views/shared/issue_type/_details_header.html.haml +++ b/app/views/shared/issue_type/_details_header.html.haml @@ -19,4 +19,4 @@ %a.btn.gl-button.btn-default.btn-icon.float-right.gl-display-block.d-sm-none.gutter-toggle.issuable-gutter-toggle.js-sidebar-toggle{ href: "#" } = sprite_icon('chevron-double-lg-left') - .js-issue-header-actions{ data: issue_header_actions_data(@project, issuable, current_user, @issuable_sidebar) } + .js-issue-header-actions{ data: issue_header_actions_data(@project, issuable, current_user) } diff --git a/app/views/shared/milestones/_sidebar.html.haml b/app/views/shared/milestones/_sidebar.html.haml index 5477b9395ea..cc1965945ac 100644 --- a/app/views/shared/milestones/_sidebar.html.haml +++ b/app/views/shared/milestones/_sidebar.html.haml @@ -1,7 +1,7 @@ - affix_offset = local_assigns.fetch(:affix_offset, "50") - project = local_assigns[:project] -%aside.right-sidebar.js-right-sidebar{ data: { "offset-top" => affix_offset, "spy" => "affix", "always-show-toggle" => true }, class: sidebar_gutter_collapsed_class(false), 'aria-live' => 'polite', 'aria-label': _('Milestone') } +%aside.right-sidebar.js-right-sidebar{ data: { "offset-top" => affix_offset, "spy" => "affix", "always-show-toggle" => true }, class: sidebar_gutter_collapsed_class, 'aria-live' => 'polite', 'aria-label': _('Milestone') } .issuable-sidebar.milestone-sidebar .block.milestone-progress.issuable-sidebar-header %a.gutter-toggle.float-right.js-sidebar-toggle.has-tooltip{ role: "button", href: "#", "aria-label" => s_('MilestoneSidebar|Toggle sidebar'), title: sidebar_gutter_tooltip_text, data: { container: 'body', placement: 'left', boundary: 'viewport' } } diff --git a/app/views/shared/notes/_edit_form.html.haml b/app/views/shared/notes/_edit_form.html.haml index cbf0b6f1051..72081856da6 100644 --- a/app/views/shared/notes/_edit_form.html.haml +++ b/app/views/shared/notes/_edit_form.html.haml @@ -9,6 +9,7 @@ .note-form-actions.clearfix .settings-message.note-edit-warning.js-finish-edit-warning = _("Finish editing this message first!") - = submit_tag _('Save comment'), class: 'gl-button btn btn-confirm js-comment-save-button', data: { qa_selector: 'save_comment_button' } + = render Pajamas::ButtonComponent.new(type: 'submit', variant: :confirm, button_options: { class: 'js-comment-save-button', data: { qa_selector: 'save_comment_button' } }) do + = _("Save comment") = render Pajamas::ButtonComponent.new(button_options: { class: 'note-edit-cancel' }) do = _("Cancel") diff --git a/doc/administration/geo/disaster_recovery/runbooks/planned_failover_multi_node.md b/doc/administration/geo/disaster_recovery/runbooks/planned_failover_multi_node.md index cef0101dd40..5480775a683 100644 --- a/doc/administration/geo/disaster_recovery/runbooks/planned_failover_multi_node.md +++ b/doc/administration/geo/disaster_recovery/runbooks/planned_failover_multi_node.md @@ -6,7 +6,7 @@ type: howto --- WARNING: -This runbook is in [**Alpha**](../../../../policy/alpha-beta-support.md#alpha-features). For complete, production-ready documentation, see the +This runbook is in [**Alpha**](../../../../policy/alpha-beta-support.md#experiment). For complete, production-ready documentation, see the [disaster recovery documentation](../index.md). # Disaster Recovery (Geo) promotion runbooks **(PREMIUM SELF)** diff --git a/doc/administration/geo/disaster_recovery/runbooks/planned_failover_single_node.md b/doc/administration/geo/disaster_recovery/runbooks/planned_failover_single_node.md index 085765ec51e..1e8dde87239 100644 --- a/doc/administration/geo/disaster_recovery/runbooks/planned_failover_single_node.md +++ b/doc/administration/geo/disaster_recovery/runbooks/planned_failover_single_node.md @@ -6,7 +6,7 @@ type: howto --- WARNING: -This runbook is in [**Alpha**](../../../../policy/alpha-beta-support.md#alpha-features). For complete, production-ready documentation, see the +This runbook is in [**Alpha**](../../../../policy/alpha-beta-support.md#experiment). For complete, production-ready documentation, see the [disaster recovery documentation](../index.md). # Disaster Recovery (Geo) promotion runbooks **(PREMIUM SELF)** diff --git a/doc/administration/gitaly/recovery.md b/doc/administration/gitaly/recovery.md index 331f9b5a956..7d27a633512 100644 --- a/doc/administration/gitaly/recovery.md +++ b/doc/administration/gitaly/recovery.md @@ -100,7 +100,7 @@ The following parameters are available: some assigned copies that are not available. NOTE: -`dataloss` is still in [Beta](../../policy/alpha-beta-support.md#beta-features) and the output format is subject to change. +`dataloss` is still in [Beta](../../policy/alpha-beta-support.md#beta) and the output format is subject to change. To check for repositories with outdated primaries or for unavailable repositories, run: diff --git a/doc/administration/operations/puma.md b/doc/administration/operations/puma.md index f2f9f1cdcda..eea391e56c4 100644 --- a/doc/administration/operations/puma.md +++ b/doc/administration/operations/puma.md @@ -99,7 +99,7 @@ To change the worker timeout to 600 seconds: ## Disable Puma clustered mode in memory-constrained environments WARNING: -This is an experimental [Alpha feature](../../policy/alpha-beta-support.md#alpha-features) and subject to change without notice. The feature +This is an experimental [Alpha feature](../../policy/alpha-beta-support.md#experiment) and subject to change without notice. The feature is not ready for production use. If you want to use this feature, you should test outside of production first. See the [known issues](#puma-single-mode-known-issues) for additional details. diff --git a/doc/administration/postgresql/multiple_databases.md b/doc/administration/postgresql/multiple_databases.md index 188578a739c..af76c03492d 100644 --- a/doc/administration/postgresql/multiple_databases.md +++ b/doc/administration/postgresql/multiple_databases.md @@ -15,7 +15,7 @@ By default, GitLab uses a single application database, referred to as the `main` To scale GitLab, you can configure GitLab to use multiple application databases. -Due to [known issues](#known-issues), configuring GitLab with multiple databases is in [**Alpha**](../../policy/alpha-beta-support.md#alpha-features). +Due to [known issues](#known-issues), configuring GitLab with multiple databases is in [**Alpha**](../../policy/alpha-beta-support.md#experiment). After you have set up multiple databases, GitLab uses a second application database for [CI/CD features](../../ci/index.md), referred to as the `ci` database. diff --git a/doc/api/dependencies.md b/doc/api/dependencies.md index b99d9e2d91d..651c5b74503 100644 --- a/doc/api/dependencies.md +++ b/doc/api/dependencies.md @@ -7,7 +7,7 @@ info: To determine the technical writer assigned to the Stage/Group associated w # Dependencies API **(ULTIMATE)** WARNING: -This API is in an [Alpha](../policy/alpha-beta-support.md#alpha-features) stage and considered unstable. +This API is in an [Alpha](../policy/alpha-beta-support.md#experiment) stage and considered unstable. The response payload may be subject to change or breakage across GitLab releases. diff --git a/doc/api/graphql/reference/index.md b/doc/api/graphql/reference/index.md index 18162ad8d87..a046c09c8c2 100644 --- a/doc/api/graphql/reference/index.md +++ b/doc/api/graphql/reference/index.md @@ -946,6 +946,28 @@ Input type: `AdminSidekiqQueuesDeleteJobsInput` | <a id="mutationadminsidekiqqueuesdeletejobserrors"></a>`errors` | [`[String!]!`](#string) | Errors encountered during execution of the mutation. | | <a id="mutationadminsidekiqqueuesdeletejobsresult"></a>`result` | [`DeleteJobsResponse`](#deletejobsresponse) | Information about the status of the deletion request. | +### `Mutation.aiAction` + +WARNING: +**Introduced** in 15.11. +This feature is in Alpha. It can be changed or removed at any time. + +Input type: `AiActionInput` + +#### Arguments + +| Name | Type | Description | +| ---- | ---- | ----------- | +| <a id="mutationaiactionclientmutationid"></a>`clientMutationId` | [`String`](#string) | A unique identifier for the client performing the mutation. | +| <a id="mutationaiactionsummarizecomments"></a>`summarizeComments` | [`AiSummarizeCommentsInput`](#aisummarizecommentsinput) | Input for summarize_comments AI action. | + +#### Fields + +| Name | Type | Description | +| ---- | ---- | ----------- | +| <a id="mutationaiactionclientmutationid"></a>`clientMutationId` | [`String`](#string) | A unique identifier for the client performing the mutation. | +| <a id="mutationaiactionerrors"></a>`errors` | [`[String!]!`](#string) | Errors encountered during execution of the mutation. | + ### `Mutation.alertSetAssignees` Input type: `AlertSetAssigneesInput` @@ -11115,6 +11137,15 @@ Information about a connected Agent. | <a id="agentmetadatapodnamespace"></a>`podNamespace` | [`String`](#string) | Namespace of the pod running the Agent. | | <a id="agentmetadataversion"></a>`version` | [`String`](#string) | Agent version tag. | +### `AiResponse` + +#### Fields + +| Name | Type | Description | +| ---- | ---- | ----------- | +| <a id="airesponseerrors"></a>`errors` | [`[String!]`](#string) | Errors return by AI API as response. | +| <a id="airesponseresponsebody"></a>`responseBody` | [`String`](#string) | Response body from AI API. | + ### `AlertManagementAlert` Describes an alert from the project's Alert Management. @@ -11960,6 +11991,7 @@ CI/CD variables for a GitLab instance. | <a id="cijobstatus"></a>`status` | [`CiJobStatus`](#cijobstatus) | Status of the job. | | <a id="cijobstuck"></a>`stuck` | [`Boolean!`](#boolean) | Indicates the job is stuck. | | <a id="cijobtags"></a>`tags` | [`[String!]`](#string) | Tags for the current job. | +| <a id="cijobtrace"></a>`trace` | [`CiJobTrace`](#cijobtrace) | Trace generated by the job. | | <a id="cijobtriggered"></a>`triggered` | [`Boolean`](#boolean) | Whether the job was triggered. | | <a id="cijobuserpermissions"></a>`userPermissions` | [`JobPermissions!`](#jobpermissions) | Permissions for the current user on the resource. | | <a id="cijobwebpath"></a>`webPath` | [`String`](#string) | Web path of the job. | @@ -11987,6 +12019,14 @@ CI/CD variables for a GitLab instance. | <a id="cijobtokenscopetypeoutboundallowlist"></a>`outboundAllowlist` | [`ProjectConnection!`](#projectconnection) | Allow list of projects that are accessible using the current project's CI Job tokens. (see [Connections](#connections)) | | <a id="cijobtokenscopetypeprojects"></a>`projects` **{warning-solid}** | [`ProjectConnection!`](#projectconnection) | **Deprecated** in 15.9. The `projects` attribute is being deprecated. Use `outbound_allowlist`. | +### `CiJobTrace` + +#### Fields + +| Name | Type | Description | +| ---- | ---- | ----------- | +| <a id="cijobtracehtmlsummary"></a>`htmlSummary` **{warning-solid}** | [`String!`](#string) | **Introduced** in 15.11. This feature is in Alpha. It can be changed or removed at any time. HTML summary containing the last 10 lines of the trace. | + ### `CiJobsDurationStatistics` Representation of duration statistics for a group of CI jobs. @@ -25061,6 +25101,12 @@ A `AchievementsUserAchievementID` is a global ID. It is encoded as a string. An example `AchievementsUserAchievementID` is: `"gid://gitlab/Achievements::UserAchievement/1"`. +### `AiModelID` + +A `AiModelID` is a global ID. It is encoded as a string. + +An example `AiModelID` is: `"gid://gitlab/Ai::Model/1"`. + ### `AlertManagementAlertID` A `AlertManagementAlertID` is a global ID. It is encoded as a string. @@ -26426,6 +26472,14 @@ be used as arguments). Only general use input types are listed here. For mutation input types, see the associated mutation type above. +### `AiSummarizeCommentsInput` + +#### Arguments + +| Name | Type | Description | +| ---- | ---- | ----------- | +| <a id="aisummarizecommentsinputresourceid"></a>`resourceId` | [`AiModelID!`](#aimodelid) | GID of the resource to mutate. | + ### `AlertManagementPayloadAlertFieldInput` Field that are available while modifying the custom mapping attributes for an HTTP integration. diff --git a/doc/api/project_import_export.md b/doc/api/project_import_export.md index 9728332f8f8..22df2b2ef4a 100644 --- a/doc/api/project_import_export.md +++ b/doc/api/project_import_export.md @@ -203,7 +203,7 @@ As an administrator, you can modify the maximum import file size. To do so, use ## Import a file from a remote object storage (Beta) -> [Introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/282503) in GitLab 13.12 in [Beta](../policy/alpha-beta-support.md#beta-features) [with a flag](../administration/feature_flags.md) named `import_project_from_remote_file`. Enabled by default. +> [Introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/282503) in GitLab 13.12 in [Beta](../policy/alpha-beta-support.md#beta) [with a flag](../administration/feature_flags.md) named `import_project_from_remote_file`. Enabled by default. FLAG: On self-managed GitLab, by default this feature is available. To hide the feature, ask an administrator to [disable the feature flag](../administration/feature_flags.md) named `import_project_from_remote_file`. diff --git a/doc/api/vulnerability_exports.md b/doc/api/vulnerability_exports.md index e1473ba68b6..7084de09f61 100644 --- a/doc/api/vulnerability_exports.md +++ b/doc/api/vulnerability_exports.md @@ -9,7 +9,7 @@ info: To determine the technical writer assigned to the Stage/Group associated w > [Introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/197494) in GitLab 12.10. [Updated](https://gitlab.com/gitlab-org/gitlab/-/merge_requests/30397) in GitLab 13.0. WARNING: -This API is in an [Alpha](../policy/alpha-beta-support.md#alpha-features) stage and considered unstable. +This API is in an [Alpha](../policy/alpha-beta-support.md#experiment) stage and considered unstable. The response payload may be subject to change or breakage across GitLab releases. diff --git a/doc/ci/cloud_services/google_cloud/index.md b/doc/ci/cloud_services/google_cloud/index.md index bcb2681403a..97ea63f57e7 100644 --- a/doc/ci/cloud_services/google_cloud/index.md +++ b/doc/ci/cloud_services/google_cloud/index.md @@ -7,7 +7,7 @@ info: To determine the technical writer assigned to the Stage/Group associated w # Configure OpenID Connect with GCP Workload Identity Federation **(FREE)** WARNING: -The `CI_JOB_JWT_V2` variable is under development [(alpha)](../../../policy/alpha-beta-support.md#alpha-features) and is not yet suitable for production use. +The `CI_JOB_JWT_V2` variable is under development [(alpha)](../../../policy/alpha-beta-support.md#experiment) and is not yet suitable for production use. This tutorial demonstrates authenticating to Google Cloud from a GitLab CI/CD job using a JSON Web Token (JWT) token and Workload Identity Federation. This configuration diff --git a/doc/ci/directed_acyclic_graph/index.md b/doc/ci/directed_acyclic_graph/index.md index 7c741ef3842..f0384fb29c7 100644 --- a/doc/ci/directed_acyclic_graph/index.md +++ b/doc/ci/directed_acyclic_graph/index.md @@ -81,7 +81,7 @@ are certain use cases that you may need to work around. For more information, ch ## Needs Visualization -> - [Introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/215517) in GitLab 13.1 as a [Beta feature](../../policy/alpha-beta-support.md#beta-features). +> - [Introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/215517) in GitLab 13.1 as a [Beta feature](../../policy/alpha-beta-support.md#beta). > - It became a [standard feature](https://gitlab.com/gitlab-org/gitlab/-/merge_requests/38517) in 13.3. > - [Feature flag removed](https://gitlab.com/gitlab-org/gitlab/-/merge_requests/52208) in GitLab 13.9. diff --git a/doc/ci/migration/circleci.md b/doc/ci/migration/circleci.md index 64f6866a3a4..b50695e8e50 100644 --- a/doc/ci/migration/circleci.md +++ b/doc/ci/migration/circleci.md @@ -291,8 +291,8 @@ Self-managed runners: GitLab.com shared runners: - Linux -- [Windows](../runners/saas/windows_saas_runner.md) ([Beta](../../policy/alpha-beta-support.md#beta-features)). -- [macOS](../runners/saas/macos_saas_runner.md) ([Beta](../../policy/alpha-beta-support.md#beta-features)). +- [Windows](../runners/saas/windows_saas_runner.md) ([Beta](../../policy/alpha-beta-support.md#beta)). +- [macOS](../runners/saas/macos_saas_runner.md) ([Beta](../../policy/alpha-beta-support.md#beta)). ### Machine and specific build environments diff --git a/doc/ci/runners/index.md b/doc/ci/runners/index.md index d3bbd7d8816..09525955a02 100644 --- a/doc/ci/runners/index.md +++ b/doc/ci/runners/index.md @@ -11,8 +11,8 @@ If you use GitLab SaaS (GitLab.com), your [untagged](../../ci/runners/configure_ As long as shared runners are enabled for your project, no configuration is required. Your jobs can run on: - [Linux runners](saas/linux_saas_runner.md). -- [Windows runners](saas/windows_saas_runner.md) ([Beta](../../policy/alpha-beta-support.md#beta-features)). -- [macOS runners](saas/macos_saas_runner.md) ([Beta](../../policy/alpha-beta-support.md#beta-features)). +- [Windows runners](saas/windows_saas_runner.md) ([Beta](../../policy/alpha-beta-support.md#beta)). +- [macOS runners](saas/macos_saas_runner.md) ([Beta](../../policy/alpha-beta-support.md#beta)). The number of minutes you can use on these runners depends on the [maximum number of CI/CD minutes](../pipelines/cicd_minutes.md) diff --git a/doc/ci/runners/saas/macos_saas_runner.md b/doc/ci/runners/saas/macos_saas_runner.md index 21120732fbe..20be2f2a147 100644 --- a/doc/ci/runners/saas/macos_saas_runner.md +++ b/doc/ci/runners/saas/macos_saas_runner.md @@ -6,7 +6,7 @@ info: To determine the technical writer assigned to the Stage/Group associated w # SaaS runners on macOS (Beta) **(PREMIUM SAAS)** -SaaS runners on macOS are in [Beta](../../../policy/alpha-beta-support.md#beta-features) for approved open source programs and customers in Premium and Ultimate plans. +SaaS runners on macOS are in [Beta](../../../policy/alpha-beta-support.md#beta) for approved open source programs and customers in Premium and Ultimate plans. SaaS runners on macOS provide an on-demand macOS build environment integrated with GitLab SaaS [CI/CD](../../../ci/index.md). diff --git a/doc/ci/runners/saas/windows_saas_runner.md b/doc/ci/runners/saas/windows_saas_runner.md index 2c6540833b0..9f58c905c62 100644 --- a/doc/ci/runners/saas/windows_saas_runner.md +++ b/doc/ci/runners/saas/windows_saas_runner.md @@ -6,7 +6,7 @@ info: To determine the technical writer assigned to the Stage/Group associated w # SaaS runners on Windows (beta) **(FREE SAAS)** -SaaS runners on Windows are in [beta](../../../policy/alpha-beta-support.md#beta-features) +SaaS runners on Windows are in [beta](../../../policy/alpha-beta-support.md#beta) and shouldn't be used for production workloads. During this beta period, the [shared runner quota for CI/CD minutes](../../pipelines/cicd_minutes.md) @@ -126,7 +126,7 @@ test: ## Limitations and known issues -- All the limitations mentioned in our [beta definition](../../../policy/alpha-beta-support.md#beta-features). +- All the limitations mentioned in our [beta definition](../../../policy/alpha-beta-support.md#beta). - The average provisioning time for a new Windows VM is 5 minutes. This means that you may notice slower build start times on the Windows runner fleet during the beta. In a future diff --git a/doc/development/api_graphql_styleguide.md b/doc/development/api_graphql_styleguide.md index efcda1f8c36..426a235823f 100644 --- a/doc/development/api_graphql_styleguide.md +++ b/doc/development/api_graphql_styleguide.md @@ -792,7 +792,7 @@ The documentation mentions that the old Global ID style is now deprecated. ## Mark schema items as Alpha You can mark GraphQL schema items (fields, arguments, enum values, and mutations) as -[Alpha](../policy/alpha-beta-support.md#alpha-features). +[Alpha](../policy/alpha-beta-support.md#experiment). An item marked as Alpha is [exempt from the deprecation process](#breaking-change-exemptions) and can be removed at any time without notice. Mark an item as Alpha when it is diff --git a/doc/development/contributing/design.md b/doc/development/contributing/design.md index 210370f9816..7cd220c606c 100644 --- a/doc/development/contributing/design.md +++ b/doc/development/contributing/design.md @@ -73,7 +73,7 @@ Check visual design properties using your browser's _elements inspector_ ([Chrom guidelines. - _Optionally_ consider [dark mode](../../user/profile/preferences.md#dark-mode). [^1] - [^1]: You're not required to design for [dark mode](../../user/profile/preferences.md#dark-mode) while the feature is in [alpha](../../policy/alpha-beta-support.md#alpha-features). The [UX Foundations team](https://about.gitlab.com/direction/manage/foundations/) plans to improve the dark mode in the future. Until we integrate [Pajamas](https://design.gitlab.com/) components into the product and the underlying design strategy is in place to support dark mode, we cannot guarantee that we won't introduce bugs and debt to this mode. At your discretion, evaluate the need to create dark mode patches. + [^1]: You're not required to design for [dark mode](../../user/profile/preferences.md#dark-mode) while the feature is in [alpha](../../policy/alpha-beta-support.md#experiment). The [UX Foundations team](https://about.gitlab.com/direction/manage/foundations/) plans to improve the dark mode in the future. Until we integrate [Pajamas](https://design.gitlab.com/) components into the product and the underlying design strategy is in place to support dark mode, we cannot guarantee that we won't introduce bugs and debt to this mode. At your discretion, evaluate the need to create dark mode patches. ### States diff --git a/doc/development/documentation/styleguide/word_list.md b/doc/development/documentation/styleguide/word_list.md index 0459c7caa58..8cf66c68935 100644 --- a/doc/development/documentation/styleguide/word_list.md +++ b/doc/development/documentation/styleguide/word_list.md @@ -153,7 +153,7 @@ This phrasing is more active and is from the user perspective, rather than the p Use uppercase for **Alpha**. For example: **The XYZ feature is in Alpha.** or **This Alpha release is ready to test.** -You might also want to link to [this section](../../../policy/alpha-beta-support.md#alpha-features) +You might also want to link to [this section](../../../policy/alpha-beta-support.md#experiment) in the handbook when writing about Alpha features. ## analytics @@ -214,7 +214,7 @@ Try to avoid **below** when referring to an example or table in a documentation Use uppercase for **Beta**. For example: **The XYZ feature is in Beta.** or **This Beta release is ready to test.** -You might also want to link to [this section](../../../policy/alpha-beta-support.md#beta-features) +You might also want to link to [this section](../../../policy/alpha-beta-support.md#beta) in the handbook when writing about Beta features. ## blacklist diff --git a/doc/development/fe_guide/customizable_dashboards.md b/doc/development/fe_guide/customizable_dashboards.md index 26c73b26126..7b9edcfa659 100644 --- a/doc/development/fe_guide/customizable_dashboards.md +++ b/doc/development/fe_guide/customizable_dashboards.md @@ -6,7 +6,7 @@ info: To determine the technical writer assigned to the Stage/Group associated w # Customizable dashboards -> [Introduced](https://gitlab.com/gitlab-org/gitlab/-/merge_requests/98610) in GitLab 15.5 as an [Alpha feature](../../policy/alpha-beta-support.md#alpha-features). +> [Introduced](https://gitlab.com/gitlab-org/gitlab/-/merge_requests/98610) in GitLab 15.5 as an [Alpha feature](../../policy/alpha-beta-support.md#experiment). Customizable dashboards provide a dashboard structure that allows users to create their own dashboards and commit the structure to a repository. diff --git a/doc/install/aws/gitlab_hybrid_on_aws.md b/doc/install/aws/gitlab_hybrid_on_aws.md index b8c840782b1..e4eb0117410 100644 --- a/doc/install/aws/gitlab_hybrid_on_aws.md +++ b/doc/install/aws/gitlab_hybrid_on_aws.md @@ -48,7 +48,7 @@ The Beta version deploys Aurora PostgreSQL, but the release version will deploy | ------------------------------------------------------------ | ------------------------------------------------------------ | ------------------------------------------------------------ | | Overview and Vision | [AWS Quick Start](https://aws.amazon.com/solutions/implementations/amazon-eks/) | [GitLab Environment Toolkit](https://gitlab.com/gitlab-org/gitlab-environment-toolkit/-/blob/main/README.md) | | Licensing | [Open Source (Apache 2.0)](https://github.com/aws-quickstart/quickstart-eks-gitlab/blob/main/LICENSE.txt) | [GitLab Enterprise Edition license](https://gitlab.com/gitlab-org/gitlab-environment-toolkit/-/blob/main/LICENSE) ([GitLab Premium tier](https://gitlab.com/gitlab-org/gitlab-environment-toolkit/-/blob/main/README.md)) | -| GitLab Support | [GitLab Beta Support](../../policy/alpha-beta-support.md#beta-features) | [GitLab GA Support](../../policy/alpha-beta-support.md#generally-available-ga) | +| GitLab Support | [GitLab Beta Support](../../policy/alpha-beta-support.md#beta) | [GitLab GA Support](../../policy/alpha-beta-support.md#generally-available-ga) | | GitLab Reference Architecture Compliant | Yes | Yes | | GitLab Performance Tool (GPT) Tested | Yes | Yes | | Amazon Well Architected Compliant | Yes<br />(via Quick Start program) | Critical portions <br />reviewed by AWS | diff --git a/doc/operations/incident_management/manage_incidents.md b/doc/operations/incident_management/manage_incidents.md index 9d0c8075ff9..338dacda166 100644 --- a/doc/operations/incident_management/manage_incidents.md +++ b/doc/operations/incident_management/manage_incidents.md @@ -226,10 +226,6 @@ When you close an incident that is linked to an [alert](alerts.md), the linked alert's status changes to **Resolved**. You are then credited with the alert's status change. -<!-- Delete when the `moved_mr_sidebar` feature flag is removed --> -If you don't see this action at the top of an incident, your project or instance might have -enabled a feature flag for [moved actions](../../user/project/merge_requests/index.md#move-sidebar-actions) - ### Automatically close incidents via recovery alerts > [Introduced for HTTP integrations](https://gitlab.com/gitlab-org/gitlab/-/issues/13402) in GitLab 13.4. @@ -253,22 +249,6 @@ When GitLab receives a recovery alert, it closes the associated incident. This action is recorded as a system note on the incident indicating that it was closed automatically by the GitLab Alert bot. -## Delete an incident - -Prerequisites: - -- You must have the Owner role for a project. - -To delete an incident: - -1. In an incident, select **Incident actions** (**{ellipsis_v}**). -1. Select **Delete incident**. - -Alternatively: - -1. In an incident, select **Edit title and description** (**{pencil}**). -1. Select **Delete incident**. - ## Other actions Because incidents in GitLab are built on top of [issues](../../user/project/issues/index.md), diff --git a/doc/operations/incident_management/slack.md b/doc/operations/incident_management/slack.md index 68c6804f947..a6f79320630 100644 --- a/doc/operations/incident_management/slack.md +++ b/doc/operations/incident_management/slack.md @@ -7,7 +7,7 @@ info: To determine the technical writer assigned to the Stage/Group associated w # Incident management for Slack (Beta) **(FREE SAAS)** > - [Introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/344856) in GitLab 15.7 [with a flag](../../administration/feature_flags.md) named `incident_declare_slash_command`. Disabled by default. -> - [Enabled on GitLab.com](https://gitlab.com/gitlab-org/gitlab/-/issues/378072) in GitLab 15.10 in [Open Beta](../../policy/alpha-beta-support.md#open-beta-features). +> - [Enabled on GitLab.com](https://gitlab.com/gitlab-org/gitlab/-/issues/378072) in GitLab 15.10 in [Open Beta](../../policy/alpha-beta-support.md#beta). FLAG: On self-managed GitLab, this feature is not available. diff --git a/doc/operations/metrics/dashboards/panel_types.md b/doc/operations/metrics/dashboards/panel_types.md index 39893f279ff..6505b335a04 100644 --- a/doc/operations/metrics/dashboards/panel_types.md +++ b/doc/operations/metrics/dashboards/panel_types.md @@ -234,7 +234,7 @@ For example, if you have a query value of `53.6`, adding `%` as the unit results ## Gauge WARNING: -This panel type is an [Alpha](../../../policy/alpha-beta-support.md#alpha-features) feature, and is subject to change at any time +This panel type is an [Alpha](../../../policy/alpha-beta-support.md#experiment) feature, and is subject to change at any time without prior notice! > [Introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/207044) in GitLab 13.3. diff --git a/doc/operations/metrics/dashboards/templating_variables.md b/doc/operations/metrics/dashboards/templating_variables.md index a27e75aacef..a9be27b1d5c 100644 --- a/doc/operations/metrics/dashboards/templating_variables.md +++ b/doc/operations/metrics/dashboards/templating_variables.md @@ -27,7 +27,7 @@ described [in Using Variables](variables.md). ## `text` variable type WARNING: -This variable type is an [Alpha](../../../policy/alpha-beta-support.md#alpha-features) feature, and is subject to change at any time +This variable type is an [Alpha](../../../policy/alpha-beta-support.md#experiment) feature, and is subject to change at any time without prior notice! For each `text` variable defined in the dashboard YAML, a free text field displays @@ -64,7 +64,7 @@ templating: ## `custom` variable type WARNING: -This variable type is an [Alpha](../../../policy/alpha-beta-support.md#alpha-features) feature, and is subject to change at any time +This variable type is an [Alpha](../../../policy/alpha-beta-support.md#experiment) feature, and is subject to change at any time without prior notice! Each `custom` variable defined in the dashboard YAML creates a dropdown list @@ -112,7 +112,7 @@ templating: ## `metric_label_values` variable type WARNING: -This variable type is an [Alpha](../../../policy/alpha-beta-support.md#alpha-features) feature, and is subject to change at any time +This variable type is an [Alpha](../../../policy/alpha-beta-support.md#experiment) feature, and is subject to change at any time without prior notice! ### Full syntax diff --git a/doc/policy/alpha-beta-support.md b/doc/policy/alpha-beta-support.md index 98910f9a3bb..1d5bacf5a2b 100644 --- a/doc/policy/alpha-beta-support.md +++ b/doc/policy/alpha-beta-support.md @@ -4,68 +4,48 @@ group: Distribution info: To determine the technical writer assigned to the Stage/Group associated with this page, see https://about.gitlab.com/handbook/product/ux/technical-writing/#assignments --- -# Support for Alpha, Beta, Limited Availability, and Generally Available features **(PREMIUM)** +# Support for Experiment, Beta, and Generally Available features **(PREMIUM)** -Some GitLab features are released as Alpha or Beta versions and are +Some GitLab features are released as Experiment or Beta versions and are [not fully supported](https://about.gitlab.com/support/statement-of-support/#alpha-beta-features). All other features are considered to be Generally Available (GA). -## Alpha features +## Experiment -Support is **not** provided for Alpha features and issues with them should be opened in the [GitLab issue tracker](https://gitlab.com/gitlab-org/gitlab/-/issues). +Support is not provided for features listed as "Experimental" or "Alpha" or any similar designation. Issues regarding such features should be opened in the GitLab issue tracker. -Characteristics of Alpha features: +- Not ready for production use +- No support available +- May be unstable or have performance issues +- Can be removed at any time +- Data loss may occur +- Documentation may not exist or just be in a blog format +- Behind a feature flag that is on by default and the UI reflects Experiment status. +- Behind a toggle that is off by default and the UI reflects Experiment status. +- Feedback issue to engage with team +- UX not finalized, might be just quick action access +- Not announced in a release post -- Not ready for production use. -- Unstable and can cause performance and stability issues. -- Configuration and dependencies are likely to change. -- Features and functions may be removed. Breaking changes may occur outside of major releases or with less notice than for Beta or Generally Available features. -- Data loss can occur (be that through bugs or updates). -- Documentation reflects the Alpha status. -- Behind flags that are off by default. -- Not announced in release posts. +## Beta -## Beta features +Commercially-reasonable efforts are made to provide limited support for features designated as "Beta," with the expectation that issues require extra time and assistance from development to troubleshoot. -Your Support Contract provides **commercially-reasonable effort** support for Beta features, with the expectation that issues require extra time and assistance from development to troubleshoot. - -### Closed Beta features - -Closed Beta features are available to selected users only. - -- Not ready for production use. -- Unstable and can cause performance and stability issues. -- Configuration and dependencies unlikely to change. -- Features and functions unlikely to change. However, breaking changes may occur outside of major releases or with less notice than for Generally Available features. -- Data loss less likely. -- Behind a feature flag that is off by default and the UI reflects Beta status. -- Documentation reflects Beta status. -- Can be announced in a release post that reflects Beta status. - -### Open Beta features - -- Not ready for production use. -- Unstable and can cause performance and stability issues. +- May not be ready for production use and the UI and documentation will reflect this status +- May be unstable and can cause performance and stability issues. - Configuration and dependencies unlikely to change. - Features and functions unlikely to change. However, breaking changes may occur outside of major releases or with less notice than for Generally Available features. - Data loss not likely. - Support on a commercially-reasonable effort basis. - Documentation reflects Beta status. +- UX complete or near completion. - Behind a feature flag that is on by default and the UI reflects Beta status. - Behind a toggle that is off by default and the UI reflects Beta status. - Can be announced in a release post that reflects Beta status. -## Limited Availability (LA) - -Characteristics of Limited Availability features: - -- Ready for production use by a small set of customers. -- Can be booked by Deal Desk as part of an order. -- Fully documented and [supported](https://about.gitlab.com/support/statement-of-support/#starter-premium-and-ultimate-users). - ## Generally Available (GA) Generally Available features means that they passed the [Production Readiness Review](https://gitlab.com/gitlab-com/gl-infra/readiness/-/blob/master/.gitlab/issue_templates/production_readiness.md) for GitLab.com, and are: - Ready for production use at any scale. - Fully documented and supported. +- UX complete and in line with GitLab design standards. diff --git a/doc/topics/autodevops/upgrading_auto_deploy_dependencies.md b/doc/topics/autodevops/upgrading_auto_deploy_dependencies.md index 36dfc4c5e6a..d981313b413 100644 --- a/doc/topics/autodevops/upgrading_auto_deploy_dependencies.md +++ b/doc/topics/autodevops/upgrading_auto_deploy_dependencies.md @@ -179,7 +179,7 @@ used the `v0.17.0` chart, add `AUTO_DEVOPS_FORCE_DEPLOY_V2`. ## Early adopters -If you want to use the latest [Beta](../../policy/alpha-beta-support.md#beta-features) or unstable version of `auto-deploy-image`, include +If you want to use the latest [Beta](../../policy/alpha-beta-support.md#beta) or unstable version of `auto-deploy-image`, include the latest Auto Deploy template into your `.gitlab-ci.yml`: ```yaml @@ -189,7 +189,7 @@ include: ``` WARNING: -Using a [Beta](../../policy/alpha-beta-support.md#beta-features) or unstable `auto-deploy-image` could cause unrecoverable damage to +Using a [Beta](../../policy/alpha-beta-support.md#beta) or unstable `auto-deploy-image` could cause unrecoverable damage to your environments. Do not test it with important projects or environments. The next stable template update is [planned for GitLab v14.0](https://gitlab.com/gitlab-org/gitlab/-/issues/232788). diff --git a/doc/user/admin_area/analytics/dev_ops_reports.md b/doc/user/admin_area/analytics/dev_ops_reports.md index 2d19c0a0058..31cc9825452 100644 --- a/doc/user/admin_area/analytics/dev_ops_reports.md +++ b/doc/user/admin_area/analytics/dev_ops_reports.md @@ -39,7 +39,7 @@ feature is available. ## DevOps Adoption **(ULTIMATE SELF)** -> - [Introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/247112) in GitLab 13.7 as a [Beta feature](../../../policy/alpha-beta-support.md#beta-features). +> - [Introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/247112) in GitLab 13.7 as a [Beta feature](../../../policy/alpha-beta-support.md#beta). > - The Overview tab [introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/330401) in GitLab 14.1. > - DAST and SAST metrics [added](https://gitlab.com/gitlab-org/gitlab/-/issues/328033) in GitLab 14.1. > - Fuzz Testing metrics [added](https://gitlab.com/gitlab-org/gitlab/-/issues/330398) in GitLab 14.2. diff --git a/doc/user/analytics/value_streams_dashboard.md b/doc/user/analytics/value_streams_dashboard.md index d6e1a26afab..969c873e2be 100644 --- a/doc/user/analytics/value_streams_dashboard.md +++ b/doc/user/analytics/value_streams_dashboard.md @@ -6,8 +6,8 @@ info: To determine the technical writer assigned to the Stage/Group associated w # Value Streams Dashboard (Beta) **(ULTIMATE)** -> - Introduced in GitLab 15.8 as a Closed [Beta](../../policy/alpha-beta-support.md#beta-features) feature [with a flag](../../administration/feature_flags.md) named `group_analytics_dashboards_page`. Disabled by default. -> - Released in GitLab 15.11 as an Open [Beta](../../policy/alpha-beta-support.md#beta-features) feature [with a flag](../../administration/feature_flags.md) named `group_analytics_dashboards_page`. Enabled by default. +> - Introduced in GitLab 15.8 as a Closed [Beta](../../policy/alpha-beta-support.md#beta) feature [with a flag](../../administration/feature_flags.md) named `group_analytics_dashboards_page`. Disabled by default. +> - Released in GitLab 15.11 as an Open [Beta](../../policy/alpha-beta-support.md#beta) feature [with a flag](../../administration/feature_flags.md) named `group_analytics_dashboards_page`. Enabled by default. FLAG: On self-managed GitLab, this feature is available by default. To disable it, ask an administrator to [disable the feature flag](../../administration/feature_flags.md) named `group_analytics_dashboards_page`. diff --git a/doc/user/application_security/breach_and_attack_simulation/index.md b/doc/user/application_security/breach_and_attack_simulation/index.md new file mode 100644 index 00000000000..0d662f7d469 --- /dev/null +++ b/doc/user/application_security/breach_and_attack_simulation/index.md @@ -0,0 +1,47 @@ +--- +stage: Secure +group: Incubation +info: Breach and Attack Simulation is a GitLab Incubation Engineering program. No technical writer assigned to this group. +type: reference, howto +--- + +# Breach and Attack Simulation **(ULTIMATE)** + +> [Introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/402784) in GitLab 15.11. + +DISCLAIMER: +Breach and Attack Simulation is a set of experimental features being developed by the Incubation Engineering Department and is subject to significant changes over time. + +Breach and Attack Simulation (BAS) uses additional security testing techniques to assess the risk of detected vulnerabilities and prioritize the remediation of exploitable vulnerabilities. + +For feedback, bug reports, and feature requests, see the [feedback issue](https://gitlab.com/gitlab-org/gitlab/-/issues/404809). + +WARNING: +Only run BAS scans against test servers. Testing attacker behavior can lead to modification or loss of data. + +## Extend Dynamic Application Security Testing (DAST) + +You can simulate attacks with [DAST](../dast/index.md) to detect vulnerabilities. +By default, DAST active checks match an expected response, or determine by response +time whether a vulnerability was exploited. + +Enable the BAS feature flag in DAST to: + +- Enable callback, match response, and timing attacks inside of active checks. +- Perform Out-of-Band Application Security Testing (OAST) through callback attacks in active checks. + +To enable BAS: + +1. Create a CI/CD job using the [DAST browser-based analyzer](../dast/browser_based.md#create-a-dast-cicd-job). +1. Set the `DAST_FF_ENABLE_BAS` [CI/CD variable](../dast/browser_based.md#available-cicd-variables) to `true`. + +```yaml +include: + - template: DAST.gitlab-ci.yml + +dast: + variables: + DAST_BROWSER_SCAN: "true" + DAST_FF_ENABLE_BAS: "true" + DAST_WEBSITE: "https://my.site.com" +``` diff --git a/doc/user/application_security/coverage_fuzzing/index.md b/doc/user/application_security/coverage_fuzzing/index.md index a9da4c6aadf..45607805916 100644 --- a/doc/user/application_security/coverage_fuzzing/index.md +++ b/doc/user/application_security/coverage_fuzzing/index.md @@ -225,7 +225,7 @@ Prerequisites: ## Coverage-guided fuzz testing report -> [Introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/220062) in GitLab 13.3 as an [Alpha feature](../../../policy/alpha-beta-support.md#alpha-features). +> [Introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/220062) in GitLab 13.3 as an [Alpha feature](../../../policy/alpha-beta-support.md#experiment). For detailed information about the `gl-coverage-fuzzing-report.json` file's format, read the [schema](https://gitlab.com/gitlab-org/security-products/security-report-schemas/-/blob/master/dist/coverage-fuzzing-report-format.json). diff --git a/doc/user/application_security/dast/authentication.md b/doc/user/application_security/dast/authentication.md index 273dfeec8ef..27f56e5224c 100644 --- a/doc/user/application_security/dast/authentication.md +++ b/doc/user/application_security/dast/authentication.md @@ -47,7 +47,7 @@ To run a DAST authenticated scan: - You have the username and password of the user you would like to authenticate as during the scan. - You have checked the [known limitations](#known-limitations) to ensure DAST can authenticate to your application. -- You have satisfied the prerequisites depending on whether you're using [form authentication](#form-authentication) or [HTTP authentication]((#http-authentication). +- You have satisfied the prerequisites depending on whether you're using [form authentication](#form-authentication) or [HTTP authentication](#http-authentication). - You have thought about how you can [verify](#verifying-authentication-is-successful) whether or not authentication was successful. #### Form authentication diff --git a/doc/user/application_security/dast/browser_based.md b/doc/user/application_security/dast/browser_based.md index e921c387053..7b263e5817d 100644 --- a/doc/user/application_security/dast/browser_based.md +++ b/doc/user/application_security/dast/browser_based.md @@ -200,6 +200,7 @@ For authentication CI/CD variables, see [Authentication](authentication.md). | `DAST_BROWSER_STABILITY_TIMEOUT` | [Duration string](https://pkg.go.dev/time#ParseDuration) | `7s` | The maximum amount of time to wait for a browser to consider a page loaded and ready for analysis. | | `DAST_EXCLUDE_RULES` | string | `10020,10026` | Set to a comma-separated list of ZAP Vulnerability Rule IDs to exclude them from running during the scan. Rule IDs are numbers and can be found from the DAST log or on the [ZAP project](https://www.zaproxy.org/docs/alerts/). | | `DAST_EXCLUDE_URLS` | URLs | `https://example.com/.*/sign-out` | The URLs to skip during the authenticated scan; comma-separated. Regular expression syntax can be used to match multiple URLs. For example, `.*` matches an arbitrary character sequence. | +| `DAST_FF_ENABLE_BAS` | boolean | `true` | Set to `true` to [enable Breach and Attack Simulation](../breach_and_attack_simulation/index.md#extend-dynamic-application-security-testing-dast) during this DAST scan. | | `DAST_FULL_SCAN_ENABLED` | boolean | `true` | Set to `true` to run both passive and active checks. Default: `false` | | `DAST_PATHS` | string | `/page1.html,/category1/page3.html` | Set to a comma-separated list of URL paths relative to `DAST_WEBSITE` for DAST to scan. | | `DAST_PATHS_FILE` | string | `/builds/project/urls.txt` | Set to a file path containing a list of URL paths relative to `DAST_WEBSITE` for DAST to scan. The file must be plain text with one path per line. | diff --git a/doc/user/application_security/dependency_scanning/index.md b/doc/user/application_security/dependency_scanning/index.md index f772fc80e11..f9db8d4409e 100644 --- a/doc/user/application_security/dependency_scanning/index.md +++ b/doc/user/application_security/dependency_scanning/index.md @@ -892,7 +892,7 @@ Here's an example dependency scanning report: ### CycloneDX Software Bill of Materials -> - [Introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/350509) in GitLab 14.8 in [Beta](../../../policy/alpha-beta-support.md#beta-features). +> - [Introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/350509) in GitLab 14.8 in [Beta](../../../policy/alpha-beta-support.md#beta). > - Generally available in GitLab 15.7. In addition to the [JSON report file](#reports-json-format), the [Gemnasium](https://gitlab.com/gitlab-org/security-products/analyzers/gemnasium) diff --git a/doc/user/clusters/agent/gitops/flux.md b/doc/user/clusters/agent/gitops/flux.md index 6ad298ea354..7b2c2f222ad 100644 --- a/doc/user/clusters/agent/gitops/flux.md +++ b/doc/user/clusters/agent/gitops/flux.md @@ -15,7 +15,7 @@ You can use Flux to: To get started, see the [Flux installation documentation](https://fluxcd.io/flux/installation). -Support for Flux is in [Open Beta](../../../../policy/alpha-beta-support.md#beta-features). +Support for Flux is in [Open Beta](../../../../policy/alpha-beta-support.md#beta). ## Bootstrap installation diff --git a/doc/user/group/devops_adoption/index.md b/doc/user/group/devops_adoption/index.md index a81b61c50ce..7105318e5df 100644 --- a/doc/user/group/devops_adoption/index.md +++ b/doc/user/group/devops_adoption/index.md @@ -6,7 +6,7 @@ info: To determine the technical writer assigned to the Stage/Group associated w # Group DevOps Adoption **(ULTIMATE)** -> - [Introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/321083) in GitLab 13.11 as a [Beta feature](../../../policy/alpha-beta-support.md#beta-features). +> - [Introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/321083) in GitLab 13.11 as a [Beta feature](../../../policy/alpha-beta-support.md#beta). > - [Feature flag removed](https://gitlab.com/gitlab-org/gitlab/-/issues/333556) in GitLab 14.1. > - The Overview tab [introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/330401) in GitLab 14.1. > - DAST and SAST metrics [added](https://gitlab.com/gitlab-org/gitlab/-/issues/328033) in GitLab 14.1. diff --git a/doc/user/group/epics/img/button_close_epic.png b/doc/user/group/epics/img/button_close_epic.png Binary files differnew file mode 100644 index 00000000000..aa1a889ea23 --- /dev/null +++ b/doc/user/group/epics/img/button_close_epic.png diff --git a/doc/user/group/epics/manage_epics.md b/doc/user/group/epics/manage_epics.md index 1349d28c6a1..0dc87b7e4e4 100644 --- a/doc/user/group/epics/manage_epics.md +++ b/doc/user/group/epics/manage_epics.md @@ -159,13 +159,14 @@ Prerequisites: - You must have at least the Reporter role for the epic's group. -To close an epic, at the top of an epic, select **Close epic**. +Whenever you decide that there is no longer need for that epic, +close the epic by: -<!-- Delete when the `moved_mr_sidebar` feature flag is removed --> -If you don't see this action at the top of an epic, your project or instance might have -enabled a feature flag for [moved actions](../../project/merge_requests/index.md#move-sidebar-actions) +- Selecting **Close epic**. -You can also use the `/close` [quick action](../../project/quick_actions.md). + ![close epic - button](img/button_close_epic.png) + +- Using the `/close` [quick action](../../project/quick_actions.md). ## Reopen a closed epic diff --git a/doc/user/group/import/index.md b/doc/user/group/import/index.md index 433c842384c..33adb415d39 100644 --- a/doc/user/group/import/index.md +++ b/doc/user/group/import/index.md @@ -40,7 +40,7 @@ Migrating groups by direct transfer copies the groups from one place to another. - The subgroup of any existing top-level group. - Another GitLab instance, including GitLab.com. - In the [API](../../../api/bulk_imports.md), copy top-level groups and subgroups to these locations. -- Copy groups with projects (in [beta](../../../policy/alpha-beta-support.md#beta-features) and not ready for production +- Copy groups with projects (in [beta](../../../policy/alpha-beta-support.md#beta) and not ready for production use) or without projects. Copying projects with groups is available: - On GitLab.com by default. @@ -50,7 +50,7 @@ Not all group and project resources are copied. See list of copied resources bel - [Migrated project items](#migrated-project-items-beta). WARNING: -Importing groups with projects is in [beta](../../../policy/alpha-beta-support.md#beta-features). This feature is not +Importing groups with projects is in [beta](../../../policy/alpha-beta-support.md#beta). This feature is not ready for production use. We invite you to leave your feedback about migrating by direct transfer in @@ -153,7 +153,7 @@ role. 1. After a group has been imported, select its GitLab path to open its GitLab URL. WARNING: -Importing groups with projects is in [beta](../../../policy/alpha-beta-support.md#beta-features). This feature is not +Importing groups with projects is in [beta](../../../policy/alpha-beta-support.md#beta). This feature is not ready for production use. ### Group import history @@ -247,7 +247,7 @@ specific project item is migrated: Any other project items are **not** migrated. WARNING: -Migrating projects when migrating groups by direct transfer is in [beta](../../../policy/alpha-beta-support.md#beta-features) +Migrating projects when migrating groups by direct transfer is in [beta](../../../policy/alpha-beta-support.md#beta) and is not ready for production use. Project items that are migrated to the destination GitLab instance include: diff --git a/doc/user/group/manage.md b/doc/user/group/manage.md index 6989f746e92..ae239fc0154 100644 --- a/doc/user/group/manage.md +++ b/doc/user/group/manage.md @@ -658,7 +658,7 @@ Support for group-level settings for merge request approval rules is tracked in > [Introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/405126) in GitLab 15.11. WARNING: -This feature is in [Open Beta](/ee/policy/alpha-beta-support.md#open-beta-features). Code Suggestions use generative AI to suggest code while you're developing. Due to high demand, this feature will have unscheduled downtime and code suggestions in VS Code may be delayed. Code Suggestions may produce [low-quality or incomplete suggestions](../project/repository/code_suggestions.md#model-accuracy-and-quality). Beta users should read about the [known limitations](../project/repository/code_suggestions.md#known-limitations). We look forward to hearing your feedback. +This feature is in [Open Beta](/ee/policy/alpha-beta-support.md#beta). Code Suggestions use generative AI to suggest code while you're developing. Due to high demand, this feature will have unscheduled downtime and code suggestions in VS Code may be delayed. Code Suggestions may produce [low-quality or incomplete suggestions](../project/repository/code_suggestions.md#model-accuracy-and-quality). Beta users should read about the [known limitations](../project/repository/code_suggestions.md#known-limitations). We look forward to hearing your feedback. This setting enables users in the group to access [Code Suggestions](../project/repository/code_suggestions.md). This setting [cascades to all projects](../project/merge_requests/approvals/settings.md#settings-cascading) @@ -674,7 +674,7 @@ To enable Code Suggestions for a group: ## Group activity analytics **(PREMIUM)** -> [Introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/207164) in GitLab 12.10 as a [Beta feature](../../policy/alpha-beta-support.md#beta-features). +> [Introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/207164) in GitLab 12.10 as a [Beta feature](../../policy/alpha-beta-support.md#beta). For a group, you can view how many merge requests, issues, and members were created in the last 90 days. diff --git a/doc/user/okrs.md b/doc/user/okrs.md index 48bc22f6b3d..3de521abc8a 100644 --- a/doc/user/okrs.md +++ b/doc/user/okrs.md @@ -9,7 +9,7 @@ info: To determine the technical writer assigned to the Stage/Group associated w > [Introduced](https://gitlab.com/gitlab-org/gitlab/-/merge_requests/103355) in GitLab 15.6 [with a flag](../administration/feature_flags.md) named `okrs_mvc`. Disabled by default. WARNING: -OKRs are in [**Alpha**](../policy/alpha-beta-support.md#alpha-features). +OKRs are in [**Alpha**](../policy/alpha-beta-support.md#experiment). For the OKR feature roadmap, see [epic 7864](https://gitlab.com/groups/gitlab-org/-/epics/7864). FLAG: diff --git a/doc/user/product_analytics/index.md b/doc/user/product_analytics/index.md index 618db406ec8..bd1900f70e3 100644 --- a/doc/user/product_analytics/index.md +++ b/doc/user/product_analytics/index.md @@ -6,7 +6,7 @@ info: To determine the technical writer assigned to the Stage/Group associated w # Product analytics (Alpha) **(ULTIMATE)** -> - Introduced in GitLab 15.4 as an [Alpha](../../policy/alpha-beta-support.md#alpha-features) feature [with a flag](../../administration/feature_flags.md) named `cube_api_proxy`. Disabled by default. +> - Introduced in GitLab 15.4 as an [Alpha](../../policy/alpha-beta-support.md#experiment) feature [with a flag](../../administration/feature_flags.md) named `cube_api_proxy`. Disabled by default. > - `cube_api_proxy` revised to only reference the [Product Analytics API](../../api/product_analytics.md) in GitLab 15.6. > - `cube_api_proxy` removed and replaced with `product_analytics_internal_preview` in GitLab 15.10. > - `product_analytics_internal_preview` replaced with `product_analytics_dashboards` in GitLab 15.11. diff --git a/doc/user/profile/notifications.md b/doc/user/profile/notifications.md index 89366c73b16..c0c967a3f18 100644 --- a/doc/user/profile/notifications.md +++ b/doc/user/profile/notifications.md @@ -239,7 +239,7 @@ Turning this toggle off only unsubscribes you from updates related to this issue Learn how to [opt out of all emails from GitLab](#opt-out-of-all-gitlab-emails). <!-- Delete when the `moved_mr_sidebar` feature flag is removed --> -If you don't see this action on the right sidebar, your project or instance might have +If you don't see this action on the right sidebar, your project or instance may have enabled a feature flag for [moved sidebar actions](../project/merge_requests/index.md#move-sidebar-actions). ### Notification events on issues, merge requests, and epics diff --git a/doc/user/profile/preferences.md b/doc/user/profile/preferences.md index 21597236475..bb8b6cbea4e 100644 --- a/doc/user/profile/preferences.md +++ b/doc/user/profile/preferences.md @@ -39,11 +39,11 @@ The default theme is Indigo. You can choose between 10 themes: ## Dark mode -> [Introduced](https://gitlab.com/gitlab-org/gitlab/-/merge_requests/28252) in GitLab 13.1 as an [Alpha](../../policy/alpha-beta-support.md#alpha-features) release. +> [Introduced](https://gitlab.com/gitlab-org/gitlab/-/merge_requests/28252) in GitLab 13.1 as an [Alpha](../../policy/alpha-beta-support.md#experiment) release. GitLab has started work on dark mode! The dark mode Alpha release is available in the spirit of iteration and the lower expectations of -[Alpha versions](../../policy/alpha-beta-support.md#alpha-features). +[Alpha versions](../../policy/alpha-beta-support.md#experiment). Progress on dark mode is tracked in the [Dark theme epic](https://gitlab.com/groups/gitlab-org/-/epics/2902). See the epic for: diff --git a/doc/user/project/import/index.md b/doc/user/project/import/index.md index 5be7c49b5c2..ebfe421fd02 100644 --- a/doc/user/project/import/index.md +++ b/doc/user/project/import/index.md @@ -24,7 +24,7 @@ For any type of source and target, you can migrate GitLab projects: - When [migrating groups by direct transfer](../../group/import/index.md#migrate-groups-by-direct-transfer-recommended), which allows you to migrate all projects in a group simultaneously. Migrating projects by direct transfer is in - [Beta](../../../policy/alpha-beta-support.md#beta-features). The feature is not ready for production use. + [Beta](../../../policy/alpha-beta-support.md#beta). The feature is not ready for production use. - Using [file exports](../settings/import_export.md). With this method you can migrate projects one by one. No network connection between instances is required. @@ -32,7 +32,7 @@ If you only need to migrate Git repositories, you can [import each project by UR import issues and merge requests this way. To retain metadata like issues and merge requests, either: - [Migrate projects with groups by direct transfer](../../group/import/index.md#migrate-groups-by-direct-transfer-recommended). - This feature is in [Beta](../../../policy/alpha-beta-support.md#beta-features). It is not ready for production use. + This feature is in [Beta](../../../policy/alpha-beta-support.md#beta). It is not ready for production use. - Use [file exports](../settings/import_export.md) to import projects. Keep in mind the limitations of [migrating using file exports](../settings/import_export.md#items-that-are-exported). diff --git a/doc/user/project/import/phabricator.md b/doc/user/project/import/phabricator.md index 8a2dbba1343..e7568d87dbe 100644 --- a/doc/user/project/import/phabricator.md +++ b/doc/user/project/import/phabricator.md @@ -15,7 +15,7 @@ and will be removed in GitLab 16.0. WARNING: The Phabricator task importer is in -[beta](../../../policy/alpha-beta-support.md#beta-features) and is +[beta](../../../policy/alpha-beta-support.md#beta) and is [**not** complete](https://gitlab.com/gitlab-org/gitlab/-/issues/284406). It imports only an issue's title and description. The GitLab project created during the import process contains only issues, and the associated repository is disabled. diff --git a/doc/user/project/integrations/mlflow_client.md b/doc/user/project/integrations/mlflow_client.md index bd14021ab1c..6e03a7a1eed 100644 --- a/doc/user/project/integrations/mlflow_client.md +++ b/doc/user/project/integrations/mlflow_client.md @@ -6,7 +6,7 @@ info: Machine Learning Experiment Tracking is a GitLab Incubation Engineering pr # MLFlow Client Integration **(FREE)** -> [Introduced](https://gitlab.com/groups/gitlab-org/-/epics/8560) in GitLab 15.6 as an [Alpha](../../../policy/alpha-beta-support.md#alpha-features) release [with a flag](../../../administration/feature_flags.md) named `ml_experiment_tracking`. Disabled by default. +> [Introduced](https://gitlab.com/groups/gitlab-org/-/epics/8560) in GitLab 15.6 as an [Alpha](../../../policy/alpha-beta-support.md#experiment) release [with a flag](../../../administration/feature_flags.md) named `ml_experiment_tracking`. Disabled by default. DISCLAIMER: MLFlow Client Integration is an experimental feature being developed by the Incubation Engineering Department, diff --git a/doc/user/project/issues/create_issues.md b/doc/user/project/issues/create_issues.md index 4511c89b0ff..b6931149ede 100644 --- a/doc/user/project/issues/create_issues.md +++ b/doc/user/project/issues/create_issues.md @@ -78,7 +78,7 @@ Prerequisites: To create an issue from another issue: -1. In an existing issue, select **Issue actions** (**{ellipsis_v}**). +1. In an existing issue, select the vertical ellipsis (**{ellipsis_v}**). 1. Select **New related issue**. 1. Complete the [fields](#fields-in-the-new-issue-form). The new issue form has a **Relate to issue #123** checkbox, where `123` is the ID of the diff --git a/doc/user/project/issues/managing_issues.md b/doc/user/project/issues/managing_issues.md index b532fd0c5b8..069bc4582c6 100644 --- a/doc/user/project/issues/managing_issues.md +++ b/doc/user/project/issues/managing_issues.md @@ -209,10 +209,6 @@ To close an issue, you can do the following: - At the top of the issue, select **Close issue**. - In an [issue board](../issue_board.md), drag an issue card from its list into the **Closed** list. -<!-- Delete when the `moved_mr_sidebar` feature flag is removed --> -If you don't see this action at the top of an issue, your project or instance might have -enabled a feature flag for [moved actions](../merge_requests/index.md#move-sidebar-actions). - ### Reopen a closed issue Prerequisites: @@ -348,7 +344,7 @@ Prerequisites: To delete an issue: -1. In an issue, select **Issue actions** (**{ellipsis_v}**). +1. In an issue, select the vertical ellipsis (**{ellipsis_v}**). 1. Select **Delete issue**. Alternatively: @@ -366,7 +362,7 @@ You can promote an issue to an [epic](../../group/epics/index.md) in the immedia To promote an issue to an epic: -1. In an issue, select **Issue actions** (**{ellipsis_v}**). +1. In an issue, select the vertical ellipsis (**{ellipsis_v}**). 1. Select **Promote to epic**. Alternatively, you can use the `/promote` [quick action](../quick_actions.md#issues-merge-requests-and-epics). @@ -476,10 +472,6 @@ You can now paste the reference into another description or comment. Read more about issue references in [GitLab-Flavored Markdown](../../markdown.md#gitlab-specific-references). -<!-- Delete when the `moved_mr_sidebar` feature flag is removed --> -If you don't see this action on the right sidebar, your project or instance might have -enabled a feature flag for [moved actions](../merge_requests/index.md#move-sidebar-actions). - ## Copy issue email address > [Introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/18816) in GitLab 13.8. diff --git a/doc/user/project/merge_requests/index.md b/doc/user/project/merge_requests/index.md index 6bcf3f15685..ee7f4e5dfed 100644 --- a/doc/user/project/merge_requests/index.md +++ b/doc/user/project/merge_requests/index.md @@ -251,8 +251,7 @@ after merging does not retarget open merge requests. This improvement is <!-- When the `moved_mr_sidebar` feature flag is removed, delete this topic and update the steps for these actions like in https://gitlab.com/gitlab-org/gitlab/-/merge_requests/87727/diffs?diff_id=522279685#5d9afba799c4af9920dab533571d7abb8b9e9163 --> -> - [Introduced](https://gitlab.com/gitlab-org/gitlab/-/merge_requests/85584) in GitLab 14.10 [with a flag](../../../administration/feature_flags.md) named `moved_mr_sidebar`. Disabled by default. -> - [Changed](https://gitlab.com/gitlab-org/gitlab/-/issues/373757) to also move actions on issues, incidents, and epics in GitLab 15.10. +> [Introduced](https://gitlab.com/gitlab-org/gitlab/-/merge_requests/85584) in GitLab 14.10 [with a flag](../../../administration/feature_flags.md) named `moved_mr_sidebar`. Disabled by default. FLAG: On self-managed GitLab, by default this feature is not available. To make it available per project or for your entire instance, ask an administrator to [enable the feature flag](../../../administration/feature_flags.md) named `moved_mr_sidebar`. @@ -267,8 +266,6 @@ When this feature flag is enabled, in the upper-right corner, - [Lock discussion](../../discussions/index.md#prevent-comments-by-locking-the-discussion) - Copy reference -In GitLab 15.10 and later, similar action menus are available on issues, incidents, and epics. - When this feature flag is disabled, these actions are in the right sidebar. ## Merge request workflows diff --git a/doc/user/project/merge_requests/reviews/index.md b/doc/user/project/merge_requests/reviews/index.md index 0b2f6587f6f..974cab837a0 100644 --- a/doc/user/project/merge_requests/reviews/index.md +++ b/doc/user/project/merge_requests/reviews/index.md @@ -23,7 +23,7 @@ review merge requests in Visual Studio Code. ## Suggested reviewers **(ULTIMATE SAAS)** -> - [Introduced](https://gitlab.com/groups/gitlab-org/modelops/applied-ml/review-recommender/-/epics/3) in GitLab 15.4 as an [Open Beta](../../../../policy/alpha-beta-support.md#beta-features) feature [with a flag](../../../../administration/feature_flags.md) named `suggested_reviewers_control`. Disabled by default. +> - [Introduced](https://gitlab.com/groups/gitlab-org/modelops/applied-ml/review-recommender/-/epics/3) in GitLab 15.4 as an [Open Beta](../../../../policy/alpha-beta-support.md#beta) feature [with a flag](../../../../administration/feature_flags.md) named `suggested_reviewers_control`. Disabled by default. > - [Enabled on GitLab.com](https://gitlab.com/gitlab-org/gitlab/-/issues/368356) in GitLab 15.6. > - Beta designation [removed from the UI](https://gitlab.com/gitlab-org/gitlab/-/merge_requests/113058) in GitLab 15.10. diff --git a/doc/user/project/merge_requests/reviews/suggestions.md b/doc/user/project/merge_requests/reviews/suggestions.md index 9d43622e68a..526ccfdd315 100644 --- a/doc/user/project/merge_requests/reviews/suggestions.md +++ b/doc/user/project/merge_requests/reviews/suggestions.md @@ -155,7 +155,7 @@ For example, to customize the commit message to output ## Batch suggestions -> - [Introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/25486) in GitLab 13.1 as an [alpha feature](../../../../policy/alpha-beta-support.md#alpha-features) with a flag named `batch_suggestions`, disabled by default. +> - [Introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/25486) in GitLab 13.1 as an [alpha feature](../../../../policy/alpha-beta-support.md#experiment) with a flag named `batch_suggestions`, disabled by default. > - [Enabled by default](https://gitlab.com/gitlab-org/gitlab/-/issues/227799) in GitLab 13.2. > - [Generally available](https://gitlab.com/gitlab-org/gitlab/-/issues/320755) in GitLab 13.11. [Feature flag `batch_suggestions`](https://gitlab.com/gitlab-org/gitlab/-/issues/320755) removed. > - [Introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/326168) custom commit messages for batch suggestions in GitLab 14.4. diff --git a/doc/user/project/remote_development/index.md b/doc/user/project/remote_development/index.md index 11c9d8dc129..4e9e2c19a81 100644 --- a/doc/user/project/remote_development/index.md +++ b/doc/user/project/remote_development/index.md @@ -14,7 +14,7 @@ FLAG: On self-managed GitLab, by default this feature is available. To hide the feature, ask an administrator to [disable the feature flag](../../../administration/feature_flags.md) named `vscode_web_ide`. On GitLab.com, this feature is available. The feature is not ready for production use. WARNING: -This feature is in [Alpha](../../../policy/alpha-beta-support.md#alpha-features) and subject to change without notice. +This feature is in [Alpha](../../../policy/alpha-beta-support.md#experiment) and subject to change without notice. DISCLAIMER: This page contains information related to upcoming products, features, and functionality. diff --git a/doc/user/project/repository/code_suggestions.md b/doc/user/project/repository/code_suggestions.md index cfc8f0a1040..50993e1ec55 100644 --- a/doc/user/project/repository/code_suggestions.md +++ b/doc/user/project/repository/code_suggestions.md @@ -7,11 +7,11 @@ type: index, reference # Code Suggestions (Open Beta) **(ULTIMATE SAAS)** -> - Enabled as opt-in with GitLab 15.11 as [Open Beta](/ee/policy/alpha-beta-support.md#open-beta-features). -> - [Introduced](https://about.gitlab.com/releases/2023/02/22/gitlab-15-9-released/#code-suggestions-available-in-closed-beta) in GitLab 15.9 as [Closed Beta](/ee/policy/alpha-beta-support.md#closed-beta-features). +> - Enabled as opt-in with GitLab 15.11 as [Open Beta](/ee/policy/alpha-beta-support.md#beta). +> - [Introduced](https://about.gitlab.com/releases/2023/02/22/gitlab-15-9-released/#code-suggestions-available-in-closed-beta) in GitLab 15.9 as [Closed Beta](/ee/policy/alpha-beta-support.md#beta). WARNING: -This feature is in [Open Beta](/ee/policy/alpha-beta-support.md#open-beta-features). Code Suggestions use generative AI to suggest code while you're developing. Due to high demand, this feature will have unscheduled downtime and code suggestions in VS Code may be delayed. Code Suggestions may produce [low-quality or incomplete suggestions](#model-accuracy-and-quality). Beta users should read about the [known limitations](#known-limitations). We look forward to hearing your feedback. +This feature is in [Open Beta](/ee/policy/alpha-beta-support.md#beta). Code Suggestions use generative AI to suggest code while you're developing. Due to high demand, this feature will have unscheduled downtime and code suggestions in VS Code may be delayed. Code Suggestions may produce [low-quality or incomplete suggestions](#model-accuracy-and-quality). Beta users should read about the [known limitations](#known-limitations). We look forward to hearing your feedback. Use Code Suggestions to write code more efficiently by viewing code suggestions as you type. Depending on the cursor position, the extension either: @@ -98,7 +98,7 @@ Code Suggestions only work when you have internet connectivity and can access Gi ### Stability and performance -This feature is currently in [Open Beta](/ee/policy/alpha-beta-support.md#open-beta-features). While the Code Suggestions inference API operates completely within GitLab.com's enterprise infrastructure, we expect a high demand for this Beta feature, which may cause degraded performance or unexpected downtime of the feature. We have built this feature to gracefully degrade and have controls in place to allow us to mitigate abuse or misuse. GitLab may disable this feature for any or all customers at any time at our discretion. +This feature is currently in [Open Beta](/ee/policy/alpha-beta-support.md#beta). While the Code Suggestions inference API operates completely within GitLab.com's enterprise infrastructure, we expect a high demand for this Beta feature, which may cause degraded performance or unexpected downtime of the feature. We have built this feature to gracefully degrade and have controls in place to allow us to mitigate abuse or misuse. GitLab may disable this feature for any or all customers at any time at our discretion. ## Data privacy diff --git a/doc/user/project/repository/jupyter_notebooks/index.md b/doc/user/project/repository/jupyter_notebooks/index.md index 28f0ffb6fbd..9b24edb411e 100644 --- a/doc/user/project/repository/jupyter_notebooks/index.md +++ b/doc/user/project/repository/jupyter_notebooks/index.md @@ -25,7 +25,7 @@ GitLab. ## Cleaner diffs and raw diffs -> - [Introduced](https://gitlab.com/groups/gitlab-org/-/epics/6589) in GitLab 14.5 as an [Alpha](../../../../policy/alpha-beta-support.md#alpha-features) release [with a flag](../../../../administration/feature_flags.md) named `jupyter_clean_diffs`. Enabled by default. +> - [Introduced](https://gitlab.com/groups/gitlab-org/-/epics/6589) in GitLab 14.5 as an [Alpha](../../../../policy/alpha-beta-support.md#experiment) release [with a flag](../../../../administration/feature_flags.md) named `jupyter_clean_diffs`. Enabled by default. > - [Generally available](https://gitlab.com/gitlab-org/gitlab/-/merge_requests/75500) in GitLab 14.9. Feature flag `jupyter_clean_diffs` removed. > - [Reintroduced toggle](https://gitlab.com/gitlab-org/gitlab/-/merge_requests/85079) in GitLab 15.0 [with a flag](../../../../administration/feature_flags.md) named `ipynb_semantic_diff`. Enabled by default. > - [Generally available](https://gitlab.com/gitlab-org/gitlab/-/merge_requests/95373) in GitLab 15.6. Feature flag `ipynb_semantic_diff` removed. diff --git a/doc/user/project/web_ide/index.md b/doc/user/project/web_ide/index.md index 0b03233e664..df5290144c5 100644 --- a/doc/user/project/web_ide/index.md +++ b/doc/user/project/web_ide/index.md @@ -296,7 +296,7 @@ An example `package.json`: > [Moved](https://gitlab.com/gitlab-org/gitlab/-/issues/211685) from GitLab Ultimate to GitLab Free in 13.1. WARNING: -Interactive Web Terminals for the Web IDE is currently in [**Beta**](../../../policy/alpha-beta-support.md#beta-features). +Interactive Web Terminals for the Web IDE is currently in [**Beta**](../../../policy/alpha-beta-support.md#beta). GitLab.com shared runners [do not yet support Interactive Web Terminals](https://gitlab.com/gitlab-org/gitlab/-/issues/24674), so you must use your own private runner to make use of this feature. diff --git a/doc/user/report_abuse.md b/doc/user/report_abuse.md index c4b9af28220..de2b82c28d3 100644 --- a/doc/user/report_abuse.md +++ b/doc/user/report_abuse.md @@ -50,7 +50,7 @@ A URL to the reported user's comment is pre-filled in the abuse report's ## Report abuse from an issue -1. On the issue, in the upper-right corner, select **Issue actions** (**{ellipsis_v}**). +1. On the issue, in the upper-right corner, select the vertical ellipsis (**{ellipsis_v}**). 1. Select **Report abuse to administrator**. 1. Select a reason for reporting the user. 1. Complete an abuse report. @@ -58,7 +58,7 @@ A URL to the reported user's comment is pre-filled in the abuse report's ## Report abuse from a merge request -1. On the merge request, in the upper-right corner, select **Merge request actions** (**{ellipsis_v}**). +1. On the merge request, in the upper-right corner, select the vertical ellipsis (**{ellipsis_v}**). 1. Select **Report abuse to administrator**. 1. Select a reason for reporting this user. 1. Complete an abuse report. diff --git a/locale/gitlab.pot b/locale/gitlab.pot index 13dc05c0d16..fa551259516 100644 --- a/locale/gitlab.pot +++ b/locale/gitlab.pot @@ -751,9 +751,6 @@ msgstr "" msgid "%{integrations_link_start}Integrations%{link_end} enable you to make third-party applications part of your GitLab workflow. If the available integrations don't meet your needs, consider using a %{webhooks_link_start}webhook%{link_end}." msgstr "" -msgid "%{issuableDisplayName} %{lockStatus}." -msgstr "" - msgid "%{issuableType} will be removed! Are you sure?" msgstr "" @@ -11777,9 +11774,6 @@ msgstr "" msgid "Copy %{http_label} clone URL" msgstr "" -msgid "Copy %{issueType} email address" -msgstr "" - msgid "Copy %{name}" msgstr "" @@ -15859,9 +15853,6 @@ msgstr "" msgid "Email a new %{name} to this project" msgstr "" -msgid "Email address copied" -msgstr "" - msgid "Email address suffix" msgstr "" @@ -21277,12 +21268,6 @@ msgstr "" msgid "Header message" msgstr "" -msgid "HeaderAction|Notifications and other %{issueType} actions have moved to this menu." -msgstr "" - -msgid "HeaderAction|Okay!" -msgstr "" - msgid "HeaderAction|incident" msgstr "" @@ -26229,9 +26214,6 @@ msgstr "" msgid "Lock %{issuableDisplayName}" msgstr "" -msgid "Lock %{issuableType}" -msgstr "" - msgid "Lock File?" msgstr "" @@ -26241,6 +26223,9 @@ msgstr "" msgid "Lock memberships to SAML Group Links synchronization" msgstr "" +msgid "Lock merge request" +msgstr "" + msgid "Lock not found" msgstr "" @@ -27220,12 +27205,18 @@ msgstr "" msgid "Merge request events" msgstr "" +msgid "Merge request locked." +msgstr "" + msgid "Merge request not merged" msgstr "" msgid "Merge request reports" msgstr "" +msgid "Merge request unlocked." +msgstr "" + msgid "Merge request was scheduled to merge after pipeline succeeds" msgstr "" @@ -36236,9 +36227,6 @@ msgstr "" msgid "Reference" msgstr "" -msgid "Reference copied" -msgstr "" - msgid "References" msgstr "" @@ -38725,12 +38713,42 @@ msgstr "" msgid "ScanResultPolicy|%{thenLabelStart}Then%{thenLabelEnd} Require approval from %{approvalsRequired} of the following approvers:" msgstr "" +msgid "ScanResultPolicy|Add new criteria" +msgstr "" + +msgid "ScanResultPolicy|Choose an option" +msgstr "" + +msgid "ScanResultPolicy|Choose criteria type" +msgstr "" + +msgid "ScanResultPolicy|Maximum number of severity-criteria is one" +msgstr "" + +msgid "ScanResultPolicy|Maximum number of status-criteria is one" +msgstr "" + +msgid "ScanResultPolicy|New severity" +msgstr "" + +msgid "ScanResultPolicy|New status" +msgstr "" + msgid "ScanResultPolicy|Newly Detected" msgstr "" msgid "ScanResultPolicy|Pre-existing" msgstr "" +msgid "ScanResultPolicy|Severity is:" +msgstr "" + +msgid "ScanResultPolicy|Status is:" +msgstr "" + +msgid "ScanResultPolicy|When %{scanners} runs against the %{branches} and find(s) more than %{vulnerabilitiesAllowed} %{boldDescription} of the following criteria:" +msgstr "" + msgid "ScanResultPolicy|add an approver" msgstr "" @@ -38740,9 +38758,6 @@ msgstr "" msgid "ScanResultPolicy|finds any license %{matchType} %{licenseType} and is %{licenseStates} in an open merge request targeting %{branches}" msgstr "" -msgid "ScanResultPolicy|from %{scanners} find(s) more than %{vulnerabilitiesAllowed} %{severities} %{vulnerabilityStates} vulnerabilities in an open merge request targeting %{branches}" -msgstr "" - msgid "ScanResultPolicy|license states" msgstr "" @@ -38764,6 +38779,9 @@ msgstr "" msgid "ScanResultPolicy|vulnerabilities allowed" msgstr "" +msgid "ScanResultPolicy|vulnerabilities that match all" +msgstr "" + msgid "ScanResultPolicy|vulnerability states" msgstr "" @@ -46847,10 +46865,10 @@ msgstr "" msgid "Unlock" msgstr "" -msgid "Unlock %{issuableType}" +msgid "Unlock account" msgstr "" -msgid "Unlock account" +msgid "Unlock merge request" msgstr "" msgid "Unlock more features with GitLab Ultimate" @@ -52389,9 +52407,6 @@ msgstr "" msgid "loading" msgstr "" -msgid "locked" -msgstr "" - msgid "locked by %{path_lock_user_name} %{created_at}" msgstr "" @@ -53290,9 +53305,6 @@ msgstr "" msgid "unicode domains should use IDNA encoding" msgstr "" -msgid "unlocked" -msgstr "" - msgid "updated" msgstr "" diff --git a/qa/Gemfile b/qa/Gemfile index 1f63be4234b..3c1dd90f8f3 100644 --- a/qa/Gemfile +++ b/qa/Gemfile @@ -2,7 +2,7 @@ source 'https://rubygems.org' -gem 'gitlab-qa', '~> 9', '>= 9.1.2', require: 'gitlab/qa' +gem 'gitlab-qa', '~> 10', '>= 10.1.0', require: 'gitlab/qa' gem 'activesupport', '~> 6.1.7.2' # This should stay in sync with the root's Gemfile gem 'allure-rspec', '~> 2.20.0' gem 'capybara', '~> 3.39.0' diff --git a/qa/Gemfile.lock b/qa/Gemfile.lock index 3d4ab76ef8c..9cdf54e0920 100644 --- a/qa/Gemfile.lock +++ b/qa/Gemfile.lock @@ -102,7 +102,7 @@ GEM gitlab (4.18.0) httparty (~> 0.18) terminal-table (>= 1.5.1) - gitlab-qa (9.1.2) + gitlab-qa (10.1.0) activesupport (~> 6.1) gitlab (~> 4.18.0) http (~> 5.0) @@ -318,7 +318,7 @@ DEPENDENCIES faraday-retry (~> 2.1) fog-core (= 2.1.0) fog-google (~> 1.19) - gitlab-qa (~> 9, >= 9.1.2) + gitlab-qa (~> 10, >= 10.1.0) influxdb-client (~> 2.9) knapsack (~> 4.0) nokogiri (~> 1.14, >= 1.14.3) diff --git a/qa/qa/page/main/login.rb b/qa/qa/page/main/login.rb index 9fb1179373d..2fce357c877 100644 --- a/qa/qa/page/main/login.rb +++ b/qa/qa/page/main/login.rb @@ -107,7 +107,7 @@ module QA # Happens on clean GDK installations when seeded root admin password is expired # def set_up_new_password_if_required(user:, skip_page_validation:) - return unless has_content?('Set up new password') + return unless has_content?('Set up new password', wait: 1) Profile::Password.perform do |new_password_page| password = user&.password || Runtime::User.password diff --git a/qa/qa/page/main/menu.rb b/qa/qa/page/main/menu.rb index fa8c0508142..b254b135dda 100644 --- a/qa/qa/page/main/menu.rb +++ b/qa/qa/page/main/menu.rb @@ -161,7 +161,7 @@ module QA end def signed_in_as_user?(user) - return false if has_no_personal_area? + return false unless has_personal_area? within_user_menu do has_element?(:user_profile_link, text: /#{user.username}/) diff --git a/spec/features/ide/user_opens_merge_request_spec.rb b/spec/features/ide/user_opens_merge_request_spec.rb index dc280133a20..0074b4b1eb0 100644 --- a/spec/features/ide/user_opens_merge_request_spec.rb +++ b/spec/features/ide/user_opens_merge_request_spec.rb @@ -3,8 +3,6 @@ require 'spec_helper' RSpec.describe 'IDE merge request', :js, feature_category: :web_ide do - include CookieHelper - let(:merge_request) { create(:merge_request, :simple, source_project: project) } let(:project) { create(:project, :public, :repository) } let(:user) { project.first_owner } @@ -14,8 +12,6 @@ RSpec.describe 'IDE merge request', :js, feature_category: :web_ide do sign_in(user) - set_cookie('new-actions-popover-viewed', 'true') - visit(merge_request_path(merge_request)) end diff --git a/spec/features/incidents/incident_details_spec.rb b/spec/features/incidents/incident_details_spec.rb index a166ff46177..709919d0196 100644 --- a/spec/features/incidents/incident_details_spec.rb +++ b/spec/features/incidents/incident_details_spec.rb @@ -94,7 +94,6 @@ RSpec.describe 'Incident details', :js, feature_category: :incident_management d end it 'routes the user to the incident details page when the `issue_type` is set to incident' do - set_cookie('new-actions-popover-viewed', 'true') visit project_issue_path(project, issue) wait_for_requests @@ -114,7 +113,6 @@ RSpec.describe 'Incident details', :js, feature_category: :incident_management d end it 'routes the user to the issue details page when the `issue_type` is set to issue' do - set_cookie('new-actions-popover-viewed', 'true') visit incident_project_issues_path(project, incident) wait_for_requests diff --git a/spec/features/issues/discussion_lock_spec.rb b/spec/features/issues/discussion_lock_spec.rb index fb9addff1a2..47865d2b6ba 100644 --- a/spec/features/issues/discussion_lock_spec.rb +++ b/spec/features/issues/discussion_lock_spec.rb @@ -9,7 +9,6 @@ RSpec.describe 'Discussion Lock', :js, feature_category: :team_planning do before do sign_in(user) - stub_feature_flags(moved_mr_sidebar: false) end context 'when a user is a team member' do diff --git a/spec/features/issues/gfm_autocomplete_spec.rb b/spec/features/issues/gfm_autocomplete_spec.rb index 665c7307231..2bd5373b715 100644 --- a/spec/features/issues/gfm_autocomplete_spec.rb +++ b/spec/features/issues/gfm_autocomplete_spec.rb @@ -3,8 +3,6 @@ require 'spec_helper' RSpec.describe 'GFM autocomplete', :js, feature_category: :team_planning do - include CookieHelper - let_it_be(:user) { create(:user, name: '💃speciąl someone💃', username: 'someone.special') } let_it_be(:user2) { create(:user, name: 'Marge Simpson', username: 'msimpson') } @@ -47,7 +45,6 @@ RSpec.describe 'GFM autocomplete', :js, feature_category: :team_planning do before do sign_in(user) - set_cookie('new-actions-popover-viewed', 'true') visit project_issue_path(project, issue_to_edit) wait_for_requests diff --git a/spec/features/issues/issue_detail_spec.rb b/spec/features/issues/issue_detail_spec.rb index 29a61d584ee..d5f90bb9260 100644 --- a/spec/features/issues/issue_detail_spec.rb +++ b/spec/features/issues/issue_detail_spec.rb @@ -98,7 +98,6 @@ RSpec.describe 'Issue Detail', :js, feature_category: :team_planning do project.add_developer(user_to_be_deleted) sign_in(user_to_be_deleted) - stub_feature_flags(moved_mr_sidebar: false) visit project_issue_path(project, issue) wait_for_requests @@ -130,7 +129,7 @@ RSpec.describe 'Issue Detail', :js, feature_category: :team_planning do describe 'when an issue `issue_type` is edited' do before do sign_in(user) - set_cookie('new-actions-popover-viewed', 'true') + visit project_issue_path(project, issue) wait_for_requests end @@ -164,7 +163,7 @@ RSpec.describe 'Issue Detail', :js, feature_category: :team_planning do describe 'when an incident `issue_type` is edited' do before do sign_in(user) - set_cookie('new-actions-popover-viewed', 'true') + visit project_issue_path(project, incident) wait_for_requests end diff --git a/spec/features/issues/issue_sidebar_spec.rb b/spec/features/issues/issue_sidebar_spec.rb index ee71181fba2..2ae347d4f9e 100644 --- a/spec/features/issues/issue_sidebar_spec.rb +++ b/spec/features/issues/issue_sidebar_spec.rb @@ -5,7 +5,6 @@ require 'spec_helper' RSpec.describe 'Issue Sidebar', feature_category: :team_planning do include MobileHelpers include Features::InviteMembersModalHelpers - include CookieHelper let_it_be(:group) { create(:group, :nested) } let_it_be(:project) { create(:project, :public, namespace: group) } @@ -21,7 +20,6 @@ RSpec.describe 'Issue Sidebar', feature_category: :team_planning do context 'when signed in' do before do sign_in(user) - set_cookie('new-actions-popover-viewed', 'true') end context 'when concerning the assignee', :js do @@ -207,7 +205,6 @@ RSpec.describe 'Issue Sidebar', feature_category: :team_planning do context 'as an allowed user' do before do - stub_feature_flags(moved_mr_sidebar: false) project.add_developer(user) visit_issue(project, issue) end @@ -296,7 +293,6 @@ RSpec.describe 'Issue Sidebar', feature_category: :team_planning do context 'as a guest' do before do - stub_feature_flags(moved_mr_sidebar: false) project.add_guest(user) visit_issue(project, issue) end diff --git a/spec/features/issues/user_edits_issue_spec.rb b/spec/features/issues/user_edits_issue_spec.rb index 4730406c2b2..3a927e76fd1 100644 --- a/spec/features/issues/user_edits_issue_spec.rb +++ b/spec/features/issues/user_edits_issue_spec.rb @@ -3,8 +3,6 @@ require "spec_helper" RSpec.describe "Issues > User edits issue", :js, feature_category: :team_planning do - include CookieHelper - let_it_be(:project) { create(:project_empty_repo, :public) } let_it_be(:project_with_milestones) { create(:project_empty_repo, :public) } let_it_be(:user) { create(:user) } @@ -20,7 +18,6 @@ RSpec.describe "Issues > User edits issue", :js, feature_category: :team_plannin project.add_developer(user) project_with_milestones.add_developer(user) sign_in(user) - set_cookie('new-actions-popover-viewed', 'true') end context "from edit page" do diff --git a/spec/features/issues/user_toggles_subscription_spec.rb b/spec/features/issues/user_toggles_subscription_spec.rb index 00b04c10d33..904fafdf56a 100644 --- a/spec/features/issues/user_toggles_subscription_spec.rb +++ b/spec/features/issues/user_toggles_subscription_spec.rb @@ -10,7 +10,6 @@ RSpec.describe "User toggles subscription", :js, feature_category: :team_plannin context 'user is not logged in' do before do - stub_feature_flags(moved_mr_sidebar: false) visit(project_issue_path(project, issue)) end @@ -21,9 +20,9 @@ RSpec.describe "User toggles subscription", :js, feature_category: :team_plannin context 'user is logged in' do before do - stub_feature_flags(moved_mr_sidebar: false) project.add_developer(user) sign_in(user) + visit(project_issue_path(project, issue)) end @@ -53,7 +52,6 @@ RSpec.describe "User toggles subscription", :js, feature_category: :team_plannin context 'user is logged in without edit permission' do before do - stub_feature_flags(moved_mr_sidebar: false) sign_in(user2) visit(project_issue_path(project, issue)) diff --git a/spec/features/merge_request/user_manages_subscription_spec.rb b/spec/features/merge_request/user_manages_subscription_spec.rb index 3bcc8255ab7..d4ccc4a93b5 100644 --- a/spec/features/merge_request/user_manages_subscription_spec.rb +++ b/spec/features/merge_request/user_manages_subscription_spec.rb @@ -3,8 +3,6 @@ require 'spec_helper' RSpec.describe 'User manages subscription', :js, feature_category: :code_review_workflow do - include CookieHelper - let(:project) { create(:project, :public, :repository) } let(:merge_request) { create(:merge_request, source_project: project, target_project: project) } let(:user) { create(:user) } @@ -12,7 +10,7 @@ RSpec.describe 'User manages subscription', :js, feature_category: :code_review_ before do stub_feature_flags(moved_mr_sidebar: moved_mr_sidebar_enabled) - set_cookie('new-actions-popover-viewed', 'true') + project.add_maintainer(user) sign_in(user) diff --git a/spec/features/merge_request/user_opens_checkout_branch_modal_spec.rb b/spec/features/merge_request/user_opens_checkout_branch_modal_spec.rb index 601310cbacf..7cb1c95f6dc 100644 --- a/spec/features/merge_request/user_opens_checkout_branch_modal_spec.rb +++ b/spec/features/merge_request/user_opens_checkout_branch_modal_spec.rb @@ -4,7 +4,6 @@ require 'spec_helper' RSpec.describe 'Merge request > User opens checkout branch modal', :js, feature_category: :code_review_workflow do include ProjectForksHelper - include CookieHelper let(:project) { create(:project, :public, :repository) } let(:user) { project.creator } @@ -12,7 +11,6 @@ RSpec.describe 'Merge request > User opens checkout branch modal', :js, feature_ before do project.add_maintainer(user) sign_in(user) - set_cookie('new-actions-popover-viewed', 'true') end describe 'for fork' do diff --git a/spec/features/merge_request/user_sees_check_out_branch_modal_spec.rb b/spec/features/merge_request/user_sees_check_out_branch_modal_spec.rb index 21c62b0d0d8..ad2ceeb23e2 100644 --- a/spec/features/merge_request/user_sees_check_out_branch_modal_spec.rb +++ b/spec/features/merge_request/user_sees_check_out_branch_modal_spec.rb @@ -3,8 +3,6 @@ require 'spec_helper' RSpec.describe 'Merge request > User sees check out branch modal', :js, feature_category: :code_review_workflow do - include CookieHelper - let(:project) { create(:project, :public, :repository) } let(:user) { project.creator } let(:merge_request) { create(:merge_request, source_project: project) } @@ -12,7 +10,6 @@ RSpec.describe 'Merge request > User sees check out branch modal', :js, feature_ before do sign_in(user) - set_cookie('new-actions-popover-viewed', 'true') visit project_merge_request_path(project, merge_request) wait_for_requests diff --git a/spec/features/merge_request/user_selects_branches_for_new_mr_spec.rb b/spec/features/merge_request/user_selects_branches_for_new_mr_spec.rb index dae28cbb05c..0de59ea21c5 100644 --- a/spec/features/merge_request/user_selects_branches_for_new_mr_spec.rb +++ b/spec/features/merge_request/user_selects_branches_for_new_mr_spec.rb @@ -4,7 +4,6 @@ require 'spec_helper' RSpec.describe 'Merge request > User selects branches for new MR', :js, feature_category: :code_review_workflow do include ListboxHelpers - include CookieHelper let(:project) { create(:project, :public, :repository) } let(:user) { project.creator } @@ -18,7 +17,6 @@ RSpec.describe 'Merge request > User selects branches for new MR', :js, feature_ before do project.add_maintainer(user) sign_in(user) - set_cookie('new-actions-popover-viewed', 'true') end it 'selects the source branch sha when a tag with the same name exists' do diff --git a/spec/features/projects/issuable_templates_spec.rb b/spec/features/projects/issuable_templates_spec.rb index 77f88994bfb..adf410ce6e8 100644 --- a/spec/features/projects/issuable_templates_spec.rb +++ b/spec/features/projects/issuable_templates_spec.rb @@ -4,7 +4,6 @@ require 'spec_helper' RSpec.describe 'issuable templates', :js, feature_category: :projects do include ProjectForksHelper - include CookieHelper let(:user) { create(:user) } let(:project) { create(:project, :public, :repository) } @@ -13,7 +12,6 @@ RSpec.describe 'issuable templates', :js, feature_category: :projects do before do project.add_maintainer(user) sign_in user - set_cookie('new-actions-popover-viewed', 'true') end context 'user creates an issue using templates' do diff --git a/spec/features/reportable_note/issue_spec.rb b/spec/features/reportable_note/issue_spec.rb index a18cdf27294..55e7f5897bc 100644 --- a/spec/features/reportable_note/issue_spec.rb +++ b/spec/features/reportable_note/issue_spec.rb @@ -3,8 +3,6 @@ require 'spec_helper' RSpec.describe 'Reportable note on issue', :js, feature_category: :team_planning do - include CookieHelper - let(:user) { create(:user) } let(:project) { create(:project) } let(:issue) { create(:issue, project: project) } @@ -13,7 +11,7 @@ RSpec.describe 'Reportable note on issue', :js, feature_category: :team_planning before do project.add_maintainer(user) sign_in(user) - set_cookie('new-actions-popover-viewed', 'true') + visit project_issue_path(project, issue) end diff --git a/spec/frontend/behaviors/quick_submit_spec.js b/spec/frontend/behaviors/quick_submit_spec.js index 8de05f7ac30..81eeb3f153e 100644 --- a/spec/frontend/behaviors/quick_submit_spec.js +++ b/spec/frontend/behaviors/quick_submit_spec.js @@ -61,22 +61,15 @@ describe('Quick Submit behavior', () => { expect(testContext.spies.submit).not.toHaveBeenCalled(); }); - it('disables input of type submit', () => { - const submitButton = $('.js-quick-submit input[type=submit]'); - testContext.textarea.trigger(keydownEvent()); - - expect(submitButton).toBeDisabled(); - }); - - it('disables button of type submit', () => { - const submitButton = $('.js-quick-submit input[type=submit]'); + it('disables submit', () => { + const submitButton = $('.js-quick-submit [type=submit]'); testContext.textarea.trigger(keydownEvent()); expect(submitButton).toBeDisabled(); }); it('only clicks one submit', () => { - const existingSubmit = $('.js-quick-submit input[type=submit]'); + const existingSubmit = $('.js-quick-submit [type=submit]'); // Add an extra submit button const newSubmit = $('<button type="submit">Submit it</button>'); newSubmit.insertAfter(testContext.textarea); diff --git a/spec/frontend/issues/show/components/header_actions_spec.js b/spec/frontend/issues/show/components/header_actions_spec.js index bd8e79a90ec..58ec7387851 100644 --- a/spec/frontend/issues/show/components/header_actions_spec.js +++ b/spec/frontend/issues/show/components/header_actions_spec.js @@ -2,8 +2,6 @@ import Vue, { nextTick } from 'vue'; import { GlDropdownItem, GlLink, GlModal, GlButton } from '@gitlab/ui'; import { shallowMount } from '@vue/test-utils'; import Vuex from 'vuex'; -import VueApollo from 'vue-apollo'; -import waitForPromises from 'helpers/wait_for_promises'; import { mockTracking } from 'helpers/tracking_helper'; import { createAlert, VARIANT_SUCCESS } from '~/alert'; import { STATUS_CLOSED, STATUS_OPEN, TYPE_INCIDENT, TYPE_ISSUE } from '~/issues/constants'; @@ -16,22 +14,17 @@ import promoteToEpicMutation from '~/issues/show/queries/promote_to_epic.mutatio import * as urlUtility from '~/lib/utils/url_utility'; import eventHub from '~/notes/event_hub'; import createStore from '~/notes/stores'; -import createMockApollo from 'helpers/mock_apollo_helper'; -import issueReferenceQuery from '~/sidebar/queries/issue_reference.query.graphql'; -import updateIssueMutation from '~/issues/show/queries/update_issue.mutation.graphql'; -import toast from '~/vue_shared/plugins/global_toast'; jest.mock('~/alert'); jest.mock('~/issues/show/event_hub', () => ({ $emit: jest.fn() })); -jest.mock('~/vue_shared/plugins/global_toast'); describe('HeaderActions component', () => { let dispatchEventSpy; + let mutateMock; let wrapper; let visitUrlSpy; Vue.use(Vuex); - Vue.use(VueApollo); const store = createStore(); @@ -52,28 +45,15 @@ describe('HeaderActions component', () => { reportedUserId: 1, reportedFromUrl: 'http://localhost:/gitlab-org/-/issues/32', submitAsSpamPath: 'gitlab-org/gitlab-test/-/issues/32/submit_as_spam', - issuableEmailAddress: null, - fullPath: 'full-path', }; - const updateIssueMutationResponse = { - data: { - updateIssue: { - errors: [], - issuable: { - id: 'gid://gitlab/Issue/511', - state: STATUS_OPEN, - }, - }, - }, - }; + const updateIssueMutationResponse = { data: { updateIssue: { errors: [] } } }; const promoteToEpicMutationResponse = { data: { promoteToEpic: { errors: [], epic: { - id: 'gid://gitlab/Epic/1', webPath: '/groups/gitlab-org/-/epics/1', }, }, @@ -89,20 +69,6 @@ describe('HeaderActions component', () => { }, }; - const mockIssueReferenceData = { - data: { - workspace: { - id: 'gid://gitlab/Project/7', - issuable: { - id: 'gid://gitlab/Issue/511', - reference: 'flightjs/Flight#33', - __typename: 'Issue', - }, - __typename: 'Project', - }, - }, - }; - const findToggleIssueStateButton = () => wrapper.find(`[data-testid="toggle-button"]`); const findEditButton = () => wrapper.find(`[data-testid="edit-button"]`); @@ -111,54 +77,33 @@ describe('HeaderActions component', () => { const findDesktopDropdown = () => findDropdownBy('desktop-dropdown'); const findMobileDropdownItems = () => findMobileDropdown().findAllComponents(GlDropdownItem); const findDesktopDropdownItems = () => findDesktopDropdown().findAllComponents(GlDropdownItem); - const findAbuseCategorySelector = () => wrapper.findComponent(AbuseCategorySelector); - const findReportAbuseSelectorItem = () => wrapper.find(`[data-testid="report-abuse-item"]`); - const findNotificationWidget = () => wrapper.find(`[data-testid="notification-toggle"]`); - const findLockIssueWidget = () => wrapper.find(`[data-testid="lock-issue-toggle"]`); - const findCopyRefenceDropdownItem = () => wrapper.find(`[data-testid="copy-reference"]`); - const findCopyEmailItem = () => wrapper.find(`[data-testid="copy-email"]`); const findModal = () => wrapper.findComponent(GlModal); const findModalLinkAt = (index) => findModal().findAllComponents(GlLink).at(index); - const issueReferenceSuccessHandler = jest.fn().mockResolvedValue(mockIssueReferenceData); - const updateIssueMutationResponseHandler = jest - .fn() - .mockResolvedValue(updateIssueMutationResponse); - const promoteToEpicMutationSuccessResponseHandler = jest - .fn() - .mockResolvedValue(promoteToEpicMutationResponse); - const promoteToEpicMutationErrorHandler = jest - .fn() - .mockResolvedValue(promoteToEpicMutationErrorResponse); - const mountComponent = ({ props = {}, issueState = STATUS_OPEN, blockedByIssues = [], - movedMrSidebarEnabled = false, - promoteToEpicHandler = promoteToEpicMutationSuccessResponseHandler, + mutateResponse = {}, } = {}) => { + mutateMock = jest.fn().mockResolvedValue(mutateResponse); + store.dispatch('setNoteableData', { blocked_by_issues: blockedByIssues, state: issueState, }); - const handlers = [ - [issueReferenceQuery, issueReferenceSuccessHandler], - [updateIssueMutation, updateIssueMutationResponseHandler], - [promoteToEpicMutation, promoteToEpicHandler], - ]; - return shallowMount(HeaderActions, { - apolloProvider: createMockApollo(handlers), store, provide: { ...defaultProps, ...props, - glFeatures: { - movedMrSidebar: movedMrSidebarEnabled, + }, + mocks: { + $apollo: { + mutate: mutateMock, }, }, stubs: { @@ -193,6 +138,7 @@ describe('HeaderActions component', () => { wrapper = mountComponent({ props: { issueType }, issueState, + mutateResponse: updateIssueMutationResponse, }); }); @@ -203,19 +149,23 @@ describe('HeaderActions component', () => { it('calls apollo mutation', () => { findToggleIssueStateButton().vm.$emit('click'); - expect(updateIssueMutationResponseHandler).toHaveBeenCalledWith({ - input: { - iid: defaultProps.iid, - projectPath: defaultProps.projectPath, - stateEvent: newIssueState, - }, - }); + expect(mutateMock).toHaveBeenCalledWith( + expect.objectContaining({ + variables: { + input: { + iid: defaultProps.iid, + projectPath: defaultProps.projectPath, + stateEvent: newIssueState, + }, + }, + }), + ); }); it('dispatches a custom event to update the issue page', async () => { findToggleIssueStateButton().vm.$emit('click'); - await waitForPromises(); + await nextTick(); expect(dispatchEventSpy).toHaveBeenCalledTimes(1); }); @@ -340,25 +290,28 @@ describe('HeaderActions component', () => { describe('when "Promote to epic" button is clicked', () => { describe('when response is successful', () => { - beforeEach(async () => { + beforeEach(() => { visitUrlSpy = jest.spyOn(urlUtility, 'visitUrl').mockReturnValue({}); wrapper = mountComponent({ - promoteToEpicHandler: promoteToEpicMutationSuccessResponseHandler, + mutateResponse: promoteToEpicMutationResponse, }); wrapper.find('[data-testid="promote-button"]').vm.$emit('click'); - - await waitForPromises(); }); it('invokes GraphQL mutation when clicked', () => { - expect(promoteToEpicMutationSuccessResponseHandler).toHaveBeenCalledWith({ - input: { - iid: defaultProps.iid, - projectPath: defaultProps.projectPath, - }, - }); + expect(mutateMock).toHaveBeenCalledWith( + expect.objectContaining({ + mutation: promoteToEpicMutation, + variables: { + input: { + iid: defaultProps.iid, + projectPath: defaultProps.projectPath, + }, + }, + }), + ); }); it('shows a success message and tells the user they are being redirected', () => { @@ -376,16 +329,14 @@ describe('HeaderActions component', () => { }); describe('when response contains errors', () => { - beforeEach(async () => { + beforeEach(() => { visitUrlSpy = jest.spyOn(urlUtility, 'visitUrl').mockReturnValue({}); wrapper = mountComponent({ - promoteToEpicHandler: promoteToEpicMutationErrorHandler, + mutateResponse: promoteToEpicMutationErrorResponse, }); wrapper.find('[data-testid="promote-button"]').vm.$emit('click'); - - await waitForPromises(); }); it('shows an error message', () => { @@ -398,17 +349,21 @@ describe('HeaderActions component', () => { describe('when `toggle.issuable.state` event is emitted', () => { it('invokes a method to toggle the issue state', () => { - wrapper = mountComponent(); + wrapper = mountComponent({ mutateResponse: updateIssueMutationResponse }); eventHub.$emit('toggle.issuable.state'); - expect(updateIssueMutationResponseHandler).toHaveBeenCalledWith({ - input: { - iid: defaultProps.iid, - projectPath: defaultProps.projectPath, - stateEvent: ISSUE_STATE_EVENT_CLOSE, - }, - }); + expect(mutateMock).toHaveBeenCalledWith( + expect.objectContaining({ + variables: { + input: { + iid: defaultProps.iid, + projectPath: defaultProps.projectPath, + stateEvent: ISSUE_STATE_EVENT_CLOSE, + }, + }, + }), + ); }); }); @@ -437,13 +392,17 @@ describe('HeaderActions component', () => { it('calls apollo mutation when primary button is clicked', () => { findModal().vm.$emit('primary'); - expect(updateIssueMutationResponseHandler).toHaveBeenCalledWith({ - input: { - iid: defaultProps.iid.toString(), - projectPath: defaultProps.projectPath, - stateEvent: ISSUE_STATE_EVENT_CLOSE, - }, - }); + expect(mutateMock).toHaveBeenCalledWith( + expect.objectContaining({ + variables: { + input: { + iid: defaultProps.iid.toString(), + projectPath: defaultProps.projectPath, + stateEvent: ISSUE_STATE_EVENT_CLOSE, + }, + }, + }), + ); }); describe.each` @@ -475,6 +434,8 @@ describe('HeaderActions component', () => { }); describe('abuse category selector', () => { + const findAbuseCategorySelector = () => wrapper.findComponent(AbuseCategorySelector); + beforeEach(() => { wrapper = mountComponent({ props: { isIssueAuthor: false } }); }); @@ -484,7 +445,7 @@ describe('HeaderActions component', () => { }); it('opens the drawer', async () => { - findReportAbuseSelectorItem().vm.$emit('click'); + findDesktopDropdownItems().at(2).vm.$emit('click'); await nextTick(); @@ -492,160 +453,10 @@ describe('HeaderActions component', () => { }); it('closes the drawer', async () => { - await findReportAbuseSelectorItem().vm.$emit('click'); + await findDesktopDropdownItems().at(2).vm.$emit('click'); await findAbuseCategorySelector().vm.$emit('close-drawer'); expect(findAbuseCategorySelector().exists()).toEqual(false); }); }); - - describe('notification toggle', () => { - describe('visibility', () => { - describe.each` - movedMrSidebarEnabled | issueType | visible - ${true} | ${TYPE_ISSUE} | ${true} - ${true} | ${TYPE_INCIDENT} | ${true} - ${false} | ${TYPE_ISSUE} | ${false} - ${false} | ${TYPE_INCIDENT} | ${false} - `( - `when movedMrSidebarEnabled flag is "$movedMrSidebarEnabled" with issue type "$issueType"`, - ({ movedMrSidebarEnabled, issueType, visible }) => { - beforeEach(() => { - wrapper = mountComponent({ - props: { - issueType, - }, - movedMrSidebarEnabled, - }); - }); - - it(`${visible ? 'shows' : 'hides'} Notification toggle`, () => { - expect(findNotificationWidget().exists()).toBe(visible); - }); - }, - ); - }); - }); - - describe('lock issue option', () => { - describe('visibility', () => { - describe.each` - movedMrSidebarEnabled | issueType | visible - ${true} | ${TYPE_ISSUE} | ${true} - ${true} | ${TYPE_INCIDENT} | ${false} - ${false} | ${TYPE_ISSUE} | ${false} - ${false} | ${TYPE_INCIDENT} | ${false} - `( - `when movedMrSidebarEnabled flag is "$movedMrSidebarEnabled" with issue type "$issueType"`, - ({ movedMrSidebarEnabled, issueType, visible }) => { - beforeEach(() => { - wrapper = mountComponent({ - props: { - issueType, - }, - movedMrSidebarEnabled, - }); - }); - - it(`${visible ? 'shows' : 'hides'} Lock issue option`, () => { - expect(findLockIssueWidget().exists()).toBe(visible); - }); - }, - ); - }); - }); - - describe('copy reference option', () => { - describe('visibility', () => { - describe.each` - movedMrSidebarEnabled | issueType | visible - ${true} | ${TYPE_ISSUE} | ${true} - ${true} | ${TYPE_INCIDENT} | ${true} - ${false} | ${TYPE_ISSUE} | ${false} - ${false} | ${TYPE_INCIDENT} | ${false} - `( - 'when movedMrSidebarFlagEnabled is "$movedMrSidebarEnabled" with issue type "$issueType"', - ({ movedMrSidebarEnabled, issueType, visible }) => { - beforeEach(() => { - wrapper = mountComponent({ - props: { - issueType, - }, - movedMrSidebarEnabled, - }); - }); - - it(`${visible ? 'shows' : 'hides'} Copy reference option`, () => { - expect(findCopyRefenceDropdownItem().exists()).toBe(visible); - }); - }, - ); - }); - - describe('clicking when visible', () => { - beforeEach(() => { - wrapper = mountComponent({ - props: { - issueType: TYPE_ISSUE, - }, - movedMrSidebarEnabled: true, - }); - }); - - it('shows toast message', () => { - findCopyRefenceDropdownItem().vm.$emit('click'); - - expect(toast).toHaveBeenCalledWith('Reference copied'); - }); - }); - }); - - describe('copy email option', () => { - describe('visibility', () => { - describe.each` - movedMrSidebarEnabled | issueType | issuableEmailAddress | visible - ${true} | ${TYPE_ISSUE} | ${'mock-email-address'} | ${true} - ${true} | ${TYPE_ISSUE} | ${''} | ${false} - ${true} | ${TYPE_INCIDENT} | ${'mock-email-address'} | ${true} - ${true} | ${TYPE_INCIDENT} | ${''} | ${false} - ${false} | ${TYPE_ISSUE} | ${'mock-email-address'} | ${false} - ${false} | ${TYPE_INCIDENT} | ${'mock-email-address'} | ${false} - `( - 'when movedMrSidebarEnabled flag is "$movedMrSidebarEnabled" issue type is "$issueType" and issuableEmailAddress="$issuableEmailAddress"', - ({ movedMrSidebarEnabled, issueType, issuableEmailAddress, visible }) => { - beforeEach(() => { - wrapper = mountComponent({ - props: { - issueType, - issuableEmailAddress, - }, - movedMrSidebarEnabled, - }); - }); - - it(`${visible ? 'shows' : 'hides'} Copy email option`, () => { - expect(findCopyEmailItem().exists()).toBe(visible); - }); - }, - ); - }); - - describe('clicking when visible', () => { - beforeEach(() => { - wrapper = mountComponent({ - props: { - issueType: TYPE_ISSUE, - issuableEmailAddress: 'mock-email-address', - }, - movedMrSidebarEnabled: true, - }); - }); - - it('shows toast message', () => { - findCopyEmailItem().vm.$emit('click'); - - expect(toast).toHaveBeenCalledWith('Email address copied'); - }); - }); - }); }); diff --git a/spec/frontend/issues/show/components/new_header_actions_popover_spec.js b/spec/frontend/issues/show/components/new_header_actions_popover_spec.js deleted file mode 100644 index 71b7a3da1c3..00000000000 --- a/spec/frontend/issues/show/components/new_header_actions_popover_spec.js +++ /dev/null @@ -1,67 +0,0 @@ -import { GlPopover } from '@gitlab/ui'; -import { shallowMountExtended } from 'helpers/vue_test_utils_helper'; -import NewHeaderActionsPopover from '~/issues/show/components/new_header_actions_popover.vue'; -import { NEW_ACTIONS_POPOVER_KEY } from '~/issues/show/constants'; -import { TYPE_ISSUE } from '~/issues/constants'; -import * as utils from '~/lib/utils/common_utils'; - -describe('NewHeaderActionsPopover', () => { - let wrapper; - - const createComponent = ({ issueType = TYPE_ISSUE }) => { - wrapper = shallowMountExtended(NewHeaderActionsPopover, { - propsData: { - issueType, - }, - stubs: { - GlPopover, - }, - }); - }; - - const findPopover = () => wrapper.findComponent(GlPopover); - const findConfirmButton = () => wrapper.findByTestId('confirm-button'); - - describe('without the popover cookie', () => { - beforeEach(() => { - utils.setCookie = jest.fn(); - - createComponent({}); - }); - - it('renders the popover with correct text', () => { - expect(findPopover().exists()).toBe(true); - expect(findPopover().text()).toContain('issue actions'); - }); - - it('does not call setCookie', () => { - expect(utils.setCookie).not.toHaveBeenCalled(); - }); - - describe('when the confirm button is clicked', () => { - beforeEach(() => { - findConfirmButton().vm.$emit('click'); - }); - - it('sets the popover cookie', () => { - expect(utils.setCookie).toHaveBeenCalledWith(NEW_ACTIONS_POPOVER_KEY, true); - }); - - it('hides the popover', () => { - expect(findPopover().exists()).toBe(false); - }); - }); - }); - - describe('with the popover cookie', () => { - beforeEach(() => { - jest.spyOn(utils, 'getCookie').mockReturnValue('true'); - - createComponent({}); - }); - - it('does not render the popover', () => { - expect(findPopover().exists()).toBe(false); - }); - }); -}); diff --git a/spec/frontend/sidebar/components/lock/issuable_lock_form_spec.js b/spec/frontend/sidebar/components/lock/issuable_lock_form_spec.js index 5e766e9a41c..d26ef7298ce 100644 --- a/spec/frontend/sidebar/components/lock/issuable_lock_form_spec.js +++ b/spec/frontend/sidebar/components/lock/issuable_lock_form_spec.js @@ -29,7 +29,6 @@ describe('IssuableLockForm', () => { const findEditForm = () => wrapper.findComponent(EditForm); const findSidebarLockStatusTooltip = () => getBinding(findSidebarCollapseIcon().element, 'gl-tooltip'); - const findIssuableLockClickable = () => wrapper.find('[data-testid="issuable-lock"]'); const initStore = (isLocked) => { if (issuableType === ISSUABLE_TYPE_ISSUE) { @@ -49,7 +48,7 @@ describe('IssuableLockForm', () => { store.getters.getNoteableData.discussion_locked = isLocked; }; - const createComponent = ({ props = {}, movedMrSidebar = false }) => { + const createComponent = ({ props = {} }, movedMrSidebar = false) => { wrapper = shallowMount(IssuableLockForm, { store, provide: { @@ -170,27 +169,11 @@ describe('IssuableLockForm', () => { `('displays $message when merge request is $locked', async ({ locked, message }) => { initStore(locked); - createComponent({ movedMrSidebar: true }); + createComponent({}, true); await wrapper.find('.dropdown-item').trigger('click'); expect(toast).toHaveBeenCalledWith(message); }); }); - - describe('moved_mr_sidebar flag', () => { - describe('when the flag is off', () => { - it('does not show the non editable lock status', () => { - createComponent({ movedMrSidebar: false }); - expect(findIssuableLockClickable().exists()).toBe(false); - }); - }); - - describe('when the flag is on', () => { - it('does not show the non editable lock status', () => { - createComponent({ movedMrSidebar: true }); - expect(findIssuableLockClickable().exists()).toBe(true); - }); - }); - }); }); diff --git a/spec/graphql/types/ci/job_trace_type_spec.rb b/spec/graphql/types/ci/job_trace_type_spec.rb new file mode 100644 index 00000000000..71803aa9ece --- /dev/null +++ b/spec/graphql/types/ci/job_trace_type_spec.rb @@ -0,0 +1,27 @@ +# frozen_string_literal: true + +require 'spec_helper' + +RSpec.describe GitlabSchema.types['CiJobTrace'], feature_category: :continuous_integration do + include GraphqlHelpers + + let_it_be(:job) { create(:ci_build) } + + it 'has the correct fields' do + expected_fields = [:html_summary] + + expect(described_class).to have_graphql_fields(*expected_fields) + end + + it 'shows the correct trace contents' do + job.trace.set('BUILD TRACE') + + expect_next_instance_of(Gitlab::Ci::Trace) do |trace| + expect(trace).to receive(:html).with(last_lines: 10).and_call_original + end + + resolved_field = resolve_field(:html_summary, job.trace) + + expect(resolved_field).to eq("<span>BUILD TRACE</span>") + end +end diff --git a/spec/graphql/types/ci/job_type_spec.rb b/spec/graphql/types/ci/job_type_spec.rb index 4eb18574969..7715ccdd075 100644 --- a/spec/graphql/types/ci/job_type_spec.rb +++ b/spec/graphql/types/ci/job_type_spec.rb @@ -55,6 +55,7 @@ RSpec.describe Types::Ci::JobType, feature_category: :continuous_integration do playPath canPlayJob scheduled + trace ] expect(described_class).to have_graphql_fields(*expected_fields) diff --git a/spec/helpers/issues_helper_spec.rb b/spec/helpers/issues_helper_spec.rb index 38cbb5a1d66..d940c696fb3 100644 --- a/spec/helpers/issues_helper_spec.rb +++ b/spec/helpers/issues_helper_spec.rb @@ -3,8 +3,6 @@ require 'spec_helper' RSpec.describe IssuesHelper do - include Features::MergeRequestHelpers - let_it_be(:project) { create(:project) } let_it_be_with_reload(:issue) { create(:issue, project: project) } @@ -237,13 +235,10 @@ RSpec.describe IssuesHelper do describe '#issue_header_actions_data' do let(:current_user) { create(:user) } - let(:merge_request) { create(:merge_request, :opened, source_project: project, author: current_user) } - let(:issuable_sidebar_issue) { serialize_issuable_sidebar(current_user, project, merge_request) } before do allow(helper).to receive(:current_user).and_return(current_user) allow(helper).to receive(:can?).and_return(true) - allow(helper).to receive(:issuable_sidebar).and_return(issuable_sidebar_issue) end it 'returns expected result' do @@ -262,11 +257,10 @@ RSpec.describe IssuesHelper do report_abuse_path: add_category_abuse_reports_path, reported_user_id: issue.author.id, reported_from_url: issue_url(issue), - submit_as_spam_path: mark_as_spam_project_issue_path(project, issue), - issuable_email_address: issuable_sidebar_issue[:create_note_email] + submit_as_spam_path: mark_as_spam_project_issue_path(project, issue) } - expect(helper.issue_header_actions_data(project, issue, current_user, issuable_sidebar_issue)).to include(expected) + expect(helper.issue_header_actions_data(project, issue, current_user)).to include(expected) end end diff --git a/spec/requests/api/error_tracking/project_settings_spec.rb b/spec/requests/api/error_tracking/project_settings_spec.rb index 3b01dec6f9c..bde90627983 100644 --- a/spec/requests/api/error_tracking/project_settings_spec.rb +++ b/spec/requests/api/error_tracking/project_settings_spec.rb @@ -4,9 +4,9 @@ require 'spec_helper' RSpec.describe API::ErrorTracking::ProjectSettings, feature_category: :error_tracking do let_it_be(:user) { create(:user) } - - let(:setting) { create(:project_error_tracking_setting) } - let(:project) { setting.project } + let_it_be(:project) { create(:project) } + let_it_be(:setting) { create(:project_error_tracking_setting, project: project) } + let_it_be(:project_without_setting) { create(:project) } shared_examples 'returns project settings' do it 'returns correct project settings' do @@ -100,7 +100,8 @@ RSpec.describe API::ErrorTracking::ProjectSettings, feature_category: :error_tra end describe "PATCH /projects/:id/error_tracking/settings" do - let(:params) { { active: false } } + let(:params) { { active: false, integrated: integrated } } + let(:integrated) { false } def make_request patch api("/projects/#{project.id}/error_tracking/settings", user), params: params @@ -111,82 +112,78 @@ RSpec.describe API::ErrorTracking::ProjectSettings, feature_category: :error_tra project.add_maintainer(user) end - context 'patch settings' do - context 'integrated_error_tracking feature enabled' do - it_behaves_like 'returns project settings' - end - - context 'integrated_error_tracking feature disabled' do - before do - stub_feature_flags(integrated_error_tracking: false) - end + context 'with integrated_error_tracking feature enabled' do + it_behaves_like 'returns project settings' + end - it_behaves_like 'returns project settings with false for integrated' + context 'with integrated_error_tracking feature disabled' do + before do + stub_feature_flags(integrated_error_tracking: false) end - it 'updates enabled flag' do - expect(setting).to be_enabled + it_behaves_like 'returns project settings with false for integrated' + end - make_request + it 'updates enabled flag' do + expect(setting).to be_enabled - expect(json_response).to include('active' => false) - expect(setting.reload).not_to be_enabled - end + make_request - context 'active is invalid' do - let(:params) { { active: "randomstring" } } + expect(json_response).to include('active' => false) + expect(setting.reload).not_to be_enabled + end - it 'returns active is invalid if non boolean' do - make_request + context 'when active is invalid' do + let(:params) { { active: "randomstring" } } - expect(response).to have_gitlab_http_status(:bad_request) - expect(json_response['error']) - .to eq('active is invalid') - end + it 'returns active is invalid if non boolean' do + make_request + + expect(response).to have_gitlab_http_status(:bad_request) + expect(json_response['error']) + .to eq('active is invalid') end + end - context 'active is empty' do - let(:params) { { active: '' } } + context 'when active is empty' do + let(:params) { { active: '' } } - it 'returns 400' do - make_request + it 'returns 400' do + make_request - expect(response).to have_gitlab_http_status(:bad_request) - expect(json_response['error']) - .to eq('active is empty') - end + expect(response).to have_gitlab_http_status(:bad_request) + expect(json_response['error']) + .to eq('active is empty') end + end - context 'with integrated param' do - let(:params) { { active: true, integrated: true } } + context 'with integrated param' do + let(:params) { { active: true, integrated: true } } - context 'integrated_error_tracking feature enabled' do - before do - stub_feature_flags(integrated_error_tracking: true) - end + context 'when integrated_error_tracking feature enabled' do + before do + stub_feature_flags(integrated_error_tracking: true) + end - it 'updates the integrated flag' do - expect(setting.integrated).to be_falsey + it 'updates the integrated flag' do + expect(setting.integrated).to be_falsey - make_request + make_request - expect(json_response).to include('integrated' => true) - expect(setting.reload.integrated).to be_truthy - end + expect(json_response).to include('integrated' => true) + expect(setting.reload.integrated).to be_truthy end end end context 'without a project setting' do - let_it_be(:project) { create(:project) } + let(:project) { project_without_setting } before do project.add_maintainer(user) end - context 'patch settings' do - it_behaves_like 'returns no project settings' - end + it_behaves_like 'returns no project settings' end context "when ::Projects::Operations::UpdateService responds with an error" do @@ -210,38 +207,22 @@ RSpec.describe API::ErrorTracking::ProjectSettings, feature_category: :error_tra end end - context 'when authenticated as reporter' do - before do - project.add_reporter(user) - end - - context 'patch request' do - it_behaves_like 'returns 403' - end - end - context 'when authenticated as developer' do before do project.add_developer(user) end - context 'patch request' do - it_behaves_like 'returns 403' - end + it_behaves_like 'returns 403' end context 'when authenticated as non-member' do - context 'patch request' do - it_behaves_like 'returns 404' - end + it_behaves_like 'returns 404' end context 'when unauthenticated' do let(:user) { nil } - context 'patch request' do - it_behaves_like 'returns 401' - end + it_behaves_like 'returns 401' end end @@ -255,43 +236,25 @@ RSpec.describe API::ErrorTracking::ProjectSettings, feature_category: :error_tra project.add_maintainer(user) end - context 'get settings' do - context 'integrated_error_tracking feature enabled' do - before do - stub_feature_flags(integrated_error_tracking: true) - end + it_behaves_like 'returns project settings' - it_behaves_like 'returns project settings' + context 'when integrated_error_tracking feature disabled' do + before do + stub_feature_flags(integrated_error_tracking: false) end - context 'integrated_error_tracking feature disabled' do - before do - stub_feature_flags(integrated_error_tracking: false) - end - - it_behaves_like 'returns project settings with false for integrated' - end + it_behaves_like 'returns project settings with false for integrated' end end context 'without a project setting' do - let(:project) { create(:project) } + let(:project) { project_without_setting } before do project.add_maintainer(user) end - context 'get settings' do - it_behaves_like 'returns no project settings' - end - end - - context 'when authenticated as reporter' do - before do - project.add_reporter(user) - end - - it_behaves_like 'returns 403' + it_behaves_like 'returns no project settings' end context 'when authenticated as developer' do @@ -329,9 +292,8 @@ RSpec.describe API::ErrorTracking::ProjectSettings, feature_category: :error_tra end context "when integrated" do - let(:integrated) { true } - context "with existing setting" do + let(:project) { setting.project } let(:setting) { create(:project_error_tracking_setting, :integrated) } let(:active) { false } @@ -351,8 +313,8 @@ RSpec.describe API::ErrorTracking::ProjectSettings, feature_category: :error_tra end context "without setting" do + let(:project) { project_without_setting } let(:active) { true } - let_it_be(:project) { create(:project) } it "creates a setting" do expect { make_request }.to change { ErrorTracking::ProjectErrorTrackingSetting.count } @@ -362,7 +324,7 @@ RSpec.describe API::ErrorTracking::ProjectSettings, feature_category: :error_tra expect(json_response).to eq( "active" => true, "api_url" => nil, - "integrated" => integrated, + "integrated" => true, "project_name" => nil, "sentry_external_url" => nil ) @@ -382,9 +344,7 @@ RSpec.describe API::ErrorTracking::ProjectSettings, feature_category: :error_tra end end - context "integrated_error_tracking feature disabled" do - let(:integrated) { true } - + context "when integrated_error_tracking feature disabled" do before do stub_feature_flags(integrated_error_tracking: false) end @@ -405,14 +365,6 @@ RSpec.describe API::ErrorTracking::ProjectSettings, feature_category: :error_tra end end - context 'as reporter' do - before do - project.add_reporter(user) - end - - it_behaves_like 'returns 403' - end - context "as developer" do before do project.add_developer(user) @@ -428,7 +380,6 @@ RSpec.describe API::ErrorTracking::ProjectSettings, feature_category: :error_tra context "when unauthorized" do let(:user) { nil } - let(:integrated) { true } it_behaves_like 'returns 401' end diff --git a/spec/requests/jwks_controller_spec.rb b/spec/requests/jwks_controller_spec.rb index c6f5f7c6bea..f756c1758e4 100644 --- a/spec/requests/jwks_controller_spec.rb +++ b/spec/requests/jwks_controller_spec.rb @@ -35,6 +35,15 @@ RSpec.describe JwksController, feature_category: :system_access do expect(ids).to contain_exactly(ci_jwk['kid'], oidc_jwk['kid']) end + it 'includes the OIDC signing key ID' do + get jwks_url + + expect(response).to have_gitlab_http_status(:ok) + + ids = json_response['keys'].map { |jwk| jwk['kid'] } + expect(ids).to include(Doorkeeper::OpenidConnect.signing_key_normalized.symbolize_keys[:kid]) + end + it 'does not leak private key data' do get jwks_url diff --git a/spec/support/rspec_order_todo.yml b/spec/support/rspec_order_todo.yml index 15743e6b695..03c35e5774d 100644 --- a/spec/support/rspec_order_todo.yml +++ b/spec/support/rspec_order_todo.yml @@ -8544,7 +8544,6 @@ - './spec/requests/api/environments_spec.rb' - './spec/requests/api/error_tracking/client_keys_spec.rb' - './spec/requests/api/error_tracking/collector_spec.rb' -- './spec/requests/api/error_tracking/project_settings_spec.rb' - './spec/requests/api/events_spec.rb' - './spec/requests/api/feature_flags_spec.rb' - './spec/requests/api/feature_flags_user_lists_spec.rb' |