Commit f45be70f authored by Dylan Griffith's avatar Dylan Griffith

Merge branch...

Merge branch '229417-20200511145545_change_variable_interpolation_format_in_common_metrics_spec-rb-spec-error-on' into 'master'

Update prometheus expected query

Closes #229417

See merge request gitlab-org/gitlab!37030
parents a7c7b257 a2dd4592
......@@ -23,9 +23,14 @@ RSpec.describe ChangeVariableInterpolationFormatInCommonMetrics, :migration do
end
it 'updates query to use {{}}' do
expected_query = 'avg(sum(container_memory_usage_bytes{container_name!="POD",' \
'pod_name=~"^{{ci_environment_slug}}-(.*)",namespace="{{kube_namespace}}"})' \
' by (job)) without (job) /1024/1024/1024'
expected_query = <<~EOS.chomp
avg(sum(container_memory_usage_bytes{container!="POD",\
pod=~"^{{ci_environment_slug}}-(.*)",namespace="{{kube_namespace}}"}) \
by (job)) without (job) /1024/1024/1024 OR \
avg(sum(container_memory_usage_bytes{container_name!="POD",\
pod_name=~"^{{ci_environment_slug}}-(.*)",namespace="{{kube_namespace}}"}) \
by (job)) without (job) /1024/1024/1024
EOS
migrate!
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment