summaryrefslogtreecommitdiffstats
path: root/spec/unit/transaction/change.rb
Commit message (Collapse)AuthorAgeFilesLines
* [#3994] rename the specs to have _spec.rb at the endMarkus Roberts2010-06-231-193/+0
| | | | | | | | | Some spec files like active_record.rb had names that would confuse the load path and get loaded instead of the intended implentation when the spec was run from the same directory as the file. Author: Matt Robinson <matt@puppetlabs.com> Date: Fri Jun 11 15:29:33 2010 -0700
* Fixing #3139 - all properties can now be auditedLuke Kanies2010-02-171-0/+26
| | | | | | | | | | | | | | | This provides a full audit trail for any parameter on any resource Puppet can manage. Just use: file { "/my/file": audit => [content, owner] } And Puppet will generate an event any time either of those properties change. This commit also deprecates the 'check' parameter in favor of a new 'audit' parameter. Signed-off-by: Luke Kanies <luke@puppetlabs.com>
* Renaming some methods in Transaction::ChangeLuke Kanies2010-02-171-42/+11
| | | | | | | | | | | Renaming 'go' to 'apply', which is a much more reasonable name. Also removing the 'backward' and 'forward' methods, since they're not actually used anywhere. (Well, 'forward' was used, but it just called 'go'.) Signed-off-by: Luke Kanies <luke@reductivelabs.com>
* Refactoring the Change/Event/Property interfaceLuke Kanies2010-02-171-9/+8
| | | | | | | | This gives all logging responsibility to the event, which can now produce logs identical to those produced directly by the property. At this point, the events are entirely supersets of the logs.
* Cleaning up Event creationLuke Kanies2010-02-171-39/+15
| | | | | | | | | | The Property class is now completely responsible for creating the event, and it adds all of the metadata that a log message would normally have. This provides a cleaner definition of responsibility, and will allow further cleaning up in later commits. Signed-off-by: Luke Kanies <luke@madstop.com>
* Random code cleanupLuke Kanies2010-02-171-50/+86
| | | | Signed-off-by: Luke Kanies <luke@madstop.com>
* Removed extra whitespace from end of linesIan Taylor2009-06-061-1/+1
|
* Fixing #1764 - a property's 'sync' method is never considered a no-op.Luke Kanies2008-11-211-4/+9
| | | | | | | | | | | | | | | | *This is a behaviour change.* If the property does not return an event name, then one is generated based on the property name. Previously, the 'sync' method could return nil and it would be considered a noop, but if you need a noop, then you need to modify your 'insync?' method to return 'true' in the noop cases. Also modifying all of the builtin types that didn't handle this explicitly or returned nil in 'sync'. There should be no behaviour change in any of them. Signed-off-by: Luke Kanies <luke@madstop.com>
* Testing and simplifying the Transaction::Change#backward method.Luke Kanies2008-07-041-0/+31
| | | | Signed-off-by: Luke Kanies <luke@madstop.com>
* Removing the Transaction::Change#transaction accessor.Luke Kanies2008-07-041-5/+0
| | | | | | | As with Events, this was never used (beyond being assigned), so I've gotten rid of it. Signed-off-by: Luke Kanies <luke@madstop.com>
* Refactoring the Transaction::Event class.Luke Kanies2008-07-041-1/+1
| | | | | | | | | | | The class had a 'transaction' accessor that was assigned but never used, and it is simple enough that it needed direct arguments rather than named arguments. The rest of the code is changing the other classes that use Events. Signed-off-by: Luke Kanies <luke@madstop.com>
* Adding tests to the Transaction::Change class.Luke Kanies2008-07-041-0/+156
There's a small amount of refactoring here, mostly removing code that appears to not be used at all. Signed-off-by: Luke Kanies <luke@madstop.com>