From 3a0e7802a8eb1ac7ff58deacea5acfd1cd06dd99 Mon Sep 17 00:00:00 2001 From: Colleen Murphy Date: Thu, 19 Mar 2015 15:12:25 -0700 Subject: [PATCH] Update tests for rspec-puppet 2 This patch uses `catalogue` instead of `subject` for the raise_error matcher since `subject` is not evaluated the way it used to be. We also unpin rspec-puppet. --- Gemfile | 1 - spec/classes/ntp_spec.rb | 4 ++-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/Gemfile b/Gemfile index 62c569397..2452d15b8 100644 --- a/Gemfile +++ b/Gemfile @@ -3,7 +3,6 @@ source ENV['GEM_SOURCE'] || "https://rubygems.org" group :development, :unit_tests do gem 'rake', :require => false gem 'rspec-core', '3.1.7', :require => false - gem 'rspec-puppet', '~> 1.0', :require => false gem 'puppetlabs_spec_helper', :require => false gem 'puppet-lint', :require => false gem 'simplecov', :require => false diff --git a/spec/classes/ntp_spec.rb b/spec/classes/ntp_spec.rb index bffcc0318..539fe6286 100644 --- a/spec/classes/ntp_spec.rb +++ b/spec/classes/ntp_spec.rb @@ -363,8 +363,8 @@ }) end - it { expect{ subject }.to raise_error( - /^The ntp module is not supported on an unsupported based system./ + it { expect{ catalogue }.to raise_error( + /The ntp module is not supported on an unsupported based system./ )} end end