Make file_line default to ensure => present#69
Conversation
This patch back ports the file from the master branch. The spec tests fail without this patch applied. This should make it easier to setup Puppet settings using the puppet_spec_helper project.
This just changes the instance variables to a memoized let block and gets ride of the before :each block. The patch has no change in behavior.
The examples in the file_line resource documentation state the following
resource should work:
file_line { 'sudo_rule':
path => '/etc/sudoers',
line => '%sudo ALL=(ALL) ALL',
}
Without this patch the example does not work because ensure is not set
to present.
This patch fixes the problem by setting the default value of ensure to
present.
|
@jeffmccune somebody complained on IRC that it doesn't work currently. And as I compare your fix and mine, it differes by yours not having I told the person on IRC to open a ticket. |
|
Thanks I'll have a look this morning and get it fixed up. I really appreciate you following up here and engaging the IRC channel. -Jeff On Tuesday, May 22, 2012, duritong wrote:
|
|
You'll find a fix in GH-65 |
The examples in the file_line resource documentation state the following
resource should work:
Without this patch the example does not work because ensure is not set
to present.
This patch fixes the problem by setting the default value of ensure to
present.