Skip to content

Commit

Permalink
Merge pull request #324 from ghoneycutt/fix_travis
Browse files Browse the repository at this point in the history
Fix travis
  • Loading branch information
ghoneycutt authored Aug 22, 2016
2 parents 926afb5 + dd9af35 commit 27c7dc1
Show file tree
Hide file tree
Showing 4 changed files with 20 additions and 6 deletions.
11 changes: 10 additions & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,11 +23,14 @@ env:
- PUPPET_GEM_VERSION="~> 4.0.0"
- PUPPET_GEM_VERSION="~> 4.1.0"
- PUPPET_GEM_VERSION="~> 4.2.0"
- PUPPET_GEM_VERSION="~> 4.3.0"
- PUPPET_GEM_VERSION="~> 4.4.0"
- PUPPET_GEM_VERSION="~> 4.5.0"
- PUPPET_GEM_VERSION="~> 4"

sudo: false

script: 'bundle exec metadata-json-lint metadata.json && bundle exec rake validate && bundle exec rake lint && SPEC_OPTS="--format documentation" bundle exec rake spec'
script: 'bundle exec rake validate && bundle exec rake lint && SPEC_OPTS="--format documentation" bundle exec rake spec'

matrix:
fast_finish: true
Expand All @@ -48,6 +51,12 @@ matrix:
env: PUPPET_GEM_VERSION="~> 4.1.0"
- rvm: 1.8.7
env: PUPPET_GEM_VERSION="~> 4.2.0"
- rvm: 1.8.7
env: PUPPET_GEM_VERSION="~> 4.3.0"
- rvm: 1.8.7
env: PUPPET_GEM_VERSION="~> 4.4.0"
- rvm: 1.8.7
env: PUPPET_GEM_VERSION="~> 4.5.0"
- rvm: 1.8.7
env: PUPPET_GEM_VERSION="~> 4"

Expand Down
9 changes: 7 additions & 2 deletions Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ source ENV['GEM_SOURCE'] || "https://rubygems.org"
group :development, :test do
gem 'metadata-json-lint', :require => false
gem 'rspec-puppet', :require => false
gem 'puppetlabs_spec_helper', :require => false
gem 'puppetlabs_spec_helper', '>= 1.1.1'
gem 'puppet-lint', :require => false
gem 'pry', :require => false
gem 'simplecov', :require => false
Expand All @@ -18,7 +18,12 @@ else
end

if RUBY_VERSION >= '1.8.7' and RUBY_VERSION < '2.0'
gem 'json', '~> 1.0'
# json 2.x requires ruby 2.0. Lock to 1.8
gem 'json', '~> 1.8'
# json_pure 2.0.2 requires ruby 2.0. Lock to 2.0.1
gem 'json_pure', '= 2.0.1'
else
gem 'json'
end

if facterversion = ENV['FACTER_GEM_VERSION']
Expand Down
4 changes: 2 additions & 2 deletions manifests/install.pp
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
$python = $::python::version ? {
'system' => 'python',
'pypy' => 'pypy',
default => "${python::version}",
default => "${python::version}", # lint:ignore:only_variable_string
}

$pythondev = $::osfamily ? {
Expand Down Expand Up @@ -220,8 +220,8 @@
}

package { 'gunicorn':
name => $python::gunicorn_package_name,
ensure => $gunicorn_ensure,
name => $python::gunicorn_package_name,
}
}
}
2 changes: 1 addition & 1 deletion spec/defines/pip_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@
context "adds proxy to search command if set to latest" do
let (:params) {{ :proxy => "http://my.proxy:3128", :ensure => 'latest' }}
it { is_expected.to contain_exec("pip_install_rpyc").with_command("pip wheel --help > /dev/null 2>&1 && { pip wheel --version > /dev/null 2>&1 || wheel_support_flag='--no-use-wheel'; } ; { pip --log /tmp/pip.log install --upgrade $wheel_support_flag --proxy=http://my.proxy:3128 rpyc || pip --log /tmp/pip.log install --upgrade --proxy=http://my.proxy:3128 rpyc ;}") }
it { is_expected.to contain_exec("pip_install_rpyc").with_unless('pip search --proxy=http://my.proxy:3128 rpyc | grep -i INSTALLED | grep -i latest') }
it { is_expected.to contain_exec("pip_install_rpyc").with_unless('pip search --proxy=http://my.proxy:3128 rpyc | grep -i INSTALLED.*latest') }
end
end

Expand Down

0 comments on commit 27c7dc1

Please sign in to comment.