diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2022-02-18 09:45:46 +0000 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2022-02-18 09:45:46 +0000 |
commit | a7b3560714b4d9cc4ab32dffcd1f74a284b93580 (patch) | |
tree | 7452bd5c3545c2fa67a28aa013835fb4fa071baf /spec/controllers/projects/mirrors_controller_spec.rb | |
parent | ee9173579ae56a3dbfe5afe9f9410c65bb327ca7 (diff) | |
download | gitlab-ce-a7b3560714b4d9cc4ab32dffcd1f74a284b93580.tar.gz |
Add latest changes from gitlab-org/gitlab@14-8-stable-eev14.8.0-rc42
Diffstat (limited to 'spec/controllers/projects/mirrors_controller_spec.rb')
-rw-r--r-- | spec/controllers/projects/mirrors_controller_spec.rb | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/spec/controllers/projects/mirrors_controller_spec.rb b/spec/controllers/projects/mirrors_controller_spec.rb index 7c5d14d3a22..7bc86d7c583 100644 --- a/spec/controllers/projects/mirrors_controller_spec.rb +++ b/spec/controllers/projects/mirrors_controller_spec.rb @@ -7,7 +7,7 @@ RSpec.describe Projects::MirrorsController do shared_examples 'only admin is allowed when mirroring is disabled' do let(:subject_action) { raise 'subject_action is required' } - let(:user) { project.owner } + let(:user) { project.first_owner } let(:project_settings_path) { project_settings_repository_path(project, anchor: 'js-push-remote-settings') } context 'when project mirroring is enabled' do @@ -88,7 +88,7 @@ RSpec.describe Projects::MirrorsController do context 'when the current project is not a mirror' do it 'allows to create a remote mirror' do - sign_in(project.owner) + sign_in(project.first_owner) expect do do_put(project, remote_mirrors_attributes: { '0' => { 'enabled' => 1, 'url' => 'http://foo.com' } }) @@ -106,7 +106,7 @@ RSpec.describe Projects::MirrorsController do end it 'processes a successful update' do - sign_in(project.owner) + sign_in(project.first_owner) do_put(project, remote_mirrors_attributes: { '0' => ssh_mirror_attributes }) expect(response).to redirect_to(project_settings_repository_path(project, anchor: 'js-push-remote-settings')) @@ -126,7 +126,7 @@ RSpec.describe Projects::MirrorsController do let(:project) { create(:project, :repository, :remote_mirror) } before do - sign_in(project.owner) + sign_in(project.first_owner) end context 'With valid URL for a push' do @@ -169,7 +169,7 @@ RSpec.describe Projects::MirrorsController do let(:cache) { SshHostKey.new(project: project, url: "ssh://example.com:22") } before do - sign_in(project.owner) + sign_in(project.first_owner) end context 'invalid URLs' do |