rodjek / puppet-lint

Check that your Puppet manifests conform to the style guide
MIT License
819 stars 204 forks source link

lint failure on 'ensure' word in dsc_lite module #866

Closed rajeshr264 closed 5 years ago

rajeshr264 commented 5 years ago

it looks puppet-lint doesn't like the way how ensure is defined in dsc_lite. Screenshot attached.

Already chatted about this issue with Tim S via slack.

image

usev6 commented 5 years ago

I'm pretty sure this has been fixed with https://github.com/rodjek/puppet-lint/pull/877

From what I can see, a complete test file would look like this:

# gh::issue866
class gh::issue866 {
  dsc { 'RSAT':
    resource_name => 'xWindowsfeature',
    module        => {
      name    => 'xPSDesiredStateConfiguration',
      version => '0.0.0.1',
    },
    properties    => {
      ensure => 'present',
      name   => 'RSAT',
    },
  }
}

Running puppet-lint on HEAD (dc9da8aac1) works just fine (no warning), with 4b82a73b9bc reverted one gets the old behaviour:

WARNING: ensure found on line but it's not the first attribute on line 10

This issue looks closable to me.

rodjek commented 5 years ago

Confirmed fixed