lib/beaker/dsl/helpers/hocon_helpers.rb in beaker-4.38.1 vs lib/beaker/dsl/helpers/hocon_helpers.rb in beaker-4.39.0

- old
+ new

@@ -51,11 +51,11 @@ # {https://github.com/puppetlabs/ruby-hocon#basic-usage Hocon's basic usage doc} # for info on how to use this object. # # @raise ArgumentError if arguments are missing or incorrect. # @return nil - def hocon_file_edit_on(hosts, filename, &block) + def hocon_file_edit_on(hosts, filename) if not block_given? msg = 'DSL method `hocon_file_edit_on` provides a given block' msg << ' a hocon file to edit. No block was provided.' raise ArgumentError, msg end @@ -78,10 +78,10 @@ # @example setting an attribute & saving # hocon_file_edit_in_place_on(hosts, hocon_filename) do |host, doc| # doc.set_value('c.d', '[6, 2, 73, 4, 45]') # end # - def hocon_file_edit_in_place_on(hosts, filename, &block) + def hocon_file_edit_in_place_on(hosts, filename) hocon_file_edit_on(hosts, filename) do |host, doc| content_doc = yield host, doc create_remote_file(host, filename, content_doc.render) end end