Skip to content

Commit

Permalink
Fix Rakefile to enforce failure on warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
blkperl committed Apr 4, 2015
1 parent 85b646e commit 70eb150
Show file tree
Hide file tree
Showing 13 changed files with 30 additions and 27 deletions.
2 changes: 1 addition & 1 deletion Rakefile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
require 'puppetlabs_spec_helper/rake_tasks'
require 'puppet-lint/tasks/puppet-lint'

PuppetLint.configuration.fail_on_warnings
PuppetLint.configuration.fail_on_warnings = true
PuppetLint.configuration.send('disable_80chars')
PuppetLint.configuration.send('disable_class_inherits_from_params_class')
PuppetLint.configuration.send('disable_class_parameter_defaults')
Expand Down
1 change: 1 addition & 0 deletions manifests/plugin/curl_json.pp
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
$url,
$instance,
$keys,
$ensure = present,
$user = undef,
$password = undef,
$order = '10',
Expand Down
2 changes: 1 addition & 1 deletion manifests/plugin/exec.pp
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,8 @@

# This is deprecated file naming ensuring old style file removed, and should be removed in next major relese
file { "${name}.load-deprecated":
path => "${conf_dir}/${name}.conf",
ensure => absent,
path => "${conf_dir}/${name}.conf",
}
# End deprecation

Expand Down
4 changes: 2 additions & 2 deletions manifests/plugin/genericjmx/connection.pp
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
# https://collectd.org/wiki/index.php/Plugin:GenericJMX
define collectd::plugin::genericjmx::connection (
$host = $name,
$collect,
$service_url,
$host = $name,
$user = undef,
$password = undef,
$instance_prefix = undef,
$collect,
) {
include collectd::plugin::genericjmx
concat::fragment { "collectd_plugin_genericjmx_conf_${name}":
Expand Down
2 changes: 1 addition & 1 deletion manifests/plugin/genericjmx/mbean.pp
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
# https://collectd.org/wiki/index.php/Plugin:GenericJMX
define collectd::plugin::genericjmx::mbean (
$object_name,
$values,
$instance_prefix = undef,
$instance_from = undef,
$values,
) {
include collectd::plugin::genericjmx
validate_array($values)
Expand Down
1 change: 1 addition & 0 deletions manifests/plugin/mysql.pp
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
# MySQL plugin
# https://collectd.org/wiki/index.php/Plugin:MySQL
class collectd::plugin::mysql (
$ensure = present,
$interval = undef,
){

Expand Down
1 change: 1 addition & 0 deletions manifests/plugin/ping.pp
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
# See http://collectd.org/documentation/manpages/collectd.conf.5.shtml#plugin_ping
define collectd::plugin::ping (
$hosts,
$ensure = present,
$interval = undef,
$timeout = undef,
$ttl = undef,
Expand Down
6 changes: 3 additions & 3 deletions manifests/plugin/snmp/data.pp
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
# https://collectd.org/wiki/index.php/Plugin:SNMP
define collectd::plugin::snmp::data (
$ensure = present,
$type,
$table = false,
$instance,
$type,
$values,
$ensure = present,
$table = false,
) {
include collectd
include collectd::plugin::snmp
Expand Down
2 changes: 1 addition & 1 deletion manifests/plugin/snmp/host.pp
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
# https://collectd.org/wiki/index.php/Plugin:SNMP
define collectd::plugin::snmp::host (
$collect,
$ensure = present,
$address = $name,
$version = 1,
$community = 'public',
$collect,
$interval = undef,
) {
include collectd
Expand Down
2 changes: 1 addition & 1 deletion tests/plugins/iptables.pp
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
include collectd

class { 'collectd::plugin::iptables':
chains => {
chains => {
'nat' => 'In_SSH',
'filter' => 'HTTP'
},
Expand Down
8 changes: 4 additions & 4 deletions tests/plugins/mysql.pp
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
include collectd

collectd::plugin::mysql::database { 'puppetdb':
host => 'localhost',
username => 'stahmna',
password => 'yermom',
port => '3306',
host => 'localhost',
username => 'stahmna',
password => 'yermom',
port => '3306',
}
20 changes: 10 additions & 10 deletions tests/plugins/perl.pp
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,8 @@
destination => '/tmp',
order => 99,
config => {
'foo' => 'bar',
'key' => [ 'val1', 'val2' ],
'foo' => 'bar',
'key' => [ 'val1', 'val2' ],
}
}

Expand All @@ -37,17 +37,17 @@

collectd::plugin::perl::plugin {
'baar':
module => 'Collectd::Plugins::Bar',
provider => 'package',
source => 'perl-Collectd-Plugins-Bar',
config => {
'foo' => 'bar',
'more' => {
module => 'Collectd::Plugins::Bar',
provider => 'package',
source => 'perl-Collectd-Plugins-Bar',
config => {
'foo' => 'bar',
'more' => {
'complex' => 'structure',
'no' => [ 'a', 'b' ],
'yes' => {
'last' => 'level',
'and' => [ 'array' , 'thing' ]
'last' => 'level',
'and' => [ 'array' , 'thing' ]
},
},
},
Expand Down
6 changes: 3 additions & 3 deletions tests/purge_config.pp
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
class { 'collectd':
purge => true,
recurse => true,
purge_config => true,
purge => true,
recurse => true,
purge_config => true,
}


Expand Down

0 comments on commit 70eb150

Please sign in to comment.