Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'spec/requests/api/geo_spec.rb')
-rw-r--r--spec/requests/api/geo_spec.rb14
1 files changed, 13 insertions, 1 deletions
diff --git a/spec/requests/api/geo_spec.rb b/spec/requests/api/geo_spec.rb
index edbca5eb1c6..4e77fa9405c 100644
--- a/spec/requests/api/geo_spec.rb
+++ b/spec/requests/api/geo_spec.rb
@@ -10,12 +10,24 @@ RSpec.describe API::Geo do
include_context 'workhorse headers'
+ let(:non_proxy_response_schema) do
+ {
+ 'type' => 'object',
+ 'additionalProperties' => false,
+ 'required' => %w(geo_enabled),
+ 'properties' => {
+ 'geo_enabled' => { 'type' => 'boolean' }
+ }
+ }
+ end
+
context 'with valid auth' do
it 'returns empty data' do
subject
expect(response).to have_gitlab_http_status(:ok)
- expect(json_response).to be_empty
+ expect(json_response).to match_schema(non_proxy_response_schema)
+ expect(json_response['geo_enabled']).to be_falsey
end
end