Add latest changes from gitlab-org/gitlab@master

This commit is contained in:
GitLab Bot 2021-12-06 06:10:20 +00:00
parent 754d77ec69
commit fde9b7a784
11 changed files with 40 additions and 55 deletions

View File

@ -271,6 +271,7 @@
- "danger/**/*"
- "{,ee/,jh/}fixtures/**/*"
- "{,ee/,jh/}rubocop/**/*"
- ".rubocop_todo/**/*.yml"
- "{,ee/,jh/}spec/**/*"
- "{,spec/}tooling/**/*"
@ -289,6 +290,7 @@
- "vendor/assets/**/*"
- ".{eslintignore,gitattributes,nvmrc,prettierrc,stylelintrc,yamllint}"
- ".{codeclimate,eslintrc,gitlab-ci,haml-lint,haml-lint_todo,rubocop,rubocop_todo,rubocop_manual_todo}.yml"
- ".rubocop_todo/**/*.yml"
- "*_VERSION"
- "{,jh/}Gemfile{,.lock}"
- "Rakefile"
@ -312,6 +314,7 @@
- "vendor/assets/**/*"
- ".{eslintignore,gitattributes,nvmrc,prettierrc,stylelintrc,yamllint}"
- ".{codeclimate,eslintrc,gitlab-ci,haml-lint,haml-lint_todo,rubocop,rubocop_todo,rubocop_manual_todo}.yml"
- ".rubocop_todo/**/*.yml"
- "*_VERSION"
- "{,jh/}Gemfile{,.lock}"
- "Rakefile"
@ -342,6 +345,7 @@
- "vendor/assets/**/*"
- ".{eslintignore,gitattributes,nvmrc,prettierrc,stylelintrc,yamllint}"
- ".{codeclimate,eslintrc,gitlab-ci,haml-lint,haml-lint_todo,rubocop,rubocop_todo,rubocop_manual_todo}.yml"
- ".rubocop_todo/**/*.yml"
- "*_VERSION"
- "{,jh/}Gemfile{,.lock}"
- "Rakefile"
@ -368,6 +372,7 @@
- "vendor/assets/**/*"
- ".{eslintignore,gitattributes,nvmrc,prettierrc,stylelintrc,yamllint}"
- ".{codeclimate,eslintrc,gitlab-ci,haml-lint,haml-lint_todo,rubocop,rubocop_todo,rubocop_manual_todo}.yml"
- ".rubocop_todo/**/*.yml"
- "*_VERSION"
- "{,jh/}Gemfile{,.lock}"
- "Rakefile"
@ -401,6 +406,7 @@
- "vendor/assets/**/*"
- ".{eslintignore,gitattributes,nvmrc,prettierrc,stylelintrc,yamllint}"
- ".{codeclimate,eslintrc,gitlab-ci,haml-lint,haml-lint_todo,rubocop,rubocop_todo,rubocop_manual_todo}.yml"
- ".rubocop_todo/**/*.yml"
- "*_VERSION"
- "{,jh/}Gemfile{,.lock}"
- "Rakefile"

View File

@ -6,3 +6,24 @@ RSpec/TimecopFreeze:
- ee/spec/lib/gitlab/geo/log_cursor/daemon_spec.rb
- ee/spec/lib/gitlab/geo/oauth/login_state_spec.rb
- ee/spec/lib/gitlab/insights/reducers/count_per_period_reducer_spec.rb
- ee/spec/models/merge_train_spec.rb
- ee/spec/support/shared_contexts/lib/gitlab/insights/reducers/reducers_shared_contexts.rb
- qa/spec/support/repeater_spec.rb
- spec/features/users/active_sessions_spec.rb
- spec/lib/gitlab/analytics/cycle_analytics/base_query_builder_spec.rb
- spec/lib/gitlab/analytics/cycle_analytics/median_spec.rb
- spec/lib/gitlab/analytics/cycle_analytics/records_fetcher_spec.rb
- spec/lib/gitlab/auth/unique_ips_limiter_spec.rb
- spec/lib/gitlab/checks/timed_logger_spec.rb
- spec/lib/gitlab/cycle_analytics/stage_summary_spec.rb
- spec/lib/gitlab/puma_logging/json_formatter_spec.rb
- spec/lib/json_web_token/hmac_token_spec.rb
- spec/models/active_session_spec.rb
- spec/serializers/entity_date_helper_spec.rb
- spec/support/cycle_analytics_helpers/test_generation.rb
- spec/support/helpers/cycle_analytics_helpers.rb
- spec/support/helpers/javascript_fixtures_helpers.rb
- spec/support/shared_contexts/rack_attack_shared_context.rb
- spec/support/shared_examples/workers/concerns/reenqueuer_shared_examples.rb
- spec/workers/concerns/reenqueuer_spec.rb
- spec/workers/metrics/dashboard/prune_old_annotations_worker_spec.rb

View File

@ -1,5 +1,5 @@
<script>
import { GlBadge, GlTable, GlLink, GlEmptyState } from '@gitlab/ui';
import { GlBadge, GlTableLite, GlLink, GlEmptyState } from '@gitlab/ui';
import { GlSingleStat } from '@gitlab/ui/dist/charts';
import { helpPagePath } from '~/helpers/help_page_helper';
import { sprintf, s__ } from '~/locale';
@ -13,7 +13,7 @@ const defaultHeaderAttrs = {
export default {
components: {
GlBadge,
GlTable,
GlTableLite,
GlSingleStat,
GlLink,
GlEmptyState,
@ -94,7 +94,7 @@ export default {
:meta-text="devopsScoreMetrics.averageScore.scoreLevel.label"
:variant="devopsScoreMetrics.averageScore.scoreLevel.variant"
/>
<gl-table
<gl-table-lite
:fields="$options.tableHeaderFields"
:items="devopsScoreMetrics.cards"
thead-class="gl-border-t-0 gl-border-b-solid gl-border-b-1 gl-border-b-gray-100"
@ -108,7 +108,7 @@ export default {
}}</gl-badge>
</div>
</template>
</gl-table>
</gl-table-lite>
</div>
</div>
</template>

View File

@ -229,11 +229,7 @@ module Groups
end
def update_pending_builds
if Feature.enabled?(:ci_pending_builds_async_update, default_enabled: :yaml)
::Ci::PendingBuilds::UpdateGroupWorker.perform_async(group.id, pending_builds_params)
else
::Ci::UpdatePendingBuildService.new(group, pending_builds_params).execute
end
::Ci::PendingBuilds::UpdateGroupWorker.perform_async(group.id, pending_builds_params)
end
def pending_builds_params

View File

@ -245,11 +245,7 @@ module Projects
end
def update_pending_builds
if Feature.enabled?(:ci_pending_builds_async_update, default_enabled: :yaml)
::Ci::PendingBuilds::UpdateProjectWorker.perform_async(project.id, pending_builds_params)
else
::Ci::UpdatePendingBuildService.new(project, pending_builds_params).execute
end
::Ci::PendingBuilds::UpdateProjectWorker.perform_async(project.id, pending_builds_params)
end
def pending_builds_params

View File

@ -1,8 +0,0 @@
---
name: ci_pending_builds_async_update
introduced_by_url: https://gitlab.com/gitlab-org/gitlab/-/merge_requests/75197
rollout_issue_url: https://gitlab.com/gitlab-org/gitlab/-/issues/346641
milestone: '14.6'
type: development
group: group::pipeline execution
default_enabled: false

View File

@ -921,7 +921,7 @@ rspec:
- Combining reports in parent pipelines using [artifacts from child pipelines](#needspipelinejob) is
not supported. Track progress on adding support in [this issue](https://gitlab.com/gitlab-org/gitlab/-/issues/215725).
- To be able to browse the report output files, include the [`artifacts:paths`](#artifactspaths) keyword.
- To be able to browse the report output files, include the [`artifacts:paths`](#artifactspaths) keyword. Please note that this will upload and store the artifact twice.
- The test reports are collected regardless of the job results (success or failure).
You can use [`artifacts:expire_in`](#artifactsexpire_in) to set up an expiration
date for artifacts reports.

View File

@ -10,7 +10,9 @@ module Gitlab
link :buy_ci_minutes, text: 'Buy additional minutes'
link :buy_storage, text: /Purchase more storage/
strong :additional_minutes, text: 'Additional minutes'
strong :plan_minutes, text: 'Current period usage'
div :purchased_usage, 'data-testid': 'purchased-usage'
div(:plan_minutes_usage) { plan_minutes_element.following_sibling.span }
div(:additional_minutes_usage) { additional_minutes_element.following_sibling.span }
div :ci_purchase_successful_alert, text: /You have successfully purchased CI minutes/
div :storage_purchase_successful_alert, text: /You have successfully purchased a storage/

View File

@ -1,4 +1,4 @@
import { GlTable, GlBadge, GlEmptyState } from '@gitlab/ui';
import { GlTableLite, GlBadge, GlEmptyState } from '@gitlab/ui';
import { GlSingleStat } from '@gitlab/ui/dist/charts';
import { mount } from '@vue/test-utils';
import { extendedWrapper } from 'helpers/vue_test_utils_helper';
@ -20,7 +20,7 @@ describe('DevopsScore', () => {
);
};
const findTable = () => wrapper.findComponent(GlTable);
const findTable = () => wrapper.findComponent(GlTableLite);
const findEmptyState = () => wrapper.findComponent(GlEmptyState);
const findCol = (testId) => findTable().find(`[data-testid="${testId}"]`);
const findUsageCol = () => findCol('usageCol');
@ -124,11 +124,11 @@ describe('DevopsScore', () => {
describe('table columns', () => {
describe('Your usage', () => {
it('displays the corrrect value', () => {
it('displays the correct value', () => {
expect(findUsageCol().text()).toContain('3.2');
});
it('displays the corrrect badge', () => {
it('displays the correct badge', () => {
const badge = findUsageCol().find(GlBadge);
expect(badge.exists()).toBe(true);

View File

@ -814,20 +814,6 @@ RSpec.describe Groups::TransferService, :sidekiq_inline do
expect(unrelated_pending_build.namespace_id).to eq(other_project.namespace_id)
expect(unrelated_pending_build.namespace_traversal_ids).to eq(other_project.namespace.traversal_ids)
end
context 'when ci_pending_builds_async_update is disabled' do
let(:update_pending_build_service) { instance_double(::Ci::PendingBuilds::UpdateGroupWorker) }
before do
stub_feature_flags(ci_pending_builds_async_update: false)
end
it 'does not call the new worker' do
expect(::Ci::PendingBuilds::UpdateGroupWorker).not_to receive(:perform_async)
transfer_service.execute(new_parent_group)
end
end
end
end

View File

@ -189,20 +189,6 @@ RSpec.describe Projects::TransferService do
expect(unrelated_pending_build.namespace_id).to eq(other_project.namespace_id)
expect(unrelated_pending_build.namespace_traversal_ids).to eq(other_project.namespace.traversal_ids)
end
context 'when ci_pending_builds_async_update is disabled' do
let(:update_pending_build_service) { instance_double(::Ci::PendingBuilds::UpdateProjectWorker) }
before do
stub_feature_flags(ci_pending_builds_async_update: false)
end
it 'does not call the new worker' do
expect(::Ci::PendingBuilds::UpdateProjectWorker).not_to receive(:perform_async)
execute_transfer
end
end
end
end