summaryrefslogtreecommitdiff
path: root/spec/unit/provider/package
Commit message (Collapse)AuthorAgeFilesLines
* Merge pull request #10148 from chef/fix-spec_helper-requiresTim Smith2020-07-151-1/+1
|\ | | | | Avoid requiring spec_helper more than once
| * The spec/ directory is in the path.fix-spec_helper-requiresPete Higgins2020-07-131-1/+1
| | | | | | | | Signed-off-by: Pete Higgins <pete@peterhiggins.org>
* | Change non-default rubygems URL to default one for failing test.Pete Higgins2020-07-151-14/+1
| | | | | | | | Signed-off-by: Pete Higgins <pete@peterhiggins.org>
* | Workaround SSL cert verification failure in test.fix-rubygems-ssl-test-failurePete Higgins2020-07-141-0/+4
| | | | | | | | Signed-off-by: Pete Higgins <pete@peterhiggins.org>
* | Turn off ssl certificate verification in failing test.Pete Higgins2020-07-141-0/+9
| | | | | | | | Signed-off-by: Pete Higgins <pete@peterhiggins.org>
* | Factor out common test setup.Pete Higgins2020-07-141-9/+4
| | | | | | | | Signed-off-by: Pete Higgins <pete@peterhiggins.org>
* | Don't run the dnf test that Windows doesn't like on Windows.Pete Higgins2020-07-131-1/+1
|/ | | | Signed-off-by: Pete Higgins <pete@peterhiggins.org>
* Fix windows package tests.fix-windows-unit-testssnehaldwivedi2020-07-101-8/+13
| | | | Signed-off-by: Pete Higgins <pete@peterhiggins.org>
* Refer to the new_resource directly.Pete Higgins2020-07-071-5/+5
| | | | Signed-off-by: Pete Higgins <pete@peterhiggins.org>
* Update test for Windows package installer_type since the resource behavior ↵Pete Higgins2020-07-071-3/+3
| | | | | | changed. Signed-off-by: Pete Higgins <pete@peterhiggins.org>
* Update tests to match how Windows package checksums are done.Pete Higgins2020-07-071-38/+10
| | | | Signed-off-by: Pete Higgins <pete@peterhiggins.org>
* Remove other top-level methods defined in tests and do a little cleanup.other-test-cleanupPete Higgins2020-06-241-20/+17
| | | | Signed-off-by: Pete Higgins <pete@peterhiggins.org>
* Fix some odd whitespacing in tests.Pete Higgins2020-06-242-4/+4
| | | | Signed-off-by: Pete Higgins <pete@peterhiggins.org>
* Add kitchen tests for snapdPhil Dibowitz2020-06-141-1/+1
| | | | Signed-off-by: Phil Dibowitz <phil@ipom.com>
* Fixed Powershell_Package does not throw error when it cannot connect to ↵sanga172020-06-021-86/+95
| | | | | | powershell gallery Signed-off-by: sanga17 <sausekar@msystechnologies.com>
* Get lib/ free of spelling violations.Pete Higgins2020-05-182-3/+3
| | | | Signed-off-by: Pete Higgins <pete@peterhiggins.org>
* Align all our comments with the codeTim Smith2020-05-061-3/+3
| | | | | | Autocorrected with chefstyle after enabling that cop. It was very hard to read some complex autocorrected blocks w/o this. Signed-off-by: Tim Smith <tsmith@chef.io>
* Fix for Chocolate_resource options causing extra quotesKapil/Github-9413_Chocolate_resource_options_causing_extra_quotesKapil Chouhan2020-04-231-1/+1
| | | | Signed-off-by: Kapil Chouhan <kapil.chouhan@msystechnologies.com>
* added multipackage support for pacman resourceIngo Becker2020-04-201-147/+65
| | | | Signed-off-by: Ingo Becker <ingo@orgizm.net>
* Use lamont's magic error handlingTim Smith2020-04-171-2/+3
| | | | | | | | | | | | | | | | | | | | | | | | | Tiny tweak to grab the first item so we actually get the hash back in the error handling. Given: ```ruby package %w{curl totally_junk_pkg} do action :upgrade end ``` ``` * No candidate version available for totally_junk_pkg ================================================================================ Error executing action `upgrade` on resource 'homebrew_package[curl, totally_junk_pkg]' ================================================================================ Chef::Exceptions::Package ------------------------- No candidate version available for totally_junk_pkg ``` Signed-off-by: Tim Smith <tsmith@chef.io>
* Return empty hash from brew_info and avoid a bunch of nil checksmulti_packageTim Smith2020-04-171-5/+5
| | | | Signed-off-by: Tim Smith <tsmith@chef.io>
* Properly handle unavailable packagesTim Smith2020-04-171-0/+10
| | | | Signed-off-by: Tim Smith <tsmith@chef.io>
* Remove some empty specs I left behindTim Smith2020-04-171-38/+1
| | | | Signed-off-by: Tim Smith <tsmith@chef.io>
* Fix the upgrade action specsTim Smith2020-04-171-25/+20
| | | | Signed-off-by: Tim Smith <tsmith@chef.io>
* Test install / remove / purge actionsTim Smith2020-04-171-39/+68
| | | | Signed-off-by: Tim Smith <tsmith@chef.io>
* Update specs for brew_cmd_outputTim Smith2020-04-161-4/+4
| | | | Signed-off-by: Tim Smith <tsmith@chef.io>
* Add specs for available versionTim Smith2020-04-161-0/+12
| | | | Signed-off-by: Tim Smith <tsmith@chef.io>
* Update specs for brew_info and installed_versionTim Smith2020-04-161-93/+193
| | | | Signed-off-by: Tim Smith <tsmith@chef.io>
* Fix the load_current_resource specsTim Smith2020-04-161-17/+13
| | | | Signed-off-by: Tim Smith <tsmith@chef.io>
* Remove copyright dateslcg/remove-copyright-datesLamont Granquist2020-04-1322-22/+22
| | | | | | | | Legally incredibly dubious, particularly since we don't follow it strictly as policy, and we have git history instead, which does it right. This is just a waste of time and a cargo cult. Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
* Add more typo fixesVivek Singh2020-04-073-3/+3
| | | | Signed-off-by: Vivek Singh <vivek.singh@msystechnologies.com>
* some spec typosVivek Singh2020-04-073-5/+5
| | | | Signed-off-by: Vivek Singh <vivek.singh@msystechnologies.com>
* Fix chefstyle violation.Pete Higgins2020-03-231-1/+1
| | | | Signed-off-by: Pete Higgins <pete@peterhiggins.org>
* Make include_default_source nil by default and change implied logic.Pete Higgins2020-03-231-12/+119
| | | | Signed-off-by: Pete Higgins <pete@peterhiggins.org>
* Clear sources if either a source or rubygems_url is set.Pete Higgins2020-03-231-1/+21
| | | | Signed-off-by: Pete Higgins <pete@peterhiggins.org>
* Switch to canonical "https://rubygems.org" URL for rubygems.Pete Higgins2020-03-231-19/+19
| | | | Signed-off-by: Pete Higgins <pete@peterhiggins.org>
* Change the default value for :rubygems_url to be nil.Pete Higgins2020-03-231-8/+8
| | | | Signed-off-by: Pete Higgins <pete@peterhiggins.org>
* Move clear_sources? helper from resource to provider.Pete Higgins2020-03-231-0/+45
| | | | Signed-off-by: Pete Higgins <pete@peterhiggins.org>
* Update gem_package to make clear_sources opt-out.Pete Higgins2020-03-231-5/+18
| | | | Signed-off-by: Pete Higgins <pete@peterhiggins.org>
* DNF refresh and aarch64-el8 supportlcg/dnf-refreshLamont Granquist2020-03-191-2/+2
| | | | | | | | should port all fixes from the yum provider back into the dnf provider. adds aarch for el8 since the func tests now pass. Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
* run powershell_spec for windows onlysanga172020-03-181-1/+1
| | | | Signed-off-by: sanga17 <sausekar@msystechnologies.com>
* Powershell spec file updatedsanga172020-03-171-0/+1
| | | | Signed-off-by: sanga17 <sausekar@msystechnologies.com>
* Add basic spec for return codewindows_package_3010Tim Smith2020-02-251-1/+1
| | | | | | Traditionally we've tested the defaults so we don't accidentally change them. Signed-off-by: Tim Smith <tsmith@chef.io>
* Add chef-utils gem with various recipe DSL helpersLamont Granquist2019-11-082-3/+3
| | | | | | | | | | | | | This is the implementation of [RFC-087](https://github.com/chef-boneyard/chef-rfc/blob/master/rfc087-distro-sugar-helpers.md) although some of the specifics have been iterated on and changed. The documentation will be in the [README.md](https://github.com/chef/chef/tree/master/chef-utils/README.md) once this is merged. While this PR mostly moves chef-sugar utilities into core-chef via this chef-utils gem, the scope of the chef-utils gem should be considered larger than just that. As an example this PR moves the Mash class into this gem for reuse in ohai as well. Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
* Updates for Chefstyle with Rubocop 0.75.1Tim Smith2019-11-042-2/+2
| | | | | | This update found a few things that should have been triggering before. Signed-off-by: Tim Smith <tsmith@chef.io>
* Avoid a PATH environment variable update before a windows package installJeremy HAGE2019-10-081-1/+1
| | | | Signed-off-by: Jeremy HAGE <jha@jsh-consulting.com>
* Fix for chocolatey_package fails using extra optionsKapil Chouhan2019-09-091-35/+50
| | | | | | | | | | | | | | | | Signed-off-by: Kapil Chouhan <kapil.chouhan@msystechnologies.com> Fixed buildkite failure Signed-off-by: Kapil Chouhan <kapil.chouhan@msystechnologies.com> update require changes according to internal review comments Signed-off-by: Kapil Chouhan <kapil.chouhan@msystechnologies.com> Fix for MSYS-1015 chocolatey_package fails using extra options Signed-off-by: Kapil Chouhan <kapil.chouhan@msystechnologies.com>
* convert chocolatey resource to use shell_out splat argsLamont Granquist2019-09-031-30/+34
| | | | Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
* zypper_package upgrade action not working (#8462)Lamont Granquist2019-08-071-0/+9
|\ | | | | zypper_package upgrade action not working
| * fix zypper_package upgrade provider and unit tests to verifyJeremy Chalfant2019-06-131-0/+9
| | | | | | | | Signed-off-by: Jeremy Chalfant <jchalfan@us.ibm.com>