Uploaded image for project: 'PuppetDB'
  1. PuppetDB
  2. PDB-3498

Fix rspec resource-related failures wrt puppet master

    Details

    • Type: Task
    • Status: Closed
    • Priority: Normal
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: PDB 4.4.1
    • Component/s: None
    • Labels:
    • Template:
    • Team:
      Systems Engineering
    • Story Points:
      1
    • Sprint:
      PuppetDB 2017-05-31
    • Release Notes:
      Not Needed
    • QA Risk Assessment:
      Needs Assessment

      Description

      See failure info below, and Jeremy suggested that this change might be related: https://github.com/puppetlabs/puppet/commit/38413cd78c61fe34d2ee343ef773a07b4786f65a, and that the fix may just involve "adding a mock for the lookupdefaults method on the mock scope which returns an empty hash, somewhere around here: https://github.com/puppetlabs/puppetdb/blob/master/puppet/spec/unit/indirector/resource/puppetdb_spec.rb#L21"

      10:25:38 Failures:
      10:25:38
      10:25:38 1) Puppet::Resource::Puppetdb#search with a matching resource with resources from a single host should return a list of parser resources if any resources are found
      10:25:38 Failure/Error: result = Puppet::Parser::Resource.new(res['type'], res['title'], attrs)
      10:25:38
      10:25:38 Mocha::ExpectationError:
      10:25:38 unexpected invocation: #<Mock:scope>.lookupdefaults('File')
      10:25:38 satisfied expectations:
      10:25:38 - allowed any number of times, not yet invoked: Puppet::Util::Puppetdb.server_urls(any_parameters)
      10:25:38 - allowed any number of times, invoked once: #<Puppet::Indirector::Indirection:0x1b37558>.terminus(any_parameters)
      10:25:38 - allowed any number of times, invoked twice: #<Net::HTTPOK:0x4821af0>.body(any_parameters)
      10:25:38 - allowed any number of times, invoked once: Puppet::Network::HttpPool.http_instance(any_parameters)

      https://cinext-jenkinsmaster-enterprise-prod-1.delivery.puppetlabs.net/job/enterprise_puppetdb_unit-rspec-puppetdb_puppetmasterbranch-master/16/PUPPET_VERSION=master,RUBY_VER=ruby-2.0.0-p481,label=unit/console

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                rob.browning Rob Browning
                Reporter:
                rob.browning Rob Browning
              • Votes:
                0 Vote for this issue
                Watchers:
                1 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:

                  Zendesk Support