-
Notifications
You must be signed in to change notification settings - Fork 303
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add an $ensure parameter to concat #39
Conversation
Thanks, this commit breaks some of the tests, if you fix those I can take a look at merging |
Sorry I didn't saw it broke the tests. I am not very familiar with rspec or Ruby :-( I manage to setup rpec-puppet but when I run 'rake spec' at the root of concat module, here is the input: Finished in 0.13162 seconds I don't see any failure... but I am not sure that I am doing the right thing. |
Sorry I just saw the Travis build log... |
The error in Travis build should be fixed now. |
great thanks, I'll need to make some time to do manual tests too then will merge |
You are welcome. Thanks to you for this module and for your great blog posts. |
Oups, I find a bug. |
Bug should be fixed. |
Updated to take into account upstream commits. |
think it's right to backup all the files into the filebucket when absent or just the final managed file? As it is everything will backup, not sure if that's the best idea. what do you think? |
Good point. I am not much a user of the filebucket :-) |
@FredericLespez Hi! Any chance you can git rebase this against master for me and squash up the commits to hide the followup work that happened? |
@apenney Hi ! Sure I'll try do that tomorrow. |
Any luck? I only ask as someone else asked me why we don't have ensure yet and it reminded me we have this PR :) |
Sorry. More work than I thought :-/ Ashley Penney notifications@github.com a écrit :
|
Rebased against master and commit squashed. I just remove the modification of the CHANGELOG file since it seems you have format. |
Looks like this commit now has a duplicated resource:
Before I can merge this a "rake spec" will need to pass all the tests. |
Sorry. I'm looking at it now. Ashley Penney notifications@github.com a écrit :
|
This parameter controls whether ressources associated to concat should be present or absent.
I think it's good now. |
@@ -46,6 +48,7 @@ | |||
# File["concat_/path/to/file"] | |||
# | |||
define concat( | |||
$ensure = 'present', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The new $ensure
param should be validated with something like validate_re($ensure, '^present$|^absent$')
@apenney I'm also desiring the ability to remove concat files. Are you inclined to merge this patch or do you want rspec-puppet tests with it? |
I'd love rspec-system tests more than anything else but I'm happy to merge it without. Let me regrab it and put it through the current tests at least. |
Add an $ensure parameter to concat
I've merged it but I'd still love it if anyone is brave enough to extend the spec/system tests to include ensure=present/absent. |
Hi,
This patch add an $ensure parameter to concat in order to control whether resources associated managed by concat should be present or absent.
This pull request also contain a format fix of concat::fragment define's declaration.
Please consider pulling.
Regards,
Fred