summaryrefslogtreecommitdiff
path: root/spec/unit/provider/package/dpkg_spec.rb
Commit message (Collapse)AuthorAgeFilesLines
* Move response_file and response_file_variables out of base package resourceKapil Chouhan2019-05-071-1/+28
| | | | | | | | | | | | | | | | | | | | Signed-off-by: Kapil Chouhan <kapil.chouhan@msystechnologies.com> Fix for Move response_file and response_file_variables out of base package resource Signed-off-by: Kapil Chouhan <kapil.chouhan@msystechnologies.com> update require changes Signed-off-by: Kapil Chouhan <kapil.chouhan@msystechnologies.com> Updated require changes Signed-off-by: Kapil Chouhan <kapil.chouhan@msystechnologies.com> Fixed some unit test cases Signed-off-by: Kapil Chouhan <kapil.chouhan@msystechnologies.com>
* fix Layout/IndentHeredocLamont Granquist2018-07-021-21/+21
| | | | Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
* fix Style/HashSyntaxLamont Granquist2018-07-021-4/+4
| | | | Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
* Unification of shell_out APIsLamont Granquist2018-06-151-8/+8
| | | | | | | converts all usage to just shell_out() from the numerous helper utilities that we've had previously. Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
* remove uses of shell_out_compact_timeoutLamont Granquist2018-05-311-1/+1
| | | | | | just use shell_out_compact now. Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
* package provider cleanuplcg/package-cleanupLamont Granquist2017-02-111-16/+16
| | | | | | | | | - cleans up a lot of ivar usage - converts most providers to shell_out_compact_timeout! - almost deprecates a few APIs, but can't quite yet - windows providers need mixlib-shellout to take an argv Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
* autofixing whitespace copsLamont Granquist2016-02-051-3/+3
| | | | | | | | | | | | | | | | | | | | | | 4174 Style/SpaceInsideHashLiteralBraces 1860 Style/SpaceAroundOperators 1336 Style/SpaceInsideBlockBraces 1292 Style/AlignHash 997 Style/SpaceAfterComma 860 Style/SpaceAroundEqualsInParameterDefault 310 Style/EmptyLines 294 Style/IndentationConsistency 267 Style/TrailingWhitespace 238 Style/ExtraSpacing 212 Style/SpaceBeforeBlockBraces 166 Style/MultilineOperationIndentation 144 Style/TrailingBlankLines 120 Style/EmptyLineBetweenDefs 101 Style/IndentationWidth 82 Style/SpaceAroundBlockParameters 40 Style/EmptyLinesAroundMethodBody 29 Style/EmptyLinesAroundAccessModifier 1 Style/RescueEnsureAlignment
* Copyright year update for 2016 and massive cleanup.Noah Kantrowitz2016-02-021-1/+1
| | | Generated via git ls-files | xargs perl -pi -e "s/[Cc]opyright (?:\([Cc]\) )?((?\!$(date +%Y))\\d{4})(-\\d{4})?([, ][ \d]+)*(,|(?= ))/Copyright \\1-$(date +%Y),/g"
* Fix nil with properties:John Keiser2016-01-271-21/+17
| | | | | | 1. Warn when default values are invalid. 2. Never validate nil (on set or get) if there is no default. 3. Emit "will be invalid in Chef 13" warning when setting an invalid nil value.
* Use double quotes by defaultThom May2016-01-141-11/+11
| | | | | | | This is an entirely mechanically generated (chefstyle -a) change, to go along with chef/chefstyle#5 . We should pick something and use it consistently, and my opinion is that double quotes are the appropriate thing.
* restore handling of dpkg -s returns codes (w/tests)lcg/dpkg-s-return-codesLamont Granquist2015-12-071-3/+38
| | | | | | | | | | | | | | | | Previously dpkg -s would allow a 0 or 1 exit status and it wasn't entirely clear why this was so either from the code or the tests. This restores throwing an exception if we are outside of the [0,1] range, and then adds tests for both behaviors: - on old ubuntu/debian we get an exit(0) and output on stdout if the file is not installed - on newer ubuntu/debian we get an exit(1) and output on stderr if the file is not installed Added tests for both those cases, and the case where dpkg -s does some other kind of exitcode barf and we should raise.
* dpkg multipackage and bonus fixesLamont Granquist2015-12-021-39/+40
| | | | | | | | - multipackages dpkg_package - fixes edge conditions in load-current-resource around purging/removing packages that threw errors before - fixes the ability to purge packages that have been removed - adds a lot of functional tests for dpkg_package
* dpkg provider cleanupLamont Granquist2015-11-201-85/+138
| | | | | | | | | | | | | | - :update and :install are now treated the same way and throw the same exceptions - :remove and :purge don't require the source at all, so don't do any checking on that - fix some convoluted side-effecty logic in load_current_resource - load_current_resource now correctly gets the dpkg state on :remove and :purge when the file does not exist (pretty sure the old logic did not) - fixed the FIXME about using en_US.UTF-8 (the default for shell_out!) - just use shell_out! to throw exceptions - clean up all the specs and remove all the instance vars from the code
* Use the output of dpkg-deb directly, rather than regextm/use-dpkg-debThom May2015-08-121-1/+8
| | | | Thanks to @kwilczynski for the original implementation
* fix package timeout attributeLamont Granquist2015-06-021-2/+2
| | | | | | | | | | updates all the shell_out calls to respect the timeout which is passed on the new_resource. the old `Chef::Config` yum timeout values are still respected and will override the default. the default of 900 seconds is preserved.
* fix dpkg regressionLamont Granquist2015-02-191-0/+1
|
* fix aix related providers to replace popen4 with mixlib shell_outkaustubh-d2015-02-171-14/+12
|
* Multipackage fixes to superclassLamont Granquist2015-02-031-1/+1
| | | | | | | - fixes define_resource_requirements - better idempotency (only packages that need updating are updated) - better messaging (only packages that update are output) - better comments
* updating resources/providers unit tests to rpsec3Lamont Granquist2014-10-241-27/+27
| | | | mechanically generated patch using transpec 2.3.7 gem
* moar 1.8.7 fixesLamont Granquist2014-07-011-4/+4
|
* fix unit testsLamont Granquist2014-07-011-48/+24
|
* CHEF-1752: Support epochs in debian package versionsBryan McLellan2014-03-191-0/+4
| | | | | | | | Debian allows a colon in package versions to handle cases where the upstream version of a release may be newer than a prior release, but not numerically sort as higher. H/T to Eric Herot <eric@where.com> for the original patch
* s/mock\(/double(/gLamont Granquist2014-01-291-3/+3
|
* s/stub!/stub/gLamont Granquist2014-01-291-10/+10
| | | | fix deprecation warnings
* Normalize whitespace on all filesSeth Vargo2013-09-261-3/+3
|
* [OC-3564] move core Chef to the repo root \o/ \m/Seth Chisamore2012-10-301-0/+216
The opscode/chef repository now only contains the core Chef library code used by chef-client, knife and chef-solo!