summaryrefslogtreecommitdiff
path: root/spec
Commit message (Collapse)AuthorAgeFilesLines
* Add rubular link for regex in test.fix-diff-testsPete Higgins2020-06-231-0/+1
| | | | Signed-off-by: Pete Higgins <pete@peterhiggins.org>
* Update the regex that was scrubbing OS specific strings.Pete Higgins2020-06-231-1/+1
| | | | | | https://rubular.com/r/5JdtZDqWnZhB9J Signed-off-by: Pete Higgins <pete@peterhiggins.org>
* More aggressively deprecate config_valueLamont Granquist2020-06-221-0/+1
| | | | | | | | | | | | | | | Force subclasses to use the `config` hash directly. This should not affect any knife plugins shipping in chef-workstation since the calls to config_value have already been removed from all of those plugins. The multiple-argument version of config_value was not actually used anywhere in those plugins and the single value version was removed and replaced with accessing the config hash. Since that was introduced sometime in 15.x when the bootstrap changes went in, it is not expected that many external knife plugins have picked up the usage of config_value. Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
* Merge pull request #10011 from chef/vasundhara/Fixes_knife_config_use_profileTim Smith2020-06-181-2/+55
|\ | | | | Fix for knife config use-profile doesn't validate that the profile exist
| * Fix for #9686: knife config use profile doesn't validate that the profile existvasundhara/Fixes_knife_config_use_profileVasu11052020-06-181-2/+55
| | | | | | | | Signed-off-by: Vasu1105 <vasundhara.jagdale@msystechnologies.com>
* | Merge pull request #10000 from chef/resource-umask-propertyTim Smith2020-06-171-0/+52
|\ \ | |/ |/| Add a umask property for resources.
| * Cleanup test, add failsafe reset.Pete Higgins2020-06-161-10/+11
| | | | | | | | Signed-off-by: Pete Higgins <pete@peterhiggins.org>
| * Fix chefstyle violation.Pete Higgins2020-06-161-1/+1
| | | | | | | | Signed-off-by: Pete Higgins <pete@peterhiggins.org>
| * Add a umask property for resources.Pete Higgins2020-06-161-0/+51
| | | | | | | | Signed-off-by: Pete Higgins <pete@peterhiggins.org>
* | Silence exception output in threaded test.Pete Higgins2020-06-161-0/+9
|/ | | | Signed-off-by: Pete Higgins <pete@peterhiggins.org>
* Merge pull request #10001 from chef/cron_cleanupTim Smith2020-06-154-52/+26
|\ | | | | Cron and Cron_d resource weekday property fixes
| * Moved all the constants together.antima-gupta2020-06-101-1/+0
| | | | | | | | | | | | | | | | | | Removed unnecessary assignment for weekday_in_crontab. Removed pry. Removed converted to a string function from weekday validation. Added unified_mode in cron and cron_d resources. Signed-off-by: antima-gupta <agupta@msystechnologies.com>
| * removed cron helper filesantima-gupta2020-06-101-31/+0
| | | | | | | | Signed-off-by: antima-gupta <agupta@msystechnologies.com>
| * Added cron_shared partial.antima-gupta2020-06-101-6/+9
| | | | | | | | | | | | | | Fixed provider cron spec failure. Moved cron and cron resource into the lib/chef/resource/cron directory. Signed-off-by: antima-gupta <agupta@msystechnologies.com>
| * Added freeze for WEEKDAYS constant.antima-gupta2020-06-102-5/+5
| | | | | | | | | | | | | | Fixed chefstyle spec failure. Made changes as per review comment. Signed-off-by: antima-gupta <agupta@msystechnologies.com>
| * Fixed cron resource weekday property.antima-gupta2020-06-105-46/+49
| | | | | | | | | | | | | | | | | | Implemented same weekday functionality for cron_d resource. Fixed rspec failure. Added cron helper for weekday functionality Added spec for cron helper. Signed-off-by: antima-gupta <agupta@msystechnologies.com>
* | Merge pull request #9980 from chef-davin/windows_audit_policyTim Smith2020-06-151-0/+64
|\ \ | | | | | | Create windows_audit_policy resource
| * | updates for chefstyle and spellcheck errorsDavin Taddeo2020-06-151-1/+0
| | | | | | | | | | | | Signed-off-by: Davin Taddeo <davin@chef.io>
| * | missed commiting the reference to the full chain to reference the ↵Davin Taddeo2020-06-151-1/+1
| | | | | | | | | | | | | | | | | | WIN_AUDIT_SUBCATEGORIES constant Signed-off-by: Davin Taddeo <davin@chef.io>
| * | still not sure if I'm calling this constant right... if this doesn't work, I ↵Davin Taddeo2020-06-151-1/+1
| | | | | | | | | | | | | | | | | | guess I'll ask for help or something ;) Signed-off-by: Davin Taddeo <davin@chef.io>
| * | hoping this fixes my uninitialized constant issueDavin Taddeo2020-06-151-0/+1
| | | | | | | | | | | | Signed-off-by: Davin Taddeo <davin@chef.io>
| * | Updated code to reflect feedback from @phigginsDavin Taddeo2020-06-151-72/+10
| | | | | | | | | | | | Signed-off-by: Davin Taddeo <davin@chef.io>
| * | Merge branch 'master' of github.com:chef/chef into windows_audit_policyDavin Taddeo2020-06-159-10/+10
| |\ \
| * \ \ Merge branch 'master' of github.com:chef/chef into windows_audit_policyDavin Taddeo2020-06-112-2/+2
| |\ \ \
| * | | | chefstyle and spellcheck fixes.Davin Taddeo2020-06-111-1/+1
| | | | | | | | | | | | | | | | | | | | Signed-off-by: Davin Taddeo <davin@chef.io>
| * | | | fixing a lot more :facepalm: copy/paste errors.Davin Taddeo2020-06-111-4/+4
| | | | | | | | | | | | | | | | | | | | Signed-off-by: Davin Taddeo <davin@chef.io>
| * | | | Create windows_audit_policy resource and some unit tests for it.Davin Taddeo2020-06-101-0/+126
| | |_|/ | |/| | | | | | | | | | Signed-off-by: Davin Taddeo <davin@chef.io>
* | | | Merge pull request #9963 from ramereth/fix-chef-apply-enforce_licenseTim Smith2020-06-151-0/+7
|\ \ \ \ | |_|_|/ |/| | | Fix how enforce_license is set in run method for chef-apply
| * | | Fix how enforce_license is set in run method for chef-applyLance Albertson2020-06-081-0/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | I recently discovered that when using Chef::Application::Apply.new.run(enforce_license: false), chef-apply will still run the license verification when I expected it to be disabled. It seems this feature works if you install this as a gem, however if you build chef using omnibus with this set, it refuses to work. I suspect this might be something with appbundler. I noticed that other binaries (i.e. solo) were using "run(enforce_license: false)" instead of "run(enforce_license = false)" which chef-apply uses. If I changed this to "run(enforce_license: false)", this worked as expected. Signed-off-by: Lance Albertson <lance@osuosl.org>
* | | | Merge pull request #9989 from chef/matchTim Smith2020-06-148-9/+9
|\ \ \ \ | | | | | | | | | | Use .match? not =~ when match values aren't necessary
| * | | | Use .match? not =~ when match values aren't necessaryTim Smith2020-06-118-9/+9
| | |_|/ | |/| | | | | | | | | | | | | | | | | | Autocorrected from RuboCop Performance which is now smart enough to detect when you use the match and when you don't. Using match? does not create any objects so it's slightly faster and uses less memory. Signed-off-by: Tim Smith <tsmith@chef.io>
* | | | Add kitchen tests for snapdPhil Dibowitz2020-06-141-1/+1
|/ / / | | | | | | | | | Signed-off-by: Phil Dibowitz <phil@ipom.com>
* | | Fix a test to silence an rspec warning.cleanup-resource-inheritancePete Higgins2020-06-101-1/+1
| | | | | | | | | | | | Signed-off-by: Pete Higgins <pete@peterhiggins.org>
* | | Fix a test to avoid rspec warning.Pete Higgins2020-06-101-1/+1
| |/ |/| | | | | Signed-off-by: Pete Higgins <pete@peterhiggins.org>
* | Warn during bootstrapping when using validation keyswarn_on_validator_bootstrapTim Smith2020-06-091-2/+2
|/ | | | | | | | | | | | | We should highly encourage users to move to validatorless bootstrapping 1) It's more secure 2) It requires less admin work since there no validation key to pass around or rotate This also provides an improved message helping the user to move off the old keys and fixes some bad formatting where the 2nd line was indented about 40 columns. Signed-off-by: Tim Smith <tsmith@chef.io>
* Merge pull request #9952 from ↵Tim Smith2020-06-081-1/+1
|\ | | | | | | | | chef/Snehal/Github-#333_knife_vault_on_windows_10_fails knife vault on windows 10 fails due to ERROR: Chef::Exceptions::InvalidDataBagPath
| * Updated exception messageSnehal/Github-#333_knife_vault_on_windows_10_failssnehaldwivedi2020-06-051-1/+1
| | | | | | | | Signed-off-by: snehaldwivedi <sdwivedi@msystechnologies.com>
| * Updated exception message Chef::Exceptions::InvalidDataBagPathsnehaldwivedi2020-06-041-1/+1
| | | | | | | | Signed-off-by: snehaldwivedi <sdwivedi@msystechnologies.com>
* | Fix chefstyle violations.fix-wrong-unit-testPete Higgins2020-06-051-1/+1
| | | | | | | | Signed-off-by: Pete Higgins <pete@peterhiggins.org>
* | Fix wrong unit test exposed by cleaning up rspec deprecations.Pete Higgins2020-06-051-9/+1
| | | | | | | | Signed-off-by: Pete Higgins <pete@peterhiggins.org>
* | Merge pull request #9920 from chef-davin/masterTim Smith2020-06-051-5/+15
|\ \ | | | | | | Update to the chef_client_scheduled_task resource frequency_modify default functionality
| * | Modify my fixes for the windows unit tests so that I don't break all the ↵Davin Taddeo2020-06-031-4/+4
| | | | | | | | | | | | | | | | | | Linux unit tests... Signed-off-by: Davin Taddeo <davin@chef.io>
| * | unit test updates for chef_client_scheduled taskDavin Taddeo2020-06-031-5/+15
| | | | | | | | | | | | Signed-off-by: Davin Taddeo <davin@chef.io>
* | | Merge pull request #9932 from chef/script-resources-use-pipesTim Smith2020-06-054-170/+163
|\ \ \ | | | | | | | | Change script resources to use pipes rather than writing to temp files
| * | | Fix chefstyle.script-resources-use-pipesPete Higgins2020-06-031-2/+2
| | | | | | | | | | | | | | | | Signed-off-by: Pete Higgins <pete@peterhiggins.org>
| * | | Adapt old tests from Script provider to Batch provider.Pete Higgins2020-06-031-0/+130
| | | | | | | | | | | | | | | | Signed-off-by: Pete Higgins <pete@peterhiggins.org>
| * | | Move test of resource behavior to resource test.Pete Higgins2020-06-032-32/+10
| | | | | | | | | | | | | | | | Signed-off-by: Pete Higgins <pete@peterhiggins.org>
| * | | Fix script provider tests.Pete Higgins2020-06-031-110/+20
| | | | | | | | | | | | | | | | Signed-off-by: Pete Higgins <pete@peterhiggins.org>
| * | | Remove unnecessary cruft in test.Pete Higgins2020-06-031-25/+3
| | | | | | | | | | | | | | | | Signed-off-by: Pete Higgins <pete@peterhiggins.org>
| * | | Fix test stub.Pete Higgins2020-06-031-4/+1
| |/ / | | | | | | | | | Signed-off-by: Pete Higgins <pete@peterhiggins.org>