From d13f592c6ad2279ad77ddadaac7d1c19be425891 Mon Sep 17 00:00:00 2001 From: Rob Reynolds Date: Wed, 4 Nov 2015 17:52:03 -0600 Subject: [PATCH 1/2] update modulesync --- .gitignore | 1 - .sync.yml | 3 ++- .travis.yml | 3 --- Gemfile | 17 +++++++++++++++++ appveyor.yml | 1 - 5 files changed, 19 insertions(+), 6 deletions(-) diff --git a/.gitignore b/.gitignore index 8fad1e9d..38f7e291 100644 --- a/.gitignore +++ b/.gitignore @@ -1,7 +1,6 @@ pkg/ Gemfile.lock Gemfile.local -vendor/ spec/fixtures/ log/ junit/ diff --git a/.sync.yml b/.sync.yml index 439784f2..0bb94724 100644 --- a/.sync.yml +++ b/.sync.yml @@ -14,13 +14,14 @@ Gemfile: ':development': - gem: rake - gem: rspec - version: '~>3.0.0' + version: '~>3.0' - gem: puppet-lint - gem: puppetlabs_spec_helper version: '~>0.10.3' - gem: puppet_facts - gem: mocha version: '~>0.10.5' + - gem: pry - gem: simplecov - gem: yard ':system_tests': diff --git a/.travis.yml b/.travis.yml index 5ac2c77f..41ffd528 100644 --- a/.travis.yml +++ b/.travis.yml @@ -18,8 +18,5 @@ matrix: env: PUPPET_GEM_VERSION="3.7.0" - rvm: 2.0.0 env: PUPPET_GEM_VERSION="3.7.0" - allow_failures: - - rvm: 2.1.5 - env: PUPPET_GEM_VERSION="~> 4.0" notifications: email: false diff --git a/Gemfile b/Gemfile index 0d3d9808..22b63e97 100644 --- a/Gemfile +++ b/Gemfile @@ -25,6 +25,16 @@ def location_for(place_or_version, fake_version = nil) end end +# The following gems are not included by default as they require DevKit on Windows. +# You should probably include them in a Gemfile.local or a ~/.gemfile +#gem 'pry' #this may already be included in the gemfile +#gem 'pry-stack_explorer', :require => false +#if RUBY_VERSION =~ /^2/ +# gem 'pry-byebug' +#else +# gem 'pry-debugger' +#end + group :development do gem 'rake', :require => false gem 'rspec', '~>3.0.0', :require => false @@ -32,6 +42,7 @@ group :development do gem 'puppetlabs_spec_helper', '~>0.10.3', :require => false gem 'puppet_facts', :require => false gem 'mocha', '~>0.10.5', :require => false + gem 'pry', :require => false gem 'simplecov', :require => false gem 'yard', :require => false end @@ -110,8 +121,14 @@ if explicitly_require_windows_gems gem "windows-pr", "1.2.3", :require => false end +# Evaluate Gemfile.local if it exists if File.exists? "#{__FILE__}.local" eval(File.read("#{__FILE__}.local"), binding) end +# Evaluate ~/.gemfile if it exists +if File.exists?(File.join(Dir.home, '.gemfile')) + eval(File.read(File.join(Dir.home, '.gemfile')), binding) +end + # vim:ft=ruby diff --git a/appveyor.yml b/appveyor.yml index 4b6144ab..ac16298c 100644 --- a/appveyor.yml +++ b/appveyor.yml @@ -26,7 +26,6 @@ matrix: fast_finish: true install: - SET PATH=C:\Ruby%RUBY_VER%\bin;%PATH% -- gem install bundler --quiet --no-ri --no-rdoc - bundle install --jobs 4 --retry 2 --without system_tests - type Gemfile.lock build: off From f6d15671a00698ceca456b81df9f9b1385718050 Mon Sep 17 00:00:00 2001 From: Rob Reynolds Date: Fri, 11 Mar 2016 16:06:04 -0600 Subject: [PATCH 2/2] (FM-4918) Restrict Rake ~> 10.1 Beaker needs a version of Rake less than 11 due to using `last_comment' in rake_task.rb:62. Reduce the version of Rake down to the same dependency that Beaker does as a development dependency. Paired with Glenn Sarti Puppet v4 needs facts to not be symbols, otherwise it causes rspec-puppet to fail with `expected Puppet::Error with message matching /expects a value for parameter 'admin_user'/, got 10.1' - gem: rspec version: '~>3.0' - gem: puppet-lint diff --git a/Gemfile b/Gemfile index 22b63e97..aa07cdef 100644 --- a/Gemfile +++ b/Gemfile @@ -36,8 +36,8 @@ end #end group :development do - gem 'rake', :require => false - gem 'rspec', '~>3.0.0', :require => false + gem 'rake', '~>10.1', :require => false + gem 'rspec', '~>3.0', :require => false gem 'puppet-lint', :require => false gem 'puppetlabs_spec_helper', '~>0.10.3', :require => false gem 'puppet_facts', :require => false diff --git a/spec/defines/config_spec.rb b/spec/defines/config_spec.rb index b1c6b607..655c5cab 100644 --- a/spec/defines/config_spec.rb +++ b/spec/defines/config_spec.rb @@ -3,7 +3,7 @@ RSpec.describe 'sqlserver::config', :type => :define do let(:title) { 'MSSQLSERVER' } - let(:facts) { {:osfamily => 'windows', :platform => :windows, :puppet_vardir => 'C:/ProgramData/PuppetLabs/puppet/var'} } + let(:facts) { {:osfamily => 'windows', :platform => 'windows', :puppet_vardir => 'C:/ProgramData/PuppetLabs/puppet/var'} } describe 'compile' do let(:params) { { diff --git a/spec/spec_helper.rb b/spec/spec_helper.rb index 9e1a07e8..7cb87359 100644 --- a/spec/spec_helper.rb +++ b/spec/spec_helper.rb @@ -7,6 +7,9 @@ RSpec.configure do |c| c.module_path = File.join(fixture_path, 'modules') c.manifest_dir = File.join(fixture_path, 'manifests') + c.expect_with :rspec do |e| + e.syntax = [:should, :expect] + end end SimpleCov.start do