Showing with 91 additions and 39 deletions.
  1. +1 −1 .fixtures.yml
  2. +53 −19 .travis.yml
  3. +3 −0 CHANGELOG
  4. +18 −7 Gemfile
  5. +1 −1 README.md
  6. +1 −0 Rakefile
  7. +1 −1 metadata.json
  8. +1 −1 tests/domain.pp
  9. +1 −1 tests/init.pp
  10. +1 −1 tests/path.pp
  11. +5 −3 tests/search.pp
  12. +5 −4 tests/stuff.pp
2 changes: 1 addition & 1 deletion .fixtures.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
fixtures:
repositories:
'stdlib':
repo: 'git://github.com/puppetlabs/puppetlabs-stdlib.git'
repo: 'https://github.com/puppetlabs/puppetlabs-stdlib.git'
ref: '4.6.0'
symlinks:
'dnsclient': "#{source_dir}"
72 changes: 53 additions & 19 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,45 +6,79 @@ rvm:
- 1.9.3
- 2.0.0
- 2.1.0
- 2.3.1

env:
matrix:
- PUPPET_GEM_VERSION="~> 3.1"
- PUPPET_GEM_VERSION="~> 3.2"
- PUPPET_GEM_VERSION="~> 3.3"
- PUPPET_GEM_VERSION="~> 3.4"
- PUPPET_GEM_VERSION="~> 3.5"
- PUPPET_GEM_VERSION="~> 3.6"
- PUPPET_GEM_VERSION="~> 3.7"
- PUPPET_GEM_VERSION="~> 3.8"
- PUPPET_GEM_VERSION="~> 3" PARSER="future"
- PUPPET_GEM_VERSION="~> 4.0"
- PUPPET_GEM_VERSION="~> 4.1"
- PUPPET_GEM_VERSION="~> 3.1.0"
- PUPPET_GEM_VERSION="~> 3.2.0"
- PUPPET_GEM_VERSION="~> 3.3.0"
- PUPPET_GEM_VERSION="~> 3.4.0"
- PUPPET_GEM_VERSION="~> 3.5.0"
- PUPPET_GEM_VERSION="~> 3.6.0"
- PUPPET_GEM_VERSION="~> 3.7.0"
- PUPPET_GEM_VERSION="~> 3.8.0"
- PUPPET_GEM_VERSION="~> 3" FUTURE_PARSER="yes"
- 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.6.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
exclude:
- rvm: 2.0.0
env: PUPPET_GEM_VERSION="~> 3.1"
env: PUPPET_GEM_VERSION="~> 3.1.0"
- rvm: 2.1.0
env: PUPPET_GEM_VERSION="~> 3.1"
env: PUPPET_GEM_VERSION="~> 3.1.0"
- rvm: 2.1.0
env: PUPPET_GEM_VERSION="~> 3.2"
env: PUPPET_GEM_VERSION="~> 3.2.0"
- rvm: 2.1.0
env: PUPPET_GEM_VERSION="~> 3.3"
env: PUPPET_GEM_VERSION="~> 3.3.0"
- rvm: 2.1.0
env: PUPPET_GEM_VERSION="~> 3.4"
env: PUPPET_GEM_VERSION="~> 3.4.0"
- rvm: 1.8.7
env: PUPPET_GEM_VERSION="~> 4.0"
env: PUPPET_GEM_VERSION="~> 4.0.0"
- rvm: 1.8.7
env: PUPPET_GEM_VERSION="~> 4.1"
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.6.0"
- rvm: 1.8.7
env: PUPPET_GEM_VERSION="~> 4"
- rvm: 2.3.1
env: PUPPET_GEM_VERSION="~> 3.1.0"
- rvm: 2.3.1
env: PUPPET_GEM_VERSION="~> 3.2.0"
- rvm: 2.3.1
env: PUPPET_GEM_VERSION="~> 3.3.0"
- rvm: 2.3.1
env: PUPPET_GEM_VERSION="~> 3.4.0"
- rvm: 2.3.1
env: PUPPET_GEM_VERSION="~> 3.5.0"
- rvm: 2.3.1
env: PUPPET_GEM_VERSION="~> 3.6.0"
- rvm: 2.3.1
env: PUPPET_GEM_VERSION="~> 3.7.0"
- rvm: 2.3.1
env: PUPPET_GEM_VERSION="~> 3.8.0"
- rvm: 2.3.1
env: PUPPET_GEM_VERSION="~> 3" FUTURE_PARSER="yes"

notifications:
email: false
3 changes: 3 additions & 0 deletions CHANGELOG
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
3.4.0 - 2015-05-27
* Support Puppet v4 and v3 with future parser

3.0.4 - 2013-06-08 Garrett Honeycutt <code@garretthoneycutt.com>
* Fix warnings by using @ in front of variables in template
* .fixtures.yml is tracking correct version of puppetlabs/stdlib
Expand Down
25 changes: 18 additions & 7 deletions Gemfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
source 'https://rubygems.org'
source ENV['GEM_SOURCE'] || 'https://rubygems.org'

if puppetversion = ENV['PUPPET_GEM_VERSION']
gem 'puppet', puppetversion, :require => false
Expand All @@ -7,12 +7,23 @@ else
end

gem 'metadata-json-lint'
gem 'puppetlabs_spec_helper', '>= 0.1.0'
gem 'puppet-lint', '>= 1.0.0'
gem 'puppetlabs_spec_helper', '>= 1.2.0'
gem 'facter', '>= 1.7.0'
gem 'rspec-puppet'
gem 'puppet-lint', '>= 1.0', '< 3.0'
gem 'puppet-lint-absolute_classname-check'
gem 'puppet-lint-alias-check'
gem 'puppet-lint-empty_string-check'
gem 'puppet-lint-file_ensure-check'
gem 'puppet-lint-file_source_rights-check'
gem 'puppet-lint-leading_zero-check'
gem 'puppet-lint-spaceship_operator_without_tag-check'
gem 'puppet-lint-trailing_comma-check'
gem 'puppet-lint-undef_in_function-check'
gem 'puppet-lint-unquoted_string-check'
gem 'puppet-lint-variable_contains_upcase'

# rspec must be v2 for ruby 1.8.7
if RUBY_VERSION >= '1.8.7' and RUBY_VERSION < '1.9'
gem 'rspec', '~> 2.0'
end
gem 'rspec', '~> 2.0' if RUBY_VERSION >= '1.8.7' and RUBY_VERSION < '1.9'
gem 'rake', '~> 10.0' if RUBY_VERSION >= '1.8.7' and RUBY_VERSION < '1.9'
gem 'json', '<= 1.8' if RUBY_VERSION < '2.0.0'
gem 'json_pure', '<= 2.0.1' if RUBY_VERSION < '2.0.0'
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ code with no modifications to the module itself as a guiding principle.

This module has been tested to work on the following systems with Puppet v3
(with and without the future parser) and Puppet v4 with Ruby versions 1.8.7,
1.9.3, 2.0.0 and 2.1.0.
1.9.3, 2.0.0, 2.1.0 and 2.3.1.

* EL 5
* EL 6
Expand Down
1 change: 1 addition & 0 deletions Rakefile
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
require 'puppetlabs_spec_helper/rake_tasks'
require 'puppet-lint/tasks/puppet-lint'
PuppetLint.configuration.send('disable_80chars')
PuppetLint.configuration.send('disable_140chars')
PuppetLint.configuration.relative = true
PuppetLint.configuration.ignore_paths = ["spec/**/*.pp", "pkg/**/*.pp"]

Expand Down
2 changes: 1 addition & 1 deletion metadata.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "ghoneycutt-dnsclient",
"version": "3.4.0",
"version": "3.5.0",
"author": "ghoneycutt",
"summary": "Manage resolver",
"license": "Apache-2.0",
Expand Down
2 changes: 1 addition & 1 deletion tests/domain.pp
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
class { 'dnsclient':
class { '::dnsclient':
domain => 'example.tld',
}
2 changes: 1 addition & 1 deletion tests/init.pp
Original file line number Diff line number Diff line change
@@ -1 +1 @@
include dnsclient
include ::dnsclient
2 changes: 1 addition & 1 deletion tests/path.pp
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
class { 'dnsclient':
class { '::dnsclient':
resolver_config_file => '/tmp/resolv.conf',
resolver_config_file_group => 'wheel',
}
8 changes: 5 additions & 3 deletions tests/search.pp
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
class { 'dnsclient':
search => [ 'foo.example.tld',
'example.tld' ],
class { '::dnsclient':
search => [
'foo.example.tld',
'example.tld',
],
}
9 changes: 5 additions & 4 deletions tests/stuff.pp
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
class { 'dnsclient':
nameservers => [ '4.2.2.2',
'4.2.2.1' ],
# domain => '-invalid.tld',
class { '::dnsclient':
nameservers => [
'4.2.2.2',
'4.2.2.1',
],
domain => 'valid-domain.tld',
resolver_config_file_ensure => 'present',
resolver_config_file_group => 'wheel',
Expand Down