HomePhorge

(maint) Unset the defaultprovider after caching it
6d2eeaaee141Unpublished

Unpublished Commit ยท Learn More

Repository Importing: This repository is still importing.

Description

(maint) Unset the defaultprovider after caching it

Prior to this change the defaultprovider for package was implicitly cached
in both package_spec.rb and msi_spec.rb (just by checking it). This represented
spec "leakage" which could result in downstream spec failures on subsequent
tests which accessed defaultprovider. E.g. this sequence failed:

be rspec spec/unit/provider/package/msi_spec.rb spec/unit/type/package_spec.rb

This change clears the defaultprovider for package after caching it for
both these two spec tests.

However, there are a lot of uses of defaultprovider in spec tests, so we may
want a more general solution.

Details

Provenance
Kylo Ginsberg <kylo@puppetlabs.com>Authored on
vanmeeuwenPushed on Jun 2 2015, 2:22 PM
Parents
rPU85ffdfb98d1d: (PUP-753) Constrain ruby-prof solely to the development group
Branches
Unknown
Tags
Unknown

Event Timeline

Kylo Ginsberg <kylo@puppetlabs.com> committed rPU6d2eeaaee141: (maint) Unset the defaultprovider after caching it (authored by Kylo Ginsberg <kylo@puppetlabs.com>).Feb 6 2014, 3:59 AM