Skip to content

Commit

Permalink
style(test): improve Ruby style
Browse files Browse the repository at this point in the history
  • Loading branch information
n-rodriguez committed Aug 24, 2020
1 parent 6010cc3 commit 461ce4f
Showing 1 changed file with 16 additions and 15 deletions.
31 changes: 16 additions & 15 deletions test/integration/repo/controls/packages_spec.rb
@@ -1,23 +1,24 @@
# frozen_string_literal: true

case platform[:family]
when 'redhat'
packages = %w[
prometheus2
alertmanager
node_exporter
]
when 'debian'
packages = %w[
prometheus
prometheus-alertmanager
prometheus-node-exporter
]
end

control 'prometheus packages' do
title 'should be installed'

packages =
case platform[:family]
when 'redhat'
%w[
prometheus2
alertmanager
node_exporter
]
when 'debian'
%w[
prometheus
prometheus-alertmanager
prometheus-node-exporter
]
end

packages.each do |p|
describe package(p) do
it { should be_installed }
Expand Down

0 comments on commit 461ce4f

Please sign in to comment.