3836d69119
Partially addresses #47424. Had to make changes to spec files because stubbing methods on frozen objects is a mess in RSpec and leads to failures: https://github.com/rspec/rspec-mocks/issues/1190
14 lines
336 B
Ruby
14 lines
336 B
Ruby
# frozen_string_literal: true
|
|
|
|
module API
|
|
class Version < Grape::API
|
|
before { authenticate! }
|
|
|
|
desc 'Get the version information of the GitLab instance.' do
|
|
detail 'This feature was introduced in GitLab 8.13.'
|
|
end
|
|
get '/version' do
|
|
{ version: Gitlab::VERSION, revision: Gitlab.revision }
|
|
end
|
|
end
|
|
end
|