opscode/chef — pull request #1553 by sethvargo (2014-06-25 19:46:36+00:00)
Title: Delegate DSL method values to their superclass

When inheriting from +Resource::LWRPBase+, the +default_action+ and +actions+ attributes are set as class instance variables. In Ruby's object model, class instance variables are **not** shared with children. So subclassing a resource that extended from +Resource::LWRPBase+ would result in some unexplainable side-effects:

```ruby
class Chef::Resource::Parent < Chef::Resource::LWRPBase
actions :execute
default_action :execute
end

class Child::Resource::Child < Chef::Resource::Parent
# In here, +actions+ and +default_action+ are **not** inherited so they
# are +nil+!
end
```

This commit tells resources that inherit from LWRPBase to check their superclasses for values if they do not have one on their own.

/cc @opscode/release-engineers