From 466534425096ccc19947d4b7ebc281a50297ec3e Mon Sep 17 00:00:00 2001 From: Melissa Stone Date: Mon, 30 Apr 2018 14:25:42 -0700 Subject: (maint) PDK manages certain files Certain files, like the Gemfile and spec/spec_helper.rb are managed by PDK. When we run `pdk update`, any changes we make to these files will be overwritten. --- spec/spec_helper.rb | 14 -------------- spec/spec_helper_local.rb | 13 +++++++++++++ 2 files changed, 13 insertions(+), 14 deletions(-) create mode 100644 spec/spec_helper_local.rb (limited to 'spec') diff --git a/spec/spec_helper.rb b/spec/spec_helper.rb index 9885e2d..efd225b 100644 --- a/spec/spec_helper.rb +++ b/spec/spec_helper.rb @@ -28,17 +28,3 @@ end RSpec.configure do |c| c.default_facts = default_facts end - -dir = File.expand_path(File.dirname(__FILE__)) -$LOAD_PATH.unshift File.join(dir, 'lib') - -# So everyone else doesn't have to include this base constant. -module PuppetSpec - FIXTURE_DIR = File.join(File.expand_path(File.dirname(__FILE__)), 'fixtures') unless defined?(FIXTURE_DIR) -end - -require 'puppet_spec/files' - -Pathname.glob("#{dir}/shared_behaviours/**/*.rb") do |behaviour| - require behaviour.relative_path_from(Pathname.new(dir)) -end diff --git a/spec/spec_helper_local.rb b/spec/spec_helper_local.rb new file mode 100644 index 0000000..0fcc231 --- /dev/null +++ b/spec/spec_helper_local.rb @@ -0,0 +1,13 @@ +dir = File.expand_path(File.dirname(__FILE__)) +$LOAD_PATH.unshift File.join(dir, 'lib') + +# So everyone else doesn't have to include this base constant. +module PuppetSpec + FIXTURE_DIR = File.join(File.expand_path(File.dirname(__FILE__)), 'fixtures') unless defined?(FIXTURE_DIR) +end + +require 'puppet_spec/files' + +Pathname.glob("#{dir}/shared_behaviours/**/*.rb") do |behaviour| + require behaviour.relative_path_from(Pathname.new(dir)) +end -- cgit v1.2.3