Add latest changes from gitlab-org/gitlab@master
This commit is contained in:
parent
a2c2225d61
commit
38a4098900
32 changed files with 154 additions and 140 deletions
|
@ -25,6 +25,9 @@ module Integrations
|
|||
expose :value do |event|
|
||||
integration.event_channel_value(event)
|
||||
end
|
||||
expose :placeholder do |_event|
|
||||
integration.default_channel_placeholder
|
||||
end
|
||||
end
|
||||
|
||||
private
|
||||
|
|
|
@ -12,6 +12,7 @@ module MergeRequests
|
|||
reset_approvals_cache(merge_request)
|
||||
merge_request_activity_counter.track_approve_mr_action(user: current_user, merge_request: merge_request)
|
||||
trigger_merge_request_merge_status_updated(merge_request)
|
||||
trigger_merge_request_reviewers_updated(merge_request)
|
||||
|
||||
# Approval side effects (things not required to be done immediately but
|
||||
# should happen after a successful approval) should be done asynchronously
|
||||
|
|
|
@ -18,6 +18,7 @@ module MergeRequests
|
|||
create_note(merge_request)
|
||||
merge_request_activity_counter.track_unapprove_mr_action(user: current_user)
|
||||
trigger_merge_request_merge_status_updated(merge_request)
|
||||
trigger_merge_request_reviewers_updated(merge_request)
|
||||
end
|
||||
|
||||
success
|
||||
|
|
|
@ -0,0 +1,15 @@
|
|||
# frozen_string_literal: true
|
||||
|
||||
class AddMirrorBranchRegexToRemoteMirrors < Gitlab::Database::Migration[2.0]
|
||||
disable_ddl_transaction!
|
||||
|
||||
def up
|
||||
add_column :remote_mirrors, :mirror_branch_regex, :text
|
||||
add_text_limit :remote_mirrors, :mirror_branch_regex, 255
|
||||
end
|
||||
|
||||
def down
|
||||
remove_text_limit :remote_mirrors, :mirror_branch_regex
|
||||
remove_column :remote_mirrors, :mirror_branch_regex
|
||||
end
|
||||
end
|
|
@ -0,0 +1,12 @@
|
|||
# frozen_string_literal: true
|
||||
|
||||
class AddMirrorBranchRegexToProjectSettings < Gitlab::Database::Migration[2.0]
|
||||
enable_lock_retries!
|
||||
|
||||
# rubocop:disable Migration/AddLimitToTextColumns
|
||||
# limit is added in 20221027124848_add_text_limit_to_project_settings_mirror_branch_regex.rb
|
||||
def change
|
||||
add_column :project_settings, :mirror_branch_regex, :text
|
||||
end
|
||||
# rubocop:enable Migration/AddLimitToTextColumns
|
||||
end
|
|
@ -0,0 +1,13 @@
|
|||
# frozen_string_literal: true
|
||||
|
||||
class AddTextLimitToProjectSettingsMirrorBranchRegex < Gitlab::Database::Migration[2.0]
|
||||
disable_ddl_transaction!
|
||||
|
||||
def up
|
||||
add_text_limit :project_settings, :mirror_branch_regex, 255
|
||||
end
|
||||
|
||||
def down
|
||||
remove_text_limit :project_settings, :mirror_branch_regex
|
||||
end
|
||||
end
|
1
db/schema_migrations/20220919062640
Normal file
1
db/schema_migrations/20220919062640
Normal file
|
@ -0,0 +1 @@
|
|||
6b4e0ed9d29ace12f6ae1d4b8177ef998f9a5a3915cca80fa546a9f90ccde887
|
1
db/schema_migrations/20220926023734
Normal file
1
db/schema_migrations/20220926023734
Normal file
|
@ -0,0 +1 @@
|
|||
efa3d1c94b5de9c68ae3d007e95bbbae9582f4354e922b00a02ff5753dbe4d05
|
1
db/schema_migrations/20221027124848
Normal file
1
db/schema_migrations/20221027124848
Normal file
|
@ -0,0 +1 @@
|
|||
108dec45cbed3651aec46636a3009cb18296d0fa0ca720774dc2105123955dfd
|
|
@ -20195,9 +20195,11 @@ CREATE TABLE project_settings (
|
|||
suggested_reviewers_enabled boolean DEFAULT false NOT NULL,
|
||||
jitsu_key text,
|
||||
only_allow_merge_if_all_status_checks_passed boolean DEFAULT false NOT NULL,
|
||||
mirror_branch_regex text,
|
||||
CONSTRAINT check_2981f15877 CHECK ((char_length(jitsu_key) <= 100)),
|
||||
CONSTRAINT check_3a03e7557a CHECK ((char_length(previous_default_branch) <= 4096)),
|
||||
CONSTRAINT check_3ca5cbffe6 CHECK ((char_length(issue_branch_template) <= 255)),
|
||||
CONSTRAINT check_67292e4b99 CHECK ((char_length(mirror_branch_regex) <= 255)),
|
||||
CONSTRAINT check_b09644994b CHECK ((char_length(squash_commit_template) <= 500)),
|
||||
CONSTRAINT check_bde223416c CHECK ((show_default_award_emojis IS NOT NULL)),
|
||||
CONSTRAINT check_eaf7cfb6a7 CHECK ((char_length(merge_commit_template) <= 500))
|
||||
|
@ -20775,7 +20777,9 @@ CREATE TABLE remote_mirrors (
|
|||
only_protected_branches boolean DEFAULT false NOT NULL,
|
||||
remote_name character varying,
|
||||
error_notification_sent boolean,
|
||||
keep_divergent_refs boolean
|
||||
keep_divergent_refs boolean,
|
||||
mirror_branch_regex text,
|
||||
CONSTRAINT check_aa6b497785 CHECK ((char_length(mirror_branch_regex) <= 255))
|
||||
);
|
||||
|
||||
CREATE SEQUENCE remote_mirrors_id_seq
|
||||
|
|
|
@ -115,7 +115,7 @@ From there, you can see the following actions:
|
|||
- Instance administrator started or stopped impersonation of a group member. [Introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/300961) in GitLab 14.8.
|
||||
- Group deploy token was successfully created, revoked, or deleted. [Introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/353452) in GitLab 14.9.
|
||||
- Failed attempt to create a group deploy token. [Introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/353452) in GitLab 14.9.
|
||||
- [IP restrictions](../user/group/access_and_permissions.md#restrict-group-access-by-ip-address) changed. [Introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/358986) in GitLab 15.0.
|
||||
- [IP restrictions](../user/group/access_and_permissions.md#restrict-access-to-groups-by-ip-address) changed. [Introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/358986) in GitLab 15.0.
|
||||
- Changes to push rules. [Introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/227629) in GitLab 15.0.
|
||||
- [Introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/356152) in GitLab 15.1, changes to the following merge request approvals settings:
|
||||
- Prevent approval by author.
|
||||
|
|
|
@ -185,6 +185,41 @@ This machine's Geo node name matches a database record ... no
|
|||
Learn more about recommended site names in the description of the Name field in
|
||||
[Geo Admin Area Common Settings](../../../user/admin_area/geo_sites.md#common-settings).
|
||||
|
||||
### Reverify all uploads (or any SSF data type which is verified)
|
||||
|
||||
1. SSH into a GitLab Rails node in the primary Geo site.
|
||||
1. Open [Rails console](../../operations/rails_console.md).
|
||||
1. Mark all uploads as "pending verification":
|
||||
|
||||
WARNING:
|
||||
Commands that change data can cause damage if not run correctly or under the right conditions. Always run commands in a test environment first and have a backup instance ready to restore.
|
||||
|
||||
```ruby
|
||||
Upload.verification_state_table_class.each_batch do |relation|
|
||||
relation.update_all(verification_state: 0)
|
||||
end
|
||||
```
|
||||
|
||||
1. This will cause the primary to start checksumming all Uploads.
|
||||
1. When a primary successfully checksums a record, then all secondaries rechecksum as well, and they compare the values.
|
||||
|
||||
A similar thing can be done for all Models handled by the [Geo Self-Service Framework](../../../development/geo/framework.md) which have implemented verification:
|
||||
|
||||
- `LfsObject`
|
||||
- `MergeRequestDiff`
|
||||
- `Packages::PackageFile`
|
||||
- `Terraform::StateVersion`
|
||||
- `SnippetRepository`
|
||||
- `Ci::PipelineArtifact`
|
||||
- `PagesDeployment`
|
||||
- `Upload`
|
||||
- `Ci::JobArtifact`
|
||||
- `Ci::SecureFile`
|
||||
|
||||
NOTE:
|
||||
`GroupWikiRepository` is not in the previous list since verification is not implemented.
|
||||
There is an [issue to implement this functionality in the Admin Area UI](https://gitlab.com/gitlab-org/gitlab/-/issues/364729).
|
||||
|
||||
### Message: `WARNING: oldest xmin is far in the past` and `pg_wal` size growing
|
||||
|
||||
If a replication slot is inactive,
|
||||
|
|
|
@ -28,77 +28,6 @@ mentioned above, we recommend running these scripts under the supervision of a
|
|||
Support Engineer, who can also verify that they continue to work as they
|
||||
should and, if needed, update the script for the latest version of GitLab.
|
||||
|
||||
## Imports and exports
|
||||
|
||||
### Import a project
|
||||
|
||||
```ruby
|
||||
# Find the project and get the error
|
||||
p = Project.find_by_full_path('<username-or-group>/<project-name>')
|
||||
|
||||
p.import_error
|
||||
|
||||
# To finish the import on GitLab running version before 11.6
|
||||
p.import_finish
|
||||
|
||||
# To finish the import on GitLab running version 11.6 or after
|
||||
p.import_state.mark_as_failed("Failed manually through console.")
|
||||
```
|
||||
|
||||
### Rename imported repository
|
||||
|
||||
In a specific situation, an imported repository needed to be renamed. The Support
|
||||
Team was informed of a backup restore that failed on a single repository, which created
|
||||
the project with an empty repository. The project was successfully restored to a development
|
||||
instance, then exported, and imported into a new project under a different name.
|
||||
|
||||
The Support Team was able to transfer the incorrectly named imported project into the
|
||||
correctly named empty project using the steps below.
|
||||
|
||||
Move the new repository to the empty repository:
|
||||
|
||||
```shell
|
||||
mv /var/opt/gitlab/git-data/repositories/<group>/<new-project> /var/opt/gitlab/git-data/repositories/<group>/<empty-project>
|
||||
```
|
||||
|
||||
Make sure the permissions are correct:
|
||||
|
||||
```shell
|
||||
chown -R git:git <path-to-directory>.git
|
||||
```
|
||||
|
||||
Clear the cache:
|
||||
|
||||
```shell
|
||||
sudo gitlab-rake cache:clear
|
||||
```
|
||||
|
||||
### Export a project
|
||||
|
||||
It's typically recommended to export a project through [the web interface](../../user/project/settings/import_export.md#export-a-project-and-its-data) or through [the API](../../api/project_import_export.md). In situations where this is not working as expected, it may be preferable to export a project directly via the Rails console:
|
||||
|
||||
```ruby
|
||||
user = User.find_by_username('<username>')
|
||||
# Sufficient permissions needed
|
||||
# Read https://docs.gitlab.com/ee/user/permissions.html#project-members-permissions
|
||||
|
||||
project = Project.find_by_full_path('<username-or-group>/<project-name')
|
||||
Projects::ImportExport::ExportService.new(project, user).execute
|
||||
```
|
||||
|
||||
If this all runs successfully, you see an output like the following before being returned to the Rails console prompt:
|
||||
|
||||
```ruby
|
||||
=> nil
|
||||
```
|
||||
|
||||
The exported project is located in a `.tar.gz` file in `/var/opt/gitlab/gitlab-rails/uploads/-/system/import_export_upload/export_file/`.
|
||||
|
||||
If this fails, [enable verbose logging](../operations/rails_console.md#looking-up-database-persisted-objects),
|
||||
repeat the above procedure after,
|
||||
and report the output to
|
||||
[GitLab Support](https://about.gitlab.com/support/).
|
||||
|
||||
## Mirrors
|
||||
|
||||
### Find mirrors with "bad decrypt" errors
|
||||
|
@ -257,38 +186,6 @@ This content has been moved to [Troubleshooting Sidekiq](../sidekiq/sidekiq_trou
|
|||
|
||||
## Geo
|
||||
|
||||
### Reverify all uploads (or any SSF data type which is verified)
|
||||
|
||||
1. SSH into a GitLab Rails node in the primary Geo site.
|
||||
1. Open [Rails console](../operations/rails_console.md).
|
||||
1. Mark all uploads as "pending verification":
|
||||
|
||||
```ruby
|
||||
Upload.verification_state_table_class.each_batch do |relation|
|
||||
relation.update_all(verification_state: 0)
|
||||
end
|
||||
```
|
||||
|
||||
1. This will cause the primary to start checksumming all Uploads.
|
||||
1. When a primary successfully checksums a record, then all secondaries rechecksum as well, and they compare the values.
|
||||
|
||||
A similar thing can be done for all Models handled by the [Geo Self-Service Framework](../../development/geo/framework.md) which have implemented verification:
|
||||
|
||||
- `LfsObject`
|
||||
- `MergeRequestDiff`
|
||||
- `Packages::PackageFile`
|
||||
- `Terraform::StateVersion`
|
||||
- `SnippetRepository`
|
||||
- `Ci::PipelineArtifact`
|
||||
- `PagesDeployment`
|
||||
- `Upload`
|
||||
- `Ci::JobArtifact`
|
||||
- `Ci::SecureFile`
|
||||
|
||||
NOTE:
|
||||
`GroupWikiRepository` is not in the previous list since verification is not implemented.
|
||||
There is an [issue to implement this functionality in the Admin Area UI](https://gitlab.com/gitlab-org/gitlab/-/issues/364729).
|
||||
|
||||
### Artifacts
|
||||
|
||||
Moved to [Geo replication troubleshooting](../geo/replication/troubleshooting.md#find-failed-artifacts).
|
||||
|
|
|
@ -48,7 +48,7 @@ tier. Users can continue to access the features in a paid tier without sharing u
|
|||
### Features available in 14.4 and later
|
||||
|
||||
- [Repository size limit](../settings/account_and_limit_settings.md#repository-size-limit).
|
||||
- [Group access restriction by IP address](../../group/access_and_permissions.md#restrict-group-access-by-ip-address).
|
||||
- [Group access restriction by IP address](../../group/access_and_permissions.md#restrict-access-to-groups-by-ip-address).
|
||||
|
||||
NOTE:
|
||||
Registration is not yet required for participation, but may be added in a future milestone.
|
||||
|
|
|
@ -280,13 +280,13 @@ work in every repository. They can only be re-enabled by an administrator user o
|
|||
> - [Introduced](https://gitlab.com/gitlab-org/gitlab/-/merge_requests/87579) in GitLab 15.1 [with a flag](../../../administration/feature_flags.md) named `group_ip_restrictions_allow_global`. Disabled by default.
|
||||
> - [Generally available](https://gitlab.com/gitlab-org/gitlab/-/issues/366445) in GitLab 15.4. [Feature flag `group_ip_restrictions_allow_global`](https://gitlab.com/gitlab-org/gitlab/-/issues/366445) removed.
|
||||
|
||||
This setting allows you to set IP address ranges to be combined with group-level IP allowlists.
|
||||
It helps administrators prevent aspects of the GitLab installation from being blocked
|
||||
from working as intended when an IP allowlist is used.
|
||||
Administrators can set IP address ranges to be combined with [group-level IP restrictions](../../group/access_and_permissions.md#restrict-access-to-groups-by-ip-address).
|
||||
Use globally-allowed IP addresses to allow aspects of the GitLab installation to work even when group-level IP address
|
||||
restrictions are set.
|
||||
|
||||
For example, if the GitLab Pages daemon runs on the `10.0.0.0/24` range, specify that range in this
|
||||
field, as otherwise any group-level restrictions that don't include that range cause the Pages
|
||||
daemon to be unable to fetch artifacts from the pipeline runs.
|
||||
For example, if the GitLab Pages daemon runs on the `10.0.0.0/24` range, you can specify that range as globally-allowed.
|
||||
This means GitLab Pages can still fetch artifacts from pipelines even if group-level IP address restrictions don't
|
||||
include the `10.0.0.0/24` range.
|
||||
|
||||
To add a IP address range to the group-level allowlist:
|
||||
|
||||
|
@ -294,7 +294,7 @@ To add a IP address range to the group-level allowlist:
|
|||
1. On the top bar, select **Main menu > Admin**.
|
||||
1. On the left sidebar, select **Settings > General**.
|
||||
1. Expand the **Visibility and access controls** section.
|
||||
1. In **Globally-allowed IP ranges**, provide a value.
|
||||
1. In **Globally-allowed IP ranges**, provide IP address ranges.
|
||||
1. Select **Save changes**.
|
||||
|
||||
<!-- ## Troubleshooting
|
||||
|
|
|
@ -56,18 +56,20 @@ To change the permitted Git access protocols for a group:
|
|||
1. Choose the permitted protocols from **Enabled Git access protocols**.
|
||||
1. Select **Save changes**.
|
||||
|
||||
## Restrict group access by IP address **(PREMIUM)**
|
||||
## Restrict access to groups by IP address **(PREMIUM)**
|
||||
|
||||
> - [Introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/1985) in GitLab 12.0.
|
||||
> - [Moved](https://gitlab.com/gitlab-org/gitlab/-/issues/215410) from GitLab Ultimate to GitLab Premium in 13.1.
|
||||
|
||||
To ensure only people from your organization can access particular
|
||||
resources, you can restrict access to groups by IP address. This group-level setting
|
||||
applies to:
|
||||
To ensure only people from your organization can access particular resources, you can restrict access to groups by IP
|
||||
address. This group-level setting applies to:
|
||||
|
||||
- The GitLab UI, including subgroups, projects, and issues.
|
||||
- [In GitLab 12.3 and later](https://gitlab.com/gitlab-org/gitlab/-/issues/12874), the API.
|
||||
|
||||
Administrators can combine restricted access by IP address with
|
||||
[globally-allowed IP addresses](../admin_area/settings/visibility_and_access_controls.md#configure-globally-allowed-ip-address-ranges).
|
||||
|
||||
### Security implications
|
||||
|
||||
You should consider some security implications before configuring IP address restrictions.
|
||||
|
@ -290,5 +292,4 @@ If a user sees a 404 when they would normally expect access, and the problem is
|
|||
- `json.message`: `'Attempting to access IP restricted group'`
|
||||
- `json.allowed`: `false`
|
||||
|
||||
In viewing the log entries, compare the `remote.ip` with the list of
|
||||
[allowed IPs](#restrict-group-access-by-ip-address) for the group.
|
||||
In viewing the log entries, compare the `remote.ip` with the list of [allowed IP addresses](#restrict-access-to-groups-by-ip-address) for the group.
|
||||
|
|
|
@ -382,9 +382,9 @@ Rather than attempting to push all changes at once, this workaround:
|
|||
|
||||
### Manually execute export steps
|
||||
|
||||
Exports sometimes fail without giving enough information to troubleshoot. In these cases, it can be
|
||||
helpful to [open a rails console session](../../../administration/operations/rails_console.md#starting-a-rails-console-session)
|
||||
and loop through [all the defined exporters](https://gitlab.com/gitlab-org/gitlab/-/blob/b67a5b5a12498d57cd877023b7385f7251e57de8/app/services/projects/import_export/export_service.rb#L65).
|
||||
You usually export a project through [the web interface](#export-a-project-and-its-data) or through [the API](../../../api/project_import_export.md). Exporting using these
|
||||
methods can sometimes fail without giving enough information to troubleshoot. In these cases,
|
||||
[open a rails console session](../../../administration/operations/rails_console.md#starting-a-rails-console-session)
|
||||
Execute each line individually, rather than pasting the entire block at once, so you can see any
|
||||
errors each command returns.
|
||||
|
||||
|
@ -406,6 +406,8 @@ s.send(:compress_and_save)
|
|||
s.send(:save_upload)
|
||||
```
|
||||
|
||||
After the project is successfully uploaded, the exported project is located in a `.tar.gz` file in `/var/opt/gitlab/gitlab-rails/uploads/-/system/import_export_upload/export_file/`.
|
||||
|
||||
### Import using the REST API fails when using a group access token
|
||||
|
||||
[Group access tokens](../../group/settings/group_access_tokens.md)
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
# frozen_string_literal: true
|
||||
|
||||
module QA
|
||||
RSpec.describe 'Package', :orchestrated, :packages, :object_storage, product_group: :package_registry do
|
||||
RSpec.describe 'Package', :skip_live_env, :orchestrated, :packages, :object_storage, product_group: :package_registry do
|
||||
describe 'Helm Registry' do
|
||||
using RSpec::Parameterized::TableSyntax
|
||||
include Runtime::Fixtures
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
# frozen_string_literal: true
|
||||
|
||||
module QA
|
||||
RSpec.describe 'Package', :orchestrated, :packages, :object_storage, :reliable, product_group: :package_registry do
|
||||
RSpec.describe 'Package', :skip_live_env, :orchestrated, :packages, :object_storage, :reliable, product_group: :package_registry do
|
||||
describe 'Maven group level endpoint' do
|
||||
include Runtime::Fixtures
|
||||
include_context 'packages registry qa scenario'
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
# frozen_string_literal: true
|
||||
|
||||
module QA
|
||||
RSpec.describe 'Package', :orchestrated, :packages, :object_storage, :reliable,
|
||||
RSpec.describe 'Package', :skip_live_env, :orchestrated, :packages, :object_storage, :reliable,
|
||||
feature_flag: {
|
||||
name: 'maven_central_request_forwarding',
|
||||
scope: :global
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
# frozen_string_literal: true
|
||||
|
||||
module QA
|
||||
RSpec.describe 'Package', :orchestrated, :packages, :object_storage, product_group: :package_registry do
|
||||
RSpec.describe 'Package', :skip_live_env, :orchestrated, :packages, :object_storage, product_group: :package_registry do
|
||||
describe 'Maven Repository with Gradle' do
|
||||
using RSpec::Parameterized::TableSyntax
|
||||
include Runtime::Fixtures
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
|
||||
module QA
|
||||
RSpec.describe 'Package' do
|
||||
describe 'Package Registry', :orchestrated, :reliable, :packages, :object_storage, product_group: :package_registry do
|
||||
describe 'Package Registry', :skip_live_env, :orchestrated, :reliable, :packages, :object_storage, product_group: :package_registry do
|
||||
describe 'npm instance level endpoint' do
|
||||
using RSpec::Parameterized::TableSyntax
|
||||
include Runtime::Fixtures
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
|
||||
module QA
|
||||
RSpec.describe 'Package' do
|
||||
describe 'Package Registry', :orchestrated, :reliable, :packages, :object_storage, product_group: :package_registry do
|
||||
describe 'Package Registry', :skip_live_env, :orchestrated, :reliable, :packages, :object_storage, product_group: :package_registry do
|
||||
describe 'npm project level endpoint' do
|
||||
using RSpec::Parameterized::TableSyntax
|
||||
include Runtime::Fixtures
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
# frozen_string_literal: true
|
||||
|
||||
module QA
|
||||
RSpec.describe 'Package', :orchestrated, :packages, :object_storage, :reliable, product_group: :package_registry do
|
||||
RSpec.describe 'Package', :skip_live_env, :orchestrated, :packages, :object_storage, :reliable, product_group: :package_registry do
|
||||
describe 'NuGet group level endpoint' do
|
||||
using RSpec::Parameterized::TableSyntax
|
||||
include Runtime::Fixtures
|
||||
|
|
|
@ -1,7 +1,8 @@
|
|||
# frozen_string_literal: true
|
||||
|
||||
module QA
|
||||
RSpec.describe 'Package', :orchestrated, :packages, :object_storage, product_group: :package_registry do
|
||||
RSpec.describe 'Package', :skip_live_env, :orchestrated, :packages, :object_storage,
|
||||
product_group: :package_registry do
|
||||
describe 'NuGet project level endpoint' do
|
||||
include Support::Helpers::MaskToken
|
||||
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
# frozen_string_literal: true
|
||||
|
||||
module QA
|
||||
RSpec.describe 'Package', :orchestrated, :packages, :object_storage, product_group: :package_registry do
|
||||
RSpec.describe 'Package', :skip_live_env, :orchestrated, :packages, :object_storage, product_group: :package_registry do
|
||||
describe 'PyPI Repository' do
|
||||
include Runtime::Fixtures
|
||||
include Support::Helpers::MaskToken
|
||||
|
|
|
@ -162,6 +162,7 @@ project_setting:
|
|||
- show_diff_preview_in_email
|
||||
- suggested_reviewers_enabled
|
||||
- jitsu_key
|
||||
- mirror_branch_regex
|
||||
|
||||
build_service_desk_setting: # service_desk_setting
|
||||
unexposed_attributes:
|
||||
|
|
|
@ -35,6 +35,7 @@ RSpec.describe Integrations::EventEntity do
|
|||
expect(subject[:value]).to eq(false)
|
||||
expect(subject[:field][:name]).to eq('note_channel')
|
||||
expect(subject[:field][:value]).to eq('note-channel')
|
||||
expect(subject[:field][:placeholder]).to eq('#general, #development')
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
|
@ -40,6 +40,10 @@ RSpec.describe MergeRequests::ApprovalService do
|
|||
it 'does not publish MergeRequests::ApprovedEvent' do
|
||||
expect { service.execute(merge_request) }.not_to publish_event(MergeRequests::ApprovedEvent)
|
||||
end
|
||||
|
||||
it_behaves_like 'does not trigger GraphQL subscription mergeRequestReviewersUpdated' do
|
||||
let(:action) { service.execute(merge_request) }
|
||||
end
|
||||
end
|
||||
|
||||
context 'with an already approved MR' do
|
||||
|
@ -54,6 +58,10 @@ RSpec.describe MergeRequests::ApprovalService do
|
|||
it_behaves_like 'does not trigger GraphQL subscription mergeRequestMergeStatusUpdated' do
|
||||
let(:action) { service.execute(merge_request) }
|
||||
end
|
||||
|
||||
it_behaves_like 'does not trigger GraphQL subscription mergeRequestReviewersUpdated' do
|
||||
let(:action) { service.execute(merge_request) }
|
||||
end
|
||||
end
|
||||
|
||||
context 'with valid approval' do
|
||||
|
@ -79,6 +87,10 @@ RSpec.describe MergeRequests::ApprovalService do
|
|||
it_behaves_like 'triggers GraphQL subscription mergeRequestMergeStatusUpdated' do
|
||||
let(:action) { service.execute(merge_request) }
|
||||
end
|
||||
|
||||
it_behaves_like 'triggers GraphQL subscription mergeRequestReviewersUpdated' do
|
||||
let(:action) { service.execute(merge_request) }
|
||||
end
|
||||
end
|
||||
|
||||
context 'user cannot update the merge request' do
|
||||
|
@ -93,6 +105,10 @@ RSpec.describe MergeRequests::ApprovalService do
|
|||
it_behaves_like 'does not trigger GraphQL subscription mergeRequestMergeStatusUpdated' do
|
||||
let(:action) { service.execute(merge_request) }
|
||||
end
|
||||
|
||||
it_behaves_like 'does not trigger GraphQL subscription mergeRequestReviewersUpdated' do
|
||||
let(:action) { service.execute(merge_request) }
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
|
@ -49,6 +49,10 @@ RSpec.describe MergeRequests::RemoveApprovalService do
|
|||
it_behaves_like 'triggers GraphQL subscription mergeRequestMergeStatusUpdated' do
|
||||
let(:action) { execute! }
|
||||
end
|
||||
|
||||
it_behaves_like 'triggers GraphQL subscription mergeRequestReviewersUpdated' do
|
||||
let(:action) { execute! }
|
||||
end
|
||||
end
|
||||
|
||||
context 'with a user who has not approved' do
|
||||
|
@ -69,6 +73,10 @@ RSpec.describe MergeRequests::RemoveApprovalService do
|
|||
it_behaves_like 'does not trigger GraphQL subscription mergeRequestMergeStatusUpdated' do
|
||||
let(:action) { execute! }
|
||||
end
|
||||
|
||||
it_behaves_like 'does not trigger GraphQL subscription mergeRequestReviewersUpdated' do
|
||||
let(:action) { execute! }
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
|
@ -7,7 +7,7 @@ require (
|
|||
github.com/BurntSushi/toml v1.2.1
|
||||
github.com/FZambia/sentinel v1.1.1
|
||||
github.com/alecthomas/chroma/v2 v2.3.0
|
||||
github.com/aws/aws-sdk-go v1.44.121
|
||||
github.com/aws/aws-sdk-go v1.44.126
|
||||
github.com/disintegration/imaging v1.6.2
|
||||
github.com/getsentry/raven-go v0.2.0
|
||||
github.com/golang-jwt/jwt/v4 v4.4.2
|
||||
|
|
|
@ -180,8 +180,8 @@ github.com/aws/aws-sdk-go v1.15.27/go.mod h1:mFuSZ37Z9YOHbQEwBWztmVzqXrEkub65tZo
|
|||
github.com/aws/aws-sdk-go v1.17.4/go.mod h1:KmX6BPdI08NWTb3/sm4ZGu5ShLoqVDhKgpiN924inxo=
|
||||
github.com/aws/aws-sdk-go v1.37.0/go.mod h1:hcU610XS61/+aQV88ixoOzUoG7v3b31pl2zKMmprdro=
|
||||
github.com/aws/aws-sdk-go v1.43.31/go.mod h1:y4AeaBuwd2Lk+GepC1E9v0qOiTws0MIWAX4oIKwKHZo=
|
||||
github.com/aws/aws-sdk-go v1.44.121 h1:ahBRUqUp4qLyGmSM5KKn+TVpZkRmtuLxTWw+6Hq/ebs=
|
||||
github.com/aws/aws-sdk-go v1.44.121/go.mod h1:y4AeaBuwd2Lk+GepC1E9v0qOiTws0MIWAX4oIKwKHZo=
|
||||
github.com/aws/aws-sdk-go v1.44.126 h1:7HQJw2DNiwpxqMe2H7odGNT2rhO4SRrUe5/8dYXl0Jk=
|
||||
github.com/aws/aws-sdk-go v1.44.126/go.mod h1:y4AeaBuwd2Lk+GepC1E9v0qOiTws0MIWAX4oIKwKHZo=
|
||||
github.com/aws/aws-sdk-go-v2 v1.16.2 h1:fqlCk6Iy3bnCumtrLz9r3mJ/2gUT0pJ0wLFVIdWh+JA=
|
||||
github.com/aws/aws-sdk-go-v2 v1.16.2/go.mod h1:ytwTPBG6fXTZLxxeeCCWj2/EMYp/xDUgX+OET6TLNNU=
|
||||
github.com/aws/aws-sdk-go-v2/aws/protocol/eventstream v1.4.1 h1:SdK4Ppk5IzLs64ZMvr6MrSficMtjY2oS0WOORXTlxwU=
|
||||
|
|
Loading…
Reference in a new issue