Uploaded image for project: 'Beaker'
  1. Beaker
  2. BKR-1626

Puppetlabs-mysql sample beaker testing not working

    XMLWordPrintable

    Details

    • Template:
    • QA Risk Assessment:
      Needs Assessment

      Description

      Hi I tried puppet beaker acceptance test in puppetlabs-mysql using https://github.com/puppetlabs/beaker-rspec I followed the README file but I got error while I execute bundle rspec like,

      RuntimeError:
      apply manifest failed
      ` puppet apply /tmp/manifest_20191122_15690_r3235e.pp --modulepath /home/beaker/puppetlabs-mysql/spec/fixtures/modules --detailed-exitcodes`
      with exit code 1 (expected: [0, 2])
      ====== Start output of failed Puppet apply ======
      Error: Evaluation Error: Error while evaluating a Resource Statement, Could not find declared class mysql::server (file: /tmp/manifest_20191122_15690_r3235e.pp, line: 1, column: 1) on node puppet-pdk.novalocal

      ====== End output of failed Puppet apply ======

      1. /usr/local/rvm/gems/ruby-2.6.3/gems/puppet_litmus-0.12.0/lib/puppet_litmus/puppet_helpers.rb:277:in `report_puppet_apply_error'
      2. /usr/local/rvm/gems/ruby-2.6.3/gems/puppet_litmus-0.12.0/lib/puppet_litmus/puppet_helpers.rb:79:in `apply_manifest'
      3. ./spec/spec_helper_acceptance_local.rb:4:in `pre_run'
      4. ./spec/acceptance/types/mysql_grant_spec.rb:446:in `block (2 levels) in <top (required)>'
      5. ./spec/acceptance/types/mysql_grant_spec.rb:445:in `block in <top (required)>'
      6. ./spec/acceptance/types/mysql_grant_spec.rb:3:in `<top (required)>'

      An error occurred while loading ./spec/acceptance/types/mysql_plugin_spec.rb.
      Failure/Error: if os[:family] == 'redhat'
      NoMethodError:
      undefined method `example' for #<Specinfra::Backend::Exec:0x0000000005c52d58 @config={}>
      Did you mean? cur_example

      1. /usr/local/rvm/gems/ruby-2.6.3/gems/beaker-rspec-6.2.4/lib/beaker-rspec/helpers/serverspec.rb:12:in `cur_example'
      2. /usr/local/rvm/gems/ruby-2.6.3/gems/beaker-rspec-6.2.4/lib/beaker-rspec/helpers/serverspec.rb:16:in `get_working_node'
      3. /usr/local/rvm/gems/ruby-2.6.3/gems/beaker-rspec-6.2.4/lib/beaker-rspec/helpers/serverspec.rb:68:in `os'
      4. ./spec/acceptance/types/mysql_plugin_spec.rb:7:in `<top (required)>'

      An error occurred while loading ./spec/acceptance/types/mysql_user_spec.rb.
      Failure/Error: if shell_output.stdout.match(%r{\d+\.\d+\.\d+}).nil?
      NoMethodError:
      undefined method `match' for nil:NilClass

      1. ./spec/spec_helper_acceptance_local.rb:9:in `mysql_version'
      2. ./spec/acceptance/types/mysql_user_spec.rb:39:in `block (2 levels) in <top (required)>'
      3. ./spec/acceptance/types/mysql_user_spec.rb:13:in `block in <top (required)>'
      4. ./spec/acceptance/types/mysql_user_spec.rb:3:in `<top (required)>'

      Finished in 0.00006 seconds (files took 9.52 seconds to load)
      0 examples, 0 failures, 5 errors occurred outside of examples

        Attachments

          Activity

            People

            Assignee:
            Unassigned Unassigned
            Reporter:
            Ashjoker Ashwinkumar
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:

                Zendesk Support