2018-07-25 11:36:08 -04:00
|
|
|
# frozen_string_literal: true
|
|
|
|
|
|
|
|
require 'spec_helper'
|
|
|
|
|
|
|
|
describe InstanceStatistics::CohortsController do
|
2018-09-06 08:43:14 -04:00
|
|
|
let(:user) { create(:user) }
|
|
|
|
|
|
|
|
before do
|
|
|
|
sign_in(user)
|
|
|
|
end
|
|
|
|
|
2018-07-25 11:36:08 -04:00
|
|
|
it_behaves_like 'instance statistics availability'
|
2018-09-06 08:43:14 -04:00
|
|
|
|
|
|
|
it 'renders a 404 when the usage ping is disabled' do
|
|
|
|
stub_application_setting(usage_ping_enabled: false)
|
|
|
|
|
|
|
|
get :index
|
|
|
|
|
|
|
|
expect(response).to have_gitlab_http_status(:not_found)
|
|
|
|
end
|
2018-07-25 11:36:08 -04:00
|
|
|
end
|