summaryrefslogtreecommitdiff
path: root/spec/support/prometheus
diff options
context:
space:
mode:
authorPawel Chojnacki <pawel@chojnacki.ws>2017-06-16 14:23:33 +0200
committerPawel Chojnacki <pawel@chojnacki.ws>2017-06-16 14:34:23 +0200
commitb97d5b65dd40fb5d8753c0677534e82cb5636f2d (patch)
tree4e6fbc43e10ddbb2d1be735df5ea2224aa12d42e /spec/support/prometheus
parent0e7e7c2f2bd0e9c913cda438826a60e761130271 (diff)
downloadgitlab-ce-b97d5b65dd40fb5d8753c0677534e82cb5636f2d.tar.gz
Use include ActiveModel::Model to hold metrics data parsed from yaml.
Diffstat (limited to 'spec/support/prometheus')
-rw-r--r--spec/support/prometheus/metric_builders.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/spec/support/prometheus/metric_builders.rb b/spec/support/prometheus/metric_builders.rb
index e4b55c22acd..c8d056d3fc8 100644
--- a/spec/support/prometheus/metric_builders.rb
+++ b/spec/support/prometheus/metric_builders.rb
@@ -9,7 +9,7 @@ module Prometheus
end
def simple_metric(title: 'title', required_metrics: [], queries: [simple_query])
- Gitlab::Prometheus::Metric.new(title, required_metrics, 1, nil, queries)
+ Gitlab::Prometheus::Metric.new(title: title, required_metrics: required_metrics, weight: 1, queries: queries)
end
def simple_metrics(added_metric_name: 'metric_a')
@@ -21,7 +21,7 @@ module Prometheus
end
def simple_metric_group(name: 'name', metrics: simple_metrics)
- Gitlab::Prometheus::MetricGroup.new( name, 1, metrics)
+ Gitlab::Prometheus::MetricGroup.new(name: name, priority: 1, metrics: metrics)
end
end
end