Add latest changes from gitlab-org/gitlab@master

This commit is contained in:
GitLab Bot 2020-09-24 03:09:48 +00:00
parent 28b18e348c
commit 5ff6f278d3
14 changed files with 59 additions and 31 deletions

View file

@ -86,6 +86,7 @@ export default () => {
boardId: $boardApp.dataset.boardId,
groupId: Number($boardApp.dataset.groupId) || null,
rootPath: $boardApp.dataset.rootPath,
canUpdate: $boardApp.dataset.canUpdate,
},
store,
apolloProvider,

View file

@ -1,6 +1,6 @@
- page_title _("CI Lint")
- page_description _("Validate your GitLab CI configuration file")
- unless Feature.enabled?(:monaco_ci)
- unless Feature.enabled?(:monaco_ci, default_enabled: true)
- content_for :library_javascripts do
= page_specific_javascript_tag('lib/ace.js')
@ -17,7 +17,7 @@
.file-holder
.js-file-title.file-title.clearfix
= _("Contents of .gitlab-ci.yml")
- if Feature.enabled?(:monaco_ci)
- if Feature.enabled?(:monaco_ci, default_enabled: true)
.file-editor.code
.js-edit-mode-pane.qa-editor#editor{ data: { 'editor-loading': true } }<
%pre.editor-loading-content= params[:content]

View file

@ -0,0 +1,5 @@
---
title: Replaced ACE with Editor Lite for CI linting
merge_request: 42814
author:
type: added

View file

@ -0,0 +1,5 @@
---
title: Migrate Recover hidden stage dropdown
merge_request: 43032
author:
type: other

View file

@ -1,7 +1,7 @@
---
name: build_service_proxy
introduced_by_url:
rollout_issue_url:
group:
introduced_by_url: https://gitlab.com/gitlab-org/gitlab/-/merge_requests/9723
rollout_issue_url:
group: group::editor
type: development
default_enabled: false

View file

@ -1,7 +1,7 @@
---
name: monaco_ci
introduced_by_url:
rollout_issue_url:
group:
introduced_by_url: https://gitlab.com/gitlab-org/gitlab/-/merge_requests/23666
rollout_issue_url: https://gitlab.com/gitlab-org/gitlab/-/issues/249137
group: group::editor
type: development
default_enabled: false
default_enabled: true

View file

@ -1,7 +1,7 @@
---
name: resource_access_token
introduced_by_url:
rollout_issue_url:
group:
introduced_by_url: https://gitlab.com/gitlab-org/gitlab/-/merge_requests/29622
rollout_issue_url: https://gitlab.com/gitlab-org/gitlab/-/issues/235765
group: group::access
type: development
default_enabled: true

View file

@ -1,7 +1,7 @@
---
name: snippet_multiple_files
introduced_by_url:
rollout_issue_url:
group:
introduced_by_url: https://gitlab.com/gitlab-org/gitlab/-/merge_requests/32416
rollout_issue_url: https://gitlab.com/gitlab-org/gitlab/-/issues/217809
group: group::editor
type: development
default_enabled: false

View file

@ -122,7 +122,6 @@ graph RL;
click 2_2-5 "https://app.periscopedata.com/app/gitlab/652085/Engineering-Productivity---Pipeline-Build-Durations?widget=8404303&udv=0"
subgraph "Needs `setup-test-env` & `compile-test-assets`";
2_2-2 & 2_2-4 & 2_2-5 --> 1-6 & 1-3;
2_2-3 --> 1-6 & 1-4;
end
2_3-1["build-assets-image (2.5 minutes)"];
@ -228,7 +227,6 @@ graph RL;
click 2_2-5 "https://app.periscopedata.com/app/gitlab/652085/Engineering-Productivity---Pipeline-Build-Durations?widget=8404303&udv=0"
subgraph "Needs `setup-test-env` & `compile-test-assets`";
2_2-2 & 2_2-4 & 2_2-5 --> 1-6 & 1-3;
2_2-3 --> 1-6 & 1-4;
end
2_3-1["build-assets-image (2.5 minutes)"];

View file

@ -5,13 +5,13 @@ info: To determine the technical writer assigned to the Stage/Group associated w
type: reference, howto
---
# Test Coverage Visualization **(CORE ONLY)**
# Test Coverage Visualization
> - [Introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/3708) in GitLab 12.9.
> - [Feature flag enabled](https://gitlab.com/gitlab-org/gitlab/-/issues/211410) in GitLab 13.4.
> - It's enabled on GitLab.com.
> - It can be disabled per-project.
> - To use it in GitLab self-managed instances, ask a GitLab administrator to [enable it](#enabling-the-feature). **(CORE ONLY)**
> - For GitLab self-managed instances, GitLab administrators can opt to [disable it](#enable-or-disable-code-coverage-visualization). **(CORE ONLY)**
With the help of [GitLab CI/CD](../../../ci/README.md), you can collect the test
coverage information of your favorite testing or coverage-analysis tool, and visualize
@ -74,21 +74,12 @@ test:
cobertura: coverage/cobertura-coverage.xml
```
## Enabling the feature
## Enable or disable code coverage visualization
This feature comes with the `:coverage_report_view` feature flag enabled by
default. It is enabled on GitLab.com. [GitLab administrators with access to the GitLab Rails console](../../../administration/feature_flags.md)
can disable it for your instance. Test coverage visualization can be enabled or disabled per-project.
To enable it:
```ruby
# Instance-wide
Feature.enable(:coverage_report_view)
# or by project
Feature.enable(:coverage_report_view, Project.find(<project id>))
```
To disable it:
```ruby
@ -97,3 +88,12 @@ Feature.disable(:coverage_report_view)
# or by project
Feature.disable(:coverage_report_view, Project.find(<project id>))
```
To enable it:
```ruby
# Instance-wide
Feature.enable(:coverage_report_view)
# or by project
Feature.enable(:coverage_report_view, Project.find(<project id>))
```

View file

@ -45,7 +45,7 @@ module Gitlab
# made globally available to the frontend
push_frontend_feature_flag(:snippets_vue, default_enabled: true)
push_frontend_feature_flag(:monaco_blobs, default_enabled: true)
push_frontend_feature_flag(:monaco_ci, default_enabled: false)
push_frontend_feature_flag(:monaco_ci, default_enabled: true)
push_frontend_feature_flag(:snippets_edit_vue, default_enabled: true)
push_frontend_feature_flag(:webperf_experiment, default_enabled: false)
push_frontend_feature_flag(:snippets_binary_blob, default_enabled: false)

View file

@ -24,6 +24,8 @@ module Gitlab
AssetMissingError = Class.new(StandardError)
class << self
include Gitlab::Utils::StrongMemoize
def entrypoint_paths(source)
raise WebpackError, manifest["errors"] unless manifest_bundled?
@ -55,6 +57,10 @@ module Gitlab
end
end
def clear_manifest!
clear_memoization(:manifest)
end
private
def manifest_bundled?
@ -67,7 +73,7 @@ module Gitlab
load_manifest
else
# ... otherwise cache at class level, as JSON loading/parsing can be expensive
@manifest ||= load_manifest
strong_memoize(:manifest) { load_manifest }
end
end

View file

@ -1014,6 +1014,11 @@ msgid_plural "%d Days"
msgstr[0] ""
msgstr[1] ""
msgid "1 Issue"
msgid_plural "%d Issues"
msgstr[0] ""
msgstr[1] ""
msgid "1 closed issue"
msgid_plural "%{issues} closed issues"
msgstr[0] ""

View file

@ -16,6 +16,14 @@ RSpec.describe Gitlab::Webpack::Manifest do
EOF
end
around do |example|
Gitlab::Webpack::Manifest.clear_manifest!
example.run
Gitlab::Webpack::Manifest.clear_manifest!
end
shared_examples_for "a valid manifest" do
it "returns single entry asset paths from the manifest" do
expect(Gitlab::Webpack::Manifest.asset_paths("entry2")).to eq(["/public_path/entry2.js"])