Skip to content

Commit 6647d1c

Browse files
committed
(maint) Backport Gemfile and .travis.yml to 2.x
This is a partial backport and update of 03c5c4a to add travis-ci support and a Gemfile to 2.x. Right now we're not testing 2.x in travis-ci and we're experiencing spec failures because we have to install rspec-puppet from git. The best resolution for this is to consistently use a Gemfile for running tests. This commit also rewrites the .travis.yml for 2.x to only test 2.x versions against ruby 1.8.7 and Puppet < 3.0 Conflicts: .travis.yml
1 parent 755d3d2 commit 6647d1c

File tree

3 files changed

+29
-0
lines changed

3 files changed

+29
-0
lines changed

.gitignore

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,3 +2,6 @@ pkg/
22
.DS_Store
33
metadata.json
44
coverage/
5+
Gemfile.lock
6+
.bundle/
7+
vendor/bundle/

.travis.yml

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
language: ruby
2+
bundler_args: --without development
3+
script: "bundle exec rake spec SPEC_OPTS='--color --format documentation'"
4+
rvm:
5+
- 1.8.7
6+
env:
7+
- PUPPET_VERSION="~> 2.7.0"
8+
- PUPPET_VERSION=2.7.13
9+
- PUPPET_VERSION=2.7.6
10+
- PUPPET_VERSION=2.6.9
11+
notifications:
12+
email: false
13+
webhooks:
14+
urls:
15+
- https://puppet-dev-community.herokuapp.com/event/travis-ci/
16+
on_success: always
17+
on_failure: always
18+
on_start: yes

Gemfile

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
source "https://rubygems.org"
2+
3+
if puppetversion = ENV['PUPPET_VERSION']
4+
gem 'puppet', puppetversion
5+
else
6+
gem 'puppet'
7+
end
8+
gem 'puppetlabs_spec_helper', '>= 0.1.0'

0 commit comments

Comments
 (0)