Commit 05e2bec1 authored by 🤖 GitLab Bot 🤖's avatar 🤖 GitLab Bot 🤖 Committed by Anastasia McDonald

Dequarantine end-to-end test

Dequarantine Create Changing Gitaly repository storage when moving from Gitaly to Gitaly Cluster behaves like repository storage move confirms a `finished` status after moving project repository storage
parent 134eecdc
......@@ -24,7 +24,7 @@ module QA
Logger.debug('Getting repository storage moves')
Support::Waiter.wait_until do
with_paginated_response_body(Request.new(api_client, "/#{resource_name(resource)}_repository_storage_moves", per_page: '100').url) do |page|
get(Request.new(api_client, "/#{resource_name(resource)}_repository_storage_moves", per_page: '100').url) do |page|
break true if page.any? { |item| yield item }
end
end
......
......@@ -2,7 +2,7 @@
module QA
RSpec.describe 'Create' do
describe 'Changing Gitaly repository storage', :requires_admin do
describe 'Changing Gitaly repository storage', :requires_admin, except: { job: 'review-qa-*' } do
praefect_manager = Service::PraefectManager.new
shared_examples 'repository storage move' do
......@@ -11,12 +11,16 @@ module QA
expect { project.change_repository_storage(destination_storage[:name]) }.not_to raise_error
expect { praefect_manager.verify_storage_move(source_storage, destination_storage, repo_type: :project) }.not_to raise_error
Resource::Repository::ProjectPush.fabricate! do |push|
push.project = project
push.file_name = 'new_file'
push.file_content = '# This is a new file'
push.commit_message = 'Add new file'
push.new_branch = false
Support::Retrier.retry_on_exception(sleep_interval: 5) do
# For a short period of time after migrating, the repository can be 'read only' which may lead to errors
# 'The repository is temporarily read-only. Please try again later.'
Resource::Repository::Commit.fabricate_via_api! do |commit|
commit.project = project
commit.commit_message = 'Add new file'
commit.add_files([
{ file_path: 'new_file', content: '# This is a new file' }
])
end
end
expect(project).to have_file('README.md')
......@@ -45,7 +49,7 @@ module QA
# Note: This test doesn't have the :orchestrated tag because it runs in the Test::Integration::Praefect
# scenario with other tests that aren't considered orchestrated.
# It also runs on staging using nfs-file07 as non-cluster storage and nfs-file22 as cluster/praefect storage
context 'when moving from Gitaly to Gitaly Cluster', :requires_praefect, testcase: 'https://gitlab.com/gitlab-org/gitlab/-/quality/test_cases/347828', quarantine: { issue: 'https://gitlab.com/gitlab-org/gitlab/-/issues/284645', type: :investigating } do
context 'when moving from Gitaly to Gitaly Cluster', :requires_praefect, testcase: 'https://gitlab.com/gitlab-org/gitlab/-/quality/test_cases/347828' do
let(:source_storage) { { type: :gitaly, name: QA::Runtime::Env.non_cluster_repository_storage } }
let(:destination_storage) { { type: :praefect, name: QA::Runtime::Env.praefect_repository_storage } }
let(:project) do
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment