Sha256: 1447b0ba76d6033eaf0abeec9b9aa2445b6c1e076bcc71567bd39f7cd89976a6

Contents?: true

Size: 550 Bytes

Versions: 193

Compression:

Stored size: 550 Bytes

Contents

# This action tests that embedded Resources have access to the enclosing Provider's
# lexical scope (as demonstrated by the call to new_resource) and that all parameters
# are passed properly (as demonstrated by the call to generate_new_name).
attr_reader :enclosed_resource

action :twiddle_thumbs do
  @enclosed_resource = lwrp_foo :foo do
    monkey generate_new_name(new_resource.monkey){ 'the monkey' }
    action :twiddle_thumbs
    provider :lwrp_monkey_name_printer
  end
end

def generate_new_name(str, &block)
  "#{str}, #{block.call}"
end

Version data entries

193 entries across 193 versions & 2 rubygems

Version Path
chef-11.18.12-x86-mingw32 spec/data/lwrp/providers/embedded_resource_accesses_providers_scope.rb
chef-11.18.12 spec/data/lwrp/providers/embedded_resource_accesses_providers_scope.rb
chef-12.3.0-x86-mingw32 spec/data/lwrp/providers/embedded_resource_accesses_providers_scope.rb
chef-12.3.0 spec/data/lwrp/providers/embedded_resource_accesses_providers_scope.rb
chef-12.3.0.rc.0-x86-mingw32 spec/data/lwrp/providers/embedded_resource_accesses_providers_scope.rb
chef-12.3.0.rc.0 spec/data/lwrp/providers/embedded_resource_accesses_providers_scope.rb
chef-12.2.1-x86-mingw32 spec/data/lwrp/providers/embedded_resource_accesses_providers_scope.rb
chef-12.2.1 spec/data/lwrp/providers/embedded_resource_accesses_providers_scope.rb
chef-12.2.0.rc.2-x86-mingw32 spec/data/lwrp/providers/embedded_resource_accesses_providers_scope.rb
chef-12.2.0.rc.2 spec/data/lwrp/providers/embedded_resource_accesses_providers_scope.rb
chef-12.2.0.rc.1-x86-mingw32 spec/data/lwrp/providers/embedded_resource_accesses_providers_scope.rb
chef-12.2.0.rc.1 spec/data/lwrp/providers/embedded_resource_accesses_providers_scope.rb
chef-12.1.2 spec/data/lwrp/providers/embedded_resource_accesses_providers_scope.rb
chef-12.1.2-x86-mingw32 spec/data/lwrp/providers/embedded_resource_accesses_providers_scope.rb
chef-12.1.1-x86-mingw32 spec/data/lwrp/providers/embedded_resource_accesses_providers_scope.rb
chef-12.1.1 spec/data/lwrp/providers/embedded_resource_accesses_providers_scope.rb
chef-12.1.0-x86-mingw32 spec/data/lwrp/providers/embedded_resource_accesses_providers_scope.rb
chef-12.1.0 spec/data/lwrp/providers/embedded_resource_accesses_providers_scope.rb
chef-12.1.0.rc.0-x86-mingw32 spec/data/lwrp/providers/embedded_resource_accesses_providers_scope.rb
chef-12.1.0.rc.0 spec/data/lwrp/providers/embedded_resource_accesses_providers_scope.rb