Commit ac31877d authored by Arturo Herrero's avatar Arturo Herrero

Allow Jira issues without GitLab issues enabled

parent 8dd8e6ad
...@@ -7,7 +7,6 @@ module Projects ...@@ -7,7 +7,6 @@ module Projects
include RecordUserLastActivity include RecordUserLastActivity
before_action :check_feature_enabled! before_action :check_feature_enabled!
before_action :check_issues_available!
before_action do before_action do
push_frontend_feature_flag(:jira_integration, project) push_frontend_feature_flag(:jira_integration, project)
......
...@@ -16,20 +16,16 @@ RSpec.describe Projects::Integrations::Jira::IssuesController do ...@@ -16,20 +16,16 @@ RSpec.describe Projects::Integrations::Jira::IssuesController do
create(:jira_service, project: project) create(:jira_service, project: project)
end end
context 'when jira_integration feature disabled' do it 'renders the "index" template' do
it 'returns 404 status' do
stub_feature_flags(jira_integration: false)
get :index, params: { namespace_id: project.namespace, project_id: project } get :index, params: { namespace_id: project.namespace, project_id: project }
expect(response).to have_gitlab_http_status(:not_found) expect(response).to have_gitlab_http_status(:ok)
end expect(response).to render_template(:index)
end end
context 'when GitLab issues disabled' do context 'when jira_integration feature disabled' do
it 'returns 404 status' do it 'returns 404 status' do
project.issues_enabled = false stub_feature_flags(jira_integration: false)
project.save!
get :index, params: { namespace_id: project.namespace, project_id: project } get :index, params: { namespace_id: project.namespace, project_id: project }
...@@ -37,15 +33,6 @@ RSpec.describe Projects::Integrations::Jira::IssuesController do ...@@ -37,15 +33,6 @@ RSpec.describe Projects::Integrations::Jira::IssuesController do
end end
end end
context 'when GitLab issues enabled' do
it 'renders the "index" template' do
get :index, params: { namespace_id: project.namespace, project_id: project }
expect(response).to have_gitlab_http_status(:ok)
expect(response).to render_template(:index)
end
end
context 'when project has moved' do context 'when project has moved' do
let(:new_project) { create(:project) } let(:new_project) { create(:project) }
......
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