Skip to content

OpenProject is the leading open source project management software for product, project and portfolio management. A powerful Jira alternative with agile planning, issue tracking, roadmaps, Gantt charts, time tracking, collaboration features, and more. Available on premises or in the cloud. ⭐ Star us on GitHub

Merge remote-tracking branch 'origin/dev' into implementation/42843-add-authorization-state-to-storages-api-endpoint

Andreas Pfohl57363610ba6c
diff --cc modules/storages/spec/requests/api/v3/storages/storages_spec.rb
index 568161649a2,8c5bad5b065..f773e8f2aaf
--- a/modules/storages/spec/requests/api/v3/storages/storages_spec.rb
+++ b/modules/storages/spec/requests/api/v3/storages/storages_spec.rb
@@@ -95,19 -95,8 +95,19 @@@ describe 'API v3 storages resource', wi
it_behaves_like 'successful storage response'
end
- context 'when storages module is inactive', :disable_storages do
+ context 'when storages module is inactive', with_flag: { storages_module_active: false } do
it_behaves_like 'not found'
end
+
+ context 'when Storage connected to a OAuth2 Authorization Server' do
+ subject { last_response.body }
+
+ let(:current_user) { create(:admin) }
+
+ it 'returns an error authorization state' do
+ expect(subject).to be_json_eql("urn:openproject-org:api:v3:storages:authorization:Error".to_json)
+ .at_path('_links/authorizationState/href')
+ end
+ end
end
end