Skip to content
This repository has been archived by the owner on Sep 24, 2019. It is now read-only.

Commit

Permalink
(maint) fix acceptance bundle
Browse files Browse the repository at this point in the history
* we can't commit a Gemfile.lock as we sweep one of our deps (rake)
  * unit test job uses bundle install not bundle update
* pin some deps here.  next major we'll require ruby > 2
  • Loading branch information
Eric Thompson committed Apr 4, 2017
1 parent 6204ccc commit a65a3d9
Show file tree
Hide file tree
Showing 3 changed files with 28 additions and 16 deletions.
2 changes: 0 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@ build/

# for a library or gem, you might want to ignore these files since the code is
# intended to run in multiple environments; otherwise, check them in:
# Gemfile.lock
# .ruby-version
# .ruby-gemset

Expand All @@ -49,7 +48,6 @@ spec/fixtures
keys
hieradata/*.eyaml

Gemfile.lock
Gemfile.local

/graphs
36 changes: 24 additions & 12 deletions Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -12,35 +12,47 @@ def location_for(place, fake_version = nil)
end
end

# unit tests: --without system_tests development
# in the Rakefile, so we require it in all groups
rake_version = '>= 0.9.0'
# this must match the default in the Rakefile, if not specified
rake_version = '~> 11.0'
if ENV['RAKE_VER']
rake_version = "~> #{ENV['RAKE_VER']}"
end

gem 'rake' , "#{rake_version}"
gem "rototiller", *location_for(ENV['TILLER_VERSION'] || '~> 0.1.0')
gem 'rspec' ,'~> 3.4.0'

group :system_tests do
gem 'beaker' ,'~> 3.0'
beaker_version = '~> 3.0'
nokogiri_version = '~> 1' # any
public_suffix_version = '~> 1' # any
activesupport_version = '~> 1' # any
# restrict gems to enable ruby versions
#
# nokogiri comes along for the ride but needs some restriction too
if Gem::Version.new(RUBY_VERSION).between?(Gem::Version.new('2.0.0'),Gem::Version.new('2.2.4'))
beaker_version = '< 3.9.0'
nokogiri_version = '< 1.7.0'
elsif Gem::Version.new(RUBY_VERSION) < Gem::Version.new('2.0.0')
beaker_version = '~> 2.0'
nokogiri_version = '~> 1' # any
public_suffix_version = '< 1.5.0'
activesupport_version = '< 5.0.0'
end
gem 'beaker' ,"#{beaker_version}"
gem 'beaker-hostgenerator'
gem 'public_suffix' ,'<= 1.4.6'
gem 'nokogiri' ,'<= 1.6.9'
gem 'nokogiri' ,"#{nokogiri_version}"
gem 'public_suffix' ,"#{public_suffix_version}"
gem 'activesupport' ,"#{activesupport_version}"
end

group :development do
gem 'simplecov'
#Documentation dependencies
gem 'yard' ,'~> 0'
gem 'markdown' ,'~> 0'
# restrict version to enable ruby 1.9.3
gem 'mime-types' ,'~> 2.0'
gem 'google-api-client' ,'<= 0.9.4'
gem 'activesupport' ,'< 5.0.0'
# restrict version to enable ruby 1.9.3 <-> 2.0.0
if Gem::Version.new(RUBY_VERSION) < Gem::Version.new('2.0.0')
gem 'public_suffix' ,'<= 1.4.6'
end
end

local_gemfile = "#{__FILE__}.local"
Expand Down
6 changes: 4 additions & 2 deletions Rakefile
Original file line number Diff line number Diff line change
Expand Up @@ -22,11 +22,13 @@ task :generate_host_config do |t, args|
sh "cat acceptance/hosts.cfg"
end

default_rake_ver = '11.0'

rototiller_task :acceptance => [:generate_host_config] do |t|
t.add_env({:name => 'LAYOUT', :default => 'centos7-64',
:message => 'The argument to pass to beaker-hostgenerator',
:set_env => true})
t.add_env({:name => 'RAKE_VER', :default => '12.0',
t.add_env({:name => 'RAKE_VER', :default => default_rake_ver,
:message => 'The rake version to use when running unit and acceptance tests',
:set_env => true})

Expand Down Expand Up @@ -72,7 +74,7 @@ end

rototiller_task :check_test do |t|
t.add_env({:name => 'SPEC_PATTERN', :default => 'spec/', :message => 'The pattern RSpec will use to find tests', :set_env => true})
t.add_env({:name => 'RAKE_VER', :default => '11.0', :message => 'The rake version to use when running unit tests', :set_env => true})
t.add_env({:name => 'RAKE_VER', :default => default_rake_ver, :message => 'The rake version to use when running unit tests', :set_env => true})
end

task :yard => [:'docs:gen']
Expand Down

0 comments on commit a65a3d9

Please sign in to comment.