From 2ee7ecc900de78ed6226cd35d44338ced87f3524 Mon Sep 17 00:00:00 2001 From: William Van Hevelingen Date: Wed, 5 Aug 2015 20:34:52 -0700 Subject: [PATCH] Fix rspec deprecation warnings --- spec/spec_helper.rb | 1 - spec/unit/collectd_version_spec.rb | 5 +++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/spec/spec_helper.rb b/spec/spec_helper.rb index 02cb7db66..cc5b7ef50 100644 --- a/spec/spec_helper.rb +++ b/spec/spec_helper.rb @@ -1,7 +1,6 @@ require 'puppetlabs_spec_helper/module_spec_helper' RSpec.configure do |c| - c.treat_symbols_as_metadata_keys_with_true_values = true c.include PuppetlabsSpec::Files c.before :each do diff --git a/spec/unit/collectd_version_spec.rb b/spec/unit/collectd_version_spec.rb index a1920dd54..c10bd67b6 100644 --- a/spec/unit/collectd_version_spec.rb +++ b/spec/unit/collectd_version_spec.rb @@ -8,14 +8,15 @@ Facter::Util::Resolution.stubs(:which).with("collectd").returns("/usr/sbin/collectd") sample_collectd_help = File.read(fixtures('facts','collectd_help')) Facter::Util::Resolution.stubs(:exec).with("collectd -h").returns(sample_collectd_help) - Facter.fact(:collectd_version).value.should == '5.1.0' + expect(Facter.fact(:collectd_version).value).to eq('5.1.0') + end it 'should be 5.1.0.git according to output' do Facter::Util::Resolution.stubs(:which).with("collectd").returns("/usr/sbin/collectd") sample_collectd_help_git = File.read(fixtures('facts','collectd_help_git')) Facter::Util::Resolution.stubs(:exec).with("collectd -h").returns(sample_collectd_help_git) - Facter.fact(:collectd_version).value.should == '5.1.0.git' + expect(Facter.fact(:collectd_version).value).to eq('5.1.0.git') end