diff options
author | Sarah Yasonik <syasonik@gitlab.com> | 2019-04-09 09:54:17 +0000 |
---|---|---|
committer | Douwe Maan <douwe@gitlab.com> | 2019-04-09 09:54:17 +0000 |
commit | 193e6602914a45974e5bd6e2ab12a63f91c62143 (patch) | |
tree | 5a169c8812dc7608c6c69175d7181a368d9e3286 /spec/controllers | |
parent | ca03848d212d46c72857e4ae5a698762c6958535 (diff) | |
download | gitlab-ce-193e6602914a45974e5bd6e2ab12a63f91c62143.tar.gz |
Resolve Environments#additional_metrics TypeError, ensure unix format
Diffstat (limited to 'spec/controllers')
-rw-r--r-- | spec/controllers/projects/environments_controller_spec.rb | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/spec/controllers/projects/environments_controller_spec.rb b/spec/controllers/projects/environments_controller_spec.rb index 43639875265..168c0168bba 100644 --- a/spec/controllers/projects/environments_controller_spec.rb +++ b/spec/controllers/projects/environments_controller_spec.rb @@ -419,6 +419,17 @@ describe Projects::EnvironmentsController do expect(json_response['data']).to eq({}) expect(json_response['last_update']).to eq(42) end + + context 'when time params are provided' do + it 'returns a metrics JSON document' do + additional_metrics(start: '1554702993.5398998', end: '1554717396.996232') + + expect(response).to be_ok + expect(json_response['success']).to be(true) + expect(json_response['data']).to eq({}) + expect(json_response['last_update']).to eq(42) + end + end end context 'when only one time param is provided' do |