Sha256: a22bf21998a036cc76fc839a3b4c55b7b83a77ba24cc8defe3339a68882183fe

Contents?: true

Size: 555 Bytes

Versions: 1

Compression:

Stored size: 555 Bytes

Contents

module BeakerAnswers
  # In the case of upgrades, we lay down a much simpler file
  class Upgrade < Answers

    def self.upgrade_version_matcher
      /\A2015\.[123]|\A2016\.[1234]/
    end

    def generate_answers
      the_answers = {}
      @hosts.each do |host|
        the_answers[host.name] = {:q_install => answer_for(@options, :q_install)}
        # merge custom host answers if available
        the_answers[host.name] = the_answers[host.name].merge(host[:custom_answers]) if host[:custom_answers]
      end
      the_answers
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
beaker-answers-0.4.1 lib/beaker-answers/versions/upgrade.rb