chef 14.14.29-universal-mingw32 → 14.15.6-universal-mingw32
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile +1 -1
- data/README.md +18 -7
- data/Rakefile +7 -4
- data/chef.gemspec +1 -1
- data/lib/chef/knife/ssh.rb +6 -0
- data/lib/chef/provider/ifconfig.rb +14 -5
- data/lib/chef/provider/windows_task.rb +9 -5
- data/lib/chef/resource/kernel_module.rb +61 -0
- data/lib/chef/resource/windows_task.rb +4 -0
- data/lib/chef/version.rb +1 -1
- data/spec/data/cookbooks/openldap/metadata.rb +2 -2
- data/spec/data/metadata/quick_start/metadata.rb +2 -7
- data/spec/functional/audit/runner_spec.rb +1 -1
- data/spec/functional/dsl/reboot_pending_spec.rb +7 -25
- data/spec/functional/event_loggers/windows_eventlog_spec.rb +6 -4
- data/spec/functional/file_content_management/deploy_strategies_spec.rb +21 -21
- data/spec/functional/knife/exec_spec.rb +1 -1
- data/spec/functional/knife/ssh_spec.rb +3 -3
- data/spec/functional/mixin/user_context_spec.rb +3 -1
- data/spec/functional/rebooter_spec.rb +1 -1
- data/spec/functional/resource/aix_service_spec.rb +1 -1
- data/spec/functional/resource/aixinit_service_spec.rb +1 -1
- data/spec/functional/resource/apt_package_spec.rb +1 -1
- data/spec/functional/resource/chocolatey_package_spec.rb +2 -2
- data/spec/functional/resource/cookbook_file_spec.rb +1 -3
- data/spec/functional/resource/cron_spec.rb +4 -3
- data/spec/functional/resource/dpkg_package_spec.rb +4 -4
- data/spec/functional/resource/dsc_resource_spec.rb +2 -1
- data/spec/functional/resource/dsc_script_spec.rb +16 -20
- data/spec/functional/resource/execute_spec.rb +2 -2
- data/spec/functional/resource/git_spec.rb +6 -6
- data/spec/functional/resource/group_spec.rb +8 -6
- data/spec/functional/resource/ifconfig_spec.rb +3 -5
- data/spec/functional/resource/link_spec.rb +2 -2
- data/spec/functional/resource/mount_spec.rb +3 -7
- data/spec/functional/resource/powershell_script_spec.rb +9 -8
- data/spec/functional/resource/reboot_spec.rb +1 -1
- data/spec/functional/resource/remote_file_spec.rb +2 -2
- data/spec/functional/resource/template_spec.rb +1 -1
- data/spec/functional/resource/user/windows_spec.rb +2 -2
- data/spec/functional/resource/windows_certificate_spec.rb +3 -3
- data/spec/functional/resource/windows_service_spec.rb +3 -3
- data/spec/functional/resource/windows_task_spec.rb +51 -0
- data/spec/functional/run_lock_spec.rb +10 -3
- data/spec/functional/shell_spec.rb +1 -1
- data/spec/functional/util/powershell/cmdlet_spec.rb +1 -1
- data/spec/functional/version_spec.rb +1 -1
- data/spec/functional/win32/security_spec.rb +12 -7
- data/spec/functional/win32/service_manager_spec.rb +1 -1
- data/spec/functional/win32/version_info_spec.rb +4 -4
- data/spec/integration/client/client_spec.rb +114 -132
- data/spec/integration/client/exit_code_spec.rb +8 -8
- data/spec/integration/client/ipv6_spec.rb +5 -5
- data/spec/integration/knife/chef_fs_data_store_spec.rb +38 -38
- data/spec/integration/knife/chef_repo_path_spec.rb +42 -42
- data/spec/integration/knife/chef_repository_file_system_spec.rb +9 -9
- data/spec/integration/knife/chefignore_spec.rb +13 -13
- data/spec/integration/knife/client_bulk_delete_spec.rb +8 -8
- data/spec/integration/knife/client_create_spec.rb +1 -1
- data/spec/integration/knife/client_delete_spec.rb +4 -4
- data/spec/integration/knife/client_key_delete_spec.rb +1 -1
- data/spec/integration/knife/client_key_list_spec.rb +1 -1
- data/spec/integration/knife/client_list_spec.rb +1 -1
- data/spec/integration/knife/common_options_spec.rb +1 -1
- data/spec/integration/knife/config_get_spec.rb +1 -1
- data/spec/integration/knife/config_list_profiles_spec.rb +2 -1
- data/spec/integration/knife/cookbook_api_ipv6_spec.rb +3 -3
- data/spec/integration/knife/cookbook_bulk_delete_spec.rb +3 -3
- data/spec/integration/knife/cookbook_download_spec.rb +4 -4
- data/spec/integration/knife/cookbook_list_spec.rb +2 -2
- data/spec/integration/knife/cookbook_show_spec.rb +3 -3
- data/spec/integration/knife/cookbook_upload_spec.rb +6 -6
- data/spec/integration/knife/data_bag_delete_spec.rb +4 -4
- data/spec/integration/knife/data_bag_from_file_spec.rb +7 -7
- data/spec/integration/knife/data_bag_list_spec.rb +1 -1
- data/spec/integration/knife/delete_spec.rb +37 -37
- data/spec/integration/knife/deps_spec.rb +23 -23
- data/spec/integration/knife/diff_spec.rb +23 -23
- data/spec/integration/knife/download_spec.rb +79 -79
- data/spec/integration/knife/environment_compare_spec.rb +3 -3
- data/spec/integration/knife/environment_from_file_spec.rb +6 -6
- data/spec/integration/knife/environment_list_spec.rb +1 -1
- data/spec/integration/knife/environment_show_spec.rb +4 -4
- data/spec/integration/knife/list_spec.rb +25 -25
- data/spec/integration/knife/node_bulk_delete_spec.rb +2 -2
- data/spec/integration/knife/node_delete_spec.rb +2 -2
- data/spec/integration/knife/node_environment_set_spec.rb +1 -1
- data/spec/integration/knife/node_from_file_spec.rb +2 -2
- data/spec/integration/knife/node_list_spec.rb +1 -1
- data/spec/integration/knife/raw_spec.rb +12 -12
- data/spec/integration/knife/redirection_spec.rb +1 -1
- data/spec/integration/knife/role_bulk_delete_spec.rb +2 -2
- data/spec/integration/knife/role_delete_spec.rb +2 -2
- data/spec/integration/knife/role_from_file_spec.rb +5 -5
- data/spec/integration/knife/role_list_spec.rb +1 -1
- data/spec/integration/knife/role_show_spec.rb +1 -1
- data/spec/integration/knife/show_spec.rb +10 -10
- data/spec/integration/knife/upload_spec.rb +85 -85
- data/spec/integration/recipes/accumulator_spec.rb +4 -4
- data/spec/integration/recipes/lwrp_inline_resources_spec.rb +6 -6
- data/spec/integration/recipes/lwrp_spec.rb +6 -6
- data/spec/integration/recipes/notifies_spec.rb +45 -45
- data/spec/integration/recipes/notifying_block_spec.rb +4 -4
- data/spec/integration/recipes/provider_choice.rb +1 -2
- data/spec/integration/recipes/recipe_dsl_spec.rb +9 -9
- data/spec/integration/recipes/remote_directory.rb +2 -2
- data/spec/integration/recipes/resource_action_spec.rb +1 -1
- data/spec/integration/recipes/resource_converge_if_changed_spec.rb +19 -19
- data/spec/integration/solo/solo_spec.rb +29 -29
- data/spec/scripts/ssl-serve.rb +1 -1
- data/spec/spec_helper.rb +11 -14
- data/spec/stress/win32/security_spec.rb +1 -1
- data/spec/support/lib/chef/resource/zen_follower.rb +1 -1
- data/spec/support/lib/chef/resource/zen_master.rb +1 -1
- data/spec/support/mock/platform.rb +2 -2
- data/spec/support/platform_helpers.rb +12 -3
- data/spec/support/platforms/win32/spec_service.rb +6 -10
- data/spec/support/shared/context/client.rb +2 -1
- data/spec/support/shared/functional/execute_resource.rb +4 -4
- data/spec/support/shared/functional/file_resource.rb +1 -3
- data/spec/support/shared/functional/http.rb +20 -44
- data/spec/support/shared/functional/securable_resource.rb +4 -8
- data/spec/support/shared/functional/win32_service.rb +1 -1
- data/spec/support/shared/functional/windows_script.rb +2 -1
- data/spec/support/shared/integration/app_server_support.rb +3 -4
- data/spec/support/shared/integration/integration_helper.rb +1 -0
- data/spec/support/shared/integration/knife_support.rb +5 -5
- data/spec/support/shared/unit/application_dot_d.rb +10 -4
- data/spec/support/shared/unit/file_system_support.rb +3 -2
- data/spec/support/shared/unit/platform_introspector.rb +12 -12
- data/spec/support/shared/unit/provider/file.rb +1 -1
- data/spec/support/shared/unit/script_resource.rb +1 -1
- data/spec/support/shared/unit/windows_script_resource.rb +1 -1
- data/spec/tiny_server.rb +1 -1
- data/spec/unit/api_client/registration_spec.rb +1 -1
- data/spec/unit/api_client_spec.rb +5 -5
- data/spec/unit/api_client_v1_spec.rb +6 -6
- data/spec/unit/application/client_spec.rb +8 -8
- data/spec/unit/application/exit_code_spec.rb +3 -2
- data/spec/unit/application/knife_spec.rb +1 -2
- data/spec/unit/audit/audit_event_proxy_spec.rb +14 -7
- data/spec/unit/audit/audit_reporter_spec.rb +20 -11
- data/spec/unit/audit/control_group_data_spec.rb +17 -12
- data/spec/unit/chef_fs/config_spec.rb +3 -3
- data/spec/unit/chef_fs/file_system/repository/directory_spec.rb +1 -1
- data/spec/unit/chef_fs/parallelizer.rb +1 -1
- data/spec/unit/client_spec.rb +3 -3
- data/spec/unit/config_fetcher_spec.rb +1 -1
- data/spec/unit/cookbook/metadata_spec.rb +13 -13
- data/spec/unit/cookbook/synchronizer_spec.rb +6 -6
- data/spec/unit/cookbook_loader_spec.rb +17 -17
- data/spec/unit/cookbook_manifest_spec.rb +9 -9
- data/spec/unit/cookbook_site_streaming_uploader_spec.rb +1 -2
- data/spec/unit/cookbook_uploader_spec.rb +2 -2
- data/spec/unit/cookbook_version_file_specificity_spec.rb +9 -9
- data/spec/unit/cookbook_version_spec.rb +2 -2
- data/spec/unit/data_bag_item_spec.rb +7 -7
- data/spec/unit/data_bag_spec.rb +1 -1
- data/spec/unit/data_collector_spec.rb +23 -23
- data/spec/unit/decorator_spec.rb +2 -2
- data/spec/unit/deprecated_spec.rb +2 -2
- data/spec/unit/dsl/data_query_spec.rb +3 -2
- data/spec/unit/dsl/declare_resource_spec.rb +1 -1
- data/spec/unit/dsl/platform_introspection_spec.rb +2 -2
- data/spec/unit/encrypted_data_bag_item/check_encrypted_spec.rb +2 -1
- data/spec/unit/encrypted_data_bag_item_spec.rb +2 -1
- data/spec/unit/environment_spec.rb +13 -13
- data/spec/unit/event_dispatch/dsl_spec.rb +1 -1
- data/spec/unit/file_content_management/deploy/mv_unix_spec.rb +3 -3
- data/spec/unit/file_content_management/deploy/mv_windows_spec.rb +2 -2
- data/spec/unit/formatters/error_inspectors/resource_failure_inspector_spec.rb +3 -3
- data/spec/unit/guard_interpreter/resource_guard_interpreter_spec.rb +1 -1
- data/spec/unit/http/authenticator_spec.rb +4 -3
- data/spec/unit/http/json_input_spec.rb +1 -1
- data/spec/unit/http/socketless_chef_zero_client_spec.rb +15 -15
- data/spec/unit/key_spec.rb +8 -8
- data/spec/unit/knife/bootstrap_spec.rb +14 -10
- data/spec/unit/knife/client_bulk_delete_spec.rb +4 -4
- data/spec/unit/knife/configure_client_spec.rb +1 -1
- data/spec/unit/knife/configure_spec.rb +1 -1
- data/spec/unit/knife/cookbook_bulk_delete_spec.rb +1 -1
- data/spec/unit/knife/cookbook_delete_spec.rb +2 -2
- data/spec/unit/knife/cookbook_download_spec.rb +2 -2
- data/spec/unit/knife/cookbook_metadata_spec.rb +4 -4
- data/spec/unit/knife/cookbook_upload_spec.rb +7 -5
- data/spec/unit/knife/core/bootstrap_context_spec.rb +1 -1
- data/spec/unit/knife/core/cookbook_scm_repo_spec.rb +2 -2
- data/spec/unit/knife/core/gem_glob_loader_spec.rb +4 -4
- data/spec/unit/knife/core/hashed_command_loader_spec.rb +4 -2
- data/spec/unit/knife/core/node_editor_spec.rb +12 -12
- data/spec/unit/knife/core/ui_spec.rb +11 -11
- data/spec/unit/knife/data_bag_from_file_spec.rb +2 -1
- data/spec/unit/knife/data_bag_show_spec.rb +2 -1
- data/spec/unit/knife/key_create_spec.rb +1 -1
- data/spec/unit/knife/key_delete_spec.rb +3 -3
- data/spec/unit/knife/key_edit_spec.rb +4 -4
- data/spec/unit/knife/key_list_spec.rb +1 -1
- data/spec/unit/knife/key_show_spec.rb +3 -3
- data/spec/unit/knife/node_bulk_delete_spec.rb +3 -3
- data/spec/unit/knife/node_delete_spec.rb +2 -2
- data/spec/unit/knife/node_edit_spec.rb +1 -1
- data/spec/unit/knife/node_environment_set_spec.rb +1 -1
- data/spec/unit/knife/node_from_file_spec.rb +1 -1
- data/spec/unit/knife/node_policy_set_spec.rb +1 -1
- data/spec/unit/knife/node_run_list_add_spec.rb +1 -1
- data/spec/unit/knife/node_run_list_remove_spec.rb +1 -1
- data/spec/unit/knife/node_run_list_set_spec.rb +1 -1
- data/spec/unit/knife/node_show_spec.rb +1 -1
- data/spec/unit/knife/raw_spec.rb +2 -2
- data/spec/unit/knife/role_bulk_delete_spec.rb +2 -2
- data/spec/unit/knife/role_create_spec.rb +1 -1
- data/spec/unit/knife/role_delete_spec.rb +1 -1
- data/spec/unit/knife/role_edit_spec.rb +1 -1
- data/spec/unit/knife/role_env_run_list_add_spec.rb +1 -1
- data/spec/unit/knife/role_env_run_list_clear_spec.rb +1 -1
- data/spec/unit/knife/role_env_run_list_remove_spec.rb +1 -1
- data/spec/unit/knife/role_env_run_list_replace_spec.rb +1 -1
- data/spec/unit/knife/role_env_run_list_set_spec.rb +1 -1
- data/spec/unit/knife/role_from_file_spec.rb +1 -1
- data/spec/unit/knife/role_run_list_add_spec.rb +1 -1
- data/spec/unit/knife/role_run_list_clear_spec.rb +1 -1
- data/spec/unit/knife/role_run_list_remove_spec.rb +1 -1
- data/spec/unit/knife/role_run_list_replace_spec.rb +1 -1
- data/spec/unit/knife/role_run_list_set_spec.rb +1 -1
- data/spec/unit/knife/ssh_spec.rb +27 -17
- data/spec/unit/knife/ssl_check_spec.rb +4 -4
- data/spec/unit/knife/ssl_fetch_spec.rb +5 -5
- data/spec/unit/knife/status_spec.rb +3 -2
- data/spec/unit/knife/supermarket_download_spec.rb +4 -4
- data/spec/unit/knife/supermarket_install_spec.rb +5 -4
- data/spec/unit/knife/supermarket_share_spec.rb +1 -1
- data/spec/unit/knife_spec.rb +34 -33
- data/spec/unit/lwrp_spec.rb +19 -19
- data/spec/unit/mixin/homebrew_user_spec.rb +1 -1
- data/spec/unit/mixin/params_validate_spec.rb +10 -10
- data/spec/unit/mixin/properties_spec.rb +4 -4
- data/spec/unit/mixin/shell_out_spec.rb +27 -27
- data/spec/unit/mixin/template_spec.rb +4 -8
- data/spec/unit/mixin/unformatter_spec.rb +1 -2
- data/spec/unit/mixin/user_context_spec.rb +1 -2
- data/spec/unit/mixin/which.rb +2 -0
- data/spec/unit/mixin/windows_architecture_helper_spec.rb +3 -3
- data/spec/unit/node/attribute_spec.rb +79 -79
- data/spec/unit/node/immutable_collections_spec.rb +50 -50
- data/spec/unit/node_spec.rb +16 -16
- data/spec/unit/org_spec.rb +3 -3
- data/spec/unit/policy_builder/policyfile_spec.rb +2 -2
- data/spec/unit/property/state_spec.rb +26 -25
- data/spec/unit/property/validation_spec.rb +14 -13
- data/spec/unit/property_spec.rb +10 -9
- data/spec/unit/provider/apt_update_spec.rb +6 -6
- data/spec/unit/provider/cron_spec.rb +15 -15
- data/spec/unit/provider/dsc_resource_spec.rb +6 -3
- data/spec/unit/provider/dsc_script_spec.rb +1 -1
- data/spec/unit/provider/execute_spec.rb +5 -5
- data/spec/unit/provider/git_spec.rb +39 -39
- data/spec/unit/provider/group/dscl_spec.rb +3 -3
- data/spec/unit/provider/group/groupadd_spec.rb +1 -1
- data/spec/unit/provider/group_spec.rb +2 -3
- data/spec/unit/provider/ifconfig/aix_spec.rb +1 -1
- data/spec/unit/provider/ifconfig/debian_spec.rb +2 -2
- data/spec/unit/provider/ifconfig_spec.rb +45 -16
- data/spec/unit/provider/launchd_spec.rb +23 -15
- data/spec/unit/provider/link_spec.rb +22 -11
- data/spec/unit/provider/mount/aix_spec.rb +6 -6
- data/spec/unit/provider/mount/mount_spec.rb +31 -31
- data/spec/unit/provider/mount/solaris_spec.rb +11 -11
- data/spec/unit/provider/ohai_spec.rb +1 -1
- data/spec/unit/provider/osx_profile_spec.rb +5 -7
- data/spec/unit/provider/package/apt_spec.rb +5 -5
- data/spec/unit/provider/package/bff_spec.rb +1 -1
- data/spec/unit/provider/package/cab_spec.rb +1 -1
- data/spec/unit/provider/package/chocolatey_spec.rb +8 -8
- data/spec/unit/provider/package/freebsd/pkg_spec.rb +1 -1
- data/spec/unit/provider/package/ips_spec.rb +6 -6
- data/spec/unit/provider/package/macports_spec.rb +1 -1
- data/spec/unit/provider/package/msu_spec.rb +1 -1
- data/spec/unit/provider/package/openbsd_spec.rb +15 -11
- data/spec/unit/provider/package/pacman_spec.rb +3 -3
- data/spec/unit/provider/package/paludis_spec.rb +4 -4
- data/spec/unit/provider/package/portage_spec.rb +1 -1
- data/spec/unit/provider/package/powershell_spec.rb +1 -1
- data/spec/unit/provider/package/smartos_spec.rb +3 -3
- data/spec/unit/provider/package/solaris_spec.rb +1 -1
- data/spec/unit/provider/package/windows/exe_spec.rb +9 -9
- data/spec/unit/provider/package/windows/msi_spec.rb +7 -7
- data/spec/unit/provider/package/windows_spec.rb +2 -1
- data/spec/unit/provider/package/yum/yum_cache_spec.rb +1 -1
- data/spec/unit/provider/package/zypper_spec.rb +4 -4
- data/spec/unit/provider/package_spec.rb +1 -1
- data/spec/unit/provider/powershell_script_spec.rb +7 -7
- data/spec/unit/provider/registry_key_spec.rb +1 -1
- data/spec/unit/provider/remote_directory_spec.rb +6 -6
- data/spec/unit/provider/route_spec.rb +11 -11
- data/spec/unit/provider/service/arch_service_spec.rb +13 -13
- data/spec/unit/provider/service/debian_service_spec.rb +2 -1
- data/spec/unit/provider/service/freebsd_service_spec.rb +28 -24
- data/spec/unit/provider/service/gentoo_service_spec.rb +2 -2
- data/spec/unit/provider/service/init_service_spec.rb +11 -11
- data/spec/unit/provider/service/invokercd_service_spec.rb +11 -11
- data/spec/unit/provider/service/macosx_spec.rb +5 -5
- data/spec/unit/provider/service/openbsd_service_spec.rb +15 -11
- data/spec/unit/provider/service/simple_service_spec.rb +7 -7
- data/spec/unit/provider/service/upstart_service_spec.rb +14 -14
- data/spec/unit/provider/service/windows_spec.rb +53 -35
- data/spec/unit/provider/subversion_spec.rb +8 -4
- data/spec/unit/provider/systemd_unit_spec.rb +142 -142
- data/spec/unit/provider/template/content_spec.rb +29 -29
- data/spec/unit/provider/windows_task_spec.rb +1 -1
- data/spec/unit/provider_resolver_spec.rb +75 -75
- data/spec/unit/provider_spec.rb +2 -4
- data/spec/unit/recipe_spec.rb +4 -4
- data/spec/unit/resource/batch_spec.rb +1 -1
- data/spec/unit/resource/chef_gem_spec.rb +1 -1
- data/spec/unit/resource/chocolatey_config_spec.rb +1 -1
- data/spec/unit/resource/chocolatey_source_spec.rb +1 -1
- data/spec/unit/resource/directory_spec.rb +1 -1
- data/spec/unit/resource/dnf_package_spec.rb +1 -1
- data/spec/unit/resource/dsc_resource_spec.rb +1 -1
- data/spec/unit/resource/file/verification_spec.rb +1 -2
- data/spec/unit/resource/file_spec.rb +1 -1
- data/spec/unit/resource/group_spec.rb +1 -1
- data/spec/unit/resource/link_spec.rb +1 -1
- data/spec/unit/resource/osx_profile_spec.rb +2 -1
- data/spec/unit/resource/powershell_script_spec.rb +12 -7
- data/spec/unit/resource/registry_key_spec.rb +3 -3
- data/spec/unit/resource/rhsm_subscription_spec.rb +1 -1
- data/spec/unit/resource/service_spec.rb +1 -1
- data/spec/unit/resource/template_spec.rb +2 -2
- data/spec/unit/resource/windows_env_spec.rb +1 -1
- data/spec/unit/resource/windows_service_spec.rb +5 -5
- data/spec/unit/resource/windows_task_spec.rb +6 -2
- data/spec/unit/resource/yum_package_spec.rb +1 -1
- data/spec/unit/resource_collection/resource_list_spec.rb +1 -1
- data/spec/unit/resource_collection/resource_set_spec.rb +7 -7
- data/spec/unit/resource_collection/stepable_iterator_spec.rb +2 -2
- data/spec/unit/resource_collection_spec.rb +4 -4
- data/spec/unit/resource_definition_spec.rb +2 -2
- data/spec/unit/resource_inspector_spec.rb +1 -1
- data/spec/unit/resource_reporter_spec.rb +4 -4
- data/spec/unit/resource_spec.rb +22 -22
- data/spec/unit/role_spec.rb +3 -3
- data/spec/unit/run_context/cookbook_compiler_spec.rb +23 -23
- data/spec/unit/run_list/run_list_expansion_spec.rb +9 -6
- data/spec/unit/run_list_spec.rb +1 -1
- data/spec/unit/runner_spec.rb +3 -3
- data/spec/unit/search/query_spec.rb +3 -2
- data/spec/unit/shell/model_wrapper_spec.rb +1 -1
- data/spec/unit/shell/shell_session_spec.rb +8 -11
- data/spec/unit/shell_spec.rb +1 -2
- data/spec/unit/user_spec.rb +4 -4
- data/spec/unit/user_v1_spec.rb +3 -3
- data/spec/unit/util/backup_spec.rb +1 -1
- data/spec/unit/util/dsc/lcm_output_parser_spec.rb +13 -13
- data/spec/unit/util/dsc/local_configuration_manager_spec.rb +3 -3
- data/spec/unit/util/editor_spec.rb +1 -1
- data/spec/unit/util/powershell/ps_credential_spec.rb +3 -2
- data/spec/unit/util/threaded_job_queue_spec.rb +2 -2
- data/spec/unit/version_class_spec.rb +4 -4
- data/spec/unit/win32/registry_spec.rb +5 -5
- data/spec/unit/win32/security_spec.rb +2 -1
- data/tasks/announce.rb +4 -11
- metadata +10 -6
- data/tasks/maintainers.rb +0 -211
- data/tasks/templates/prerelease.md.erb +0 -35
@@ -46,7 +46,7 @@ describe "knife deps", :workstation do
|
|
46
46
|
/cookbooks/quiche
|
47
47
|
/cookbooks/soup
|
48
48
|
/roles/starring.json
|
49
|
-
EOM
|
49
|
+
EOM
|
50
50
|
end
|
51
51
|
end
|
52
52
|
|
@@ -65,7 +65,7 @@ EOM
|
|
65
65
|
/cookbooks/quiche
|
66
66
|
/cookbooks/soup
|
67
67
|
/roles/starring.json
|
68
|
-
EOM
|
68
|
+
EOM
|
69
69
|
end
|
70
70
|
end
|
71
71
|
|
@@ -99,7 +99,7 @@ EOM
|
|
99
99
|
/cookbooks/quiche
|
100
100
|
/cookbooks/soup
|
101
101
|
/nodes/mort.json
|
102
|
-
EOM
|
102
|
+
EOM
|
103
103
|
end
|
104
104
|
end
|
105
105
|
when_the_repository "has a cookbook with no dependencies" do
|
@@ -155,7 +155,7 @@ depends "kettle"'
|
|
155
155
|
/cookbooks/soup
|
156
156
|
/roles/starring.json
|
157
157
|
/nodes/mort.json
|
158
|
-
EOM
|
158
|
+
EOM
|
159
159
|
end
|
160
160
|
it "knife deps * reports all dependencies of all things" do
|
161
161
|
knife("deps /nodes/*").should_succeed <<~EOM
|
@@ -166,7 +166,7 @@ EOM
|
|
166
166
|
/cookbooks/soup
|
167
167
|
/roles/starring.json
|
168
168
|
/nodes/mort.json
|
169
|
-
EOM
|
169
|
+
EOM
|
170
170
|
end
|
171
171
|
it "knife deps a b reports all dependencies of a and b" do
|
172
172
|
knife("deps /nodes/bart.json /nodes/mort.json").should_succeed <<~EOM
|
@@ -177,7 +177,7 @@ EOM
|
|
177
177
|
/cookbooks/soup
|
178
178
|
/roles/starring.json
|
179
179
|
/nodes/mort.json
|
180
|
-
EOM
|
180
|
+
EOM
|
181
181
|
end
|
182
182
|
it "knife deps --tree /* shows dependencies in a tree" do
|
183
183
|
knife("deps --tree /nodes/*").should_succeed <<~EOM
|
@@ -189,7 +189,7 @@ EOM
|
|
189
189
|
/roles/minor.json
|
190
190
|
/cookbooks/quiche
|
191
191
|
/cookbooks/soup
|
192
|
-
EOM
|
192
|
+
EOM
|
193
193
|
end
|
194
194
|
it "knife deps --tree --no-recurse shows only the first level of dependencies" do
|
195
195
|
knife("deps --tree --no-recurse /nodes/*").should_succeed <<~EOM
|
@@ -198,7 +198,7 @@ EOM
|
|
198
198
|
/nodes/mort.json
|
199
199
|
/environments/desert.json
|
200
200
|
/roles/starring.json
|
201
|
-
EOM
|
201
|
+
EOM
|
202
202
|
end
|
203
203
|
end
|
204
204
|
|
@@ -237,7 +237,7 @@ depends "foo"'
|
|
237
237
|
/roles/bar.json
|
238
238
|
/roles/foo.json
|
239
239
|
/roles/self.json
|
240
|
-
EOM
|
240
|
+
EOM
|
241
241
|
end
|
242
242
|
it "knife deps --tree prints each once" do
|
243
243
|
knife("deps --tree /roles/foo.json /roles/self.json") do
|
@@ -383,7 +383,7 @@ EOM
|
|
383
383
|
/cookbooks/quiche
|
384
384
|
/cookbooks/soup
|
385
385
|
/roles/starring.json
|
386
|
-
EOM
|
386
|
+
EOM
|
387
387
|
end
|
388
388
|
end
|
389
389
|
|
@@ -400,7 +400,7 @@ EOM
|
|
400
400
|
/cookbooks/quiche
|
401
401
|
/cookbooks/soup
|
402
402
|
/roles/starring.json
|
403
|
-
EOM
|
403
|
+
EOM
|
404
404
|
end
|
405
405
|
end
|
406
406
|
|
@@ -432,7 +432,7 @@ EOM
|
|
432
432
|
/cookbooks/quiche
|
433
433
|
/cookbooks/soup
|
434
434
|
/nodes/mort.json
|
435
|
-
EOM
|
435
|
+
EOM
|
436
436
|
end
|
437
437
|
end
|
438
438
|
when_the_chef_server "has a cookbook with no dependencies" do
|
@@ -484,7 +484,7 @@ depends "kettle"', "recipes" => { "default.rb" => "" } }
|
|
484
484
|
/cookbooks/soup
|
485
485
|
/roles/starring.json
|
486
486
|
/nodes/mort.json
|
487
|
-
EOM
|
487
|
+
EOM
|
488
488
|
end
|
489
489
|
it "knife deps * reports all dependencies of all things" do
|
490
490
|
knife("deps --remote /nodes/*").should_succeed <<~EOM
|
@@ -495,7 +495,7 @@ EOM
|
|
495
495
|
/cookbooks/soup
|
496
496
|
/roles/starring.json
|
497
497
|
/nodes/mort.json
|
498
|
-
EOM
|
498
|
+
EOM
|
499
499
|
end
|
500
500
|
it "knife deps a b reports all dependencies of a and b" do
|
501
501
|
knife("deps --remote /nodes/bart.json /nodes/mort.json").should_succeed <<~EOM
|
@@ -506,7 +506,7 @@ EOM
|
|
506
506
|
/cookbooks/soup
|
507
507
|
/roles/starring.json
|
508
508
|
/nodes/mort.json
|
509
|
-
EOM
|
509
|
+
EOM
|
510
510
|
end
|
511
511
|
it "knife deps --tree /* shows dependencies in a tree" do
|
512
512
|
knife("deps --remote --tree /nodes/*").should_succeed <<~EOM
|
@@ -518,7 +518,7 @@ EOM
|
|
518
518
|
/roles/minor.json
|
519
519
|
/cookbooks/quiche
|
520
520
|
/cookbooks/soup
|
521
|
-
EOM
|
521
|
+
EOM
|
522
522
|
end
|
523
523
|
it "knife deps --tree --no-recurse shows only the first level of dependencies" do
|
524
524
|
knife("deps --remote --tree --no-recurse /nodes/*").should_succeed <<~EOM
|
@@ -527,18 +527,18 @@ EOM
|
|
527
527
|
/nodes/mort.json
|
528
528
|
/environments/desert.json
|
529
529
|
/roles/starring.json
|
530
|
-
EOM
|
530
|
+
EOM
|
531
531
|
end
|
532
532
|
end
|
533
533
|
|
534
534
|
context "circular dependencies" do
|
535
535
|
when_the_chef_server "has cookbooks with circular dependencies" do
|
536
536
|
before do
|
537
|
-
cookbook "foo", "1.0.0", { "metadata.rb"
|
537
|
+
cookbook "foo", "1.0.0", { "metadata.rb" => 'name "foo"
|
538
538
|
depends "bar"' }
|
539
|
-
cookbook "bar", "1.0.0", { "metadata.rb"
|
539
|
+
cookbook "bar", "1.0.0", { "metadata.rb" => 'name "bar"
|
540
540
|
depends "baz"' }
|
541
|
-
cookbook "baz", "1.0.0", { "metadata.rb"
|
541
|
+
cookbook "baz", "1.0.0", { "metadata.rb" => 'name "baz"
|
542
542
|
depends "foo"' }
|
543
543
|
cookbook "self", "1.0.0", { "metadata.rb" => 'name "self"
|
544
544
|
depends "self"' }
|
@@ -549,7 +549,7 @@ depends "self"' }
|
|
549
549
|
/cookbooks/bar
|
550
550
|
/cookbooks/foo
|
551
551
|
/cookbooks/self
|
552
|
-
EOM
|
552
|
+
EOM
|
553
553
|
end
|
554
554
|
it "knife deps --tree prints each once" do
|
555
555
|
knife("deps --remote --tree /cookbooks/foo /cookbooks/self").should_succeed <<~EOM
|
@@ -559,7 +559,7 @@ EOM
|
|
559
559
|
/cookbooks/foo
|
560
560
|
/cookbooks/self
|
561
561
|
/cookbooks/self
|
562
|
-
EOM
|
562
|
+
EOM
|
563
563
|
end
|
564
564
|
end
|
565
565
|
when_the_chef_server "has roles with circular dependencies" do
|
@@ -575,7 +575,7 @@ EOM
|
|
575
575
|
/roles/bar.json
|
576
576
|
/roles/foo.json
|
577
577
|
/roles/self.json
|
578
|
-
EOM
|
578
|
+
EOM
|
579
579
|
end
|
580
580
|
it "knife deps --tree prints each once" do
|
581
581
|
knife("deps --remote --tree /roles/foo.json /roles/self.json") do
|
@@ -58,7 +58,7 @@ describe "knife diff", :workstation do
|
|
58
58
|
D\t/roles/x.json
|
59
59
|
D\t/users/admin.json
|
60
60
|
D\t/users/x.json
|
61
|
-
EOM
|
61
|
+
EOM
|
62
62
|
end
|
63
63
|
end
|
64
64
|
|
@@ -96,13 +96,13 @@ EOM
|
|
96
96
|
{
|
97
97
|
"foo": "bar"
|
98
98
|
}
|
99
|
-
EOM
|
99
|
+
EOM
|
100
100
|
end
|
101
101
|
|
102
102
|
it "knife diff reports the role as different" do
|
103
103
|
knife("diff --name-status /").should_succeed <<~EOM
|
104
104
|
M\t/roles/x.json
|
105
|
-
EOM
|
105
|
+
EOM
|
106
106
|
end
|
107
107
|
end
|
108
108
|
|
@@ -130,7 +130,7 @@ EOM
|
|
130
130
|
A\t/nodes/y.json
|
131
131
|
A\t/roles/y.json
|
132
132
|
A\t/users/y.json
|
133
|
-
EOM
|
133
|
+
EOM
|
134
134
|
end
|
135
135
|
|
136
136
|
context "when cwd is the data_bags directory" do
|
@@ -139,13 +139,13 @@ EOM
|
|
139
139
|
knife("diff --name-status").should_succeed <<~EOM
|
140
140
|
A\tx/z.json
|
141
141
|
A\ty
|
142
|
-
EOM
|
142
|
+
EOM
|
143
143
|
end
|
144
144
|
it "knife diff * reports different data bags" do
|
145
145
|
knife("diff --name-status *").should_succeed <<~EOM
|
146
146
|
A\tx/z.json
|
147
147
|
A\ty
|
148
|
-
EOM
|
148
|
+
EOM
|
149
149
|
end
|
150
150
|
end
|
151
151
|
end
|
@@ -161,7 +161,7 @@ EOM
|
|
161
161
|
D\t/nodes
|
162
162
|
D\t/roles
|
163
163
|
D\t/users
|
164
|
-
EOM
|
164
|
+
EOM
|
165
165
|
end
|
166
166
|
end
|
167
167
|
end
|
@@ -183,14 +183,14 @@ EOM
|
|
183
183
|
M\t/cookbooks/x/metadata.rb
|
184
184
|
D\t/cookbooks/x/onlyin1.0.1.rb
|
185
185
|
A\t/cookbooks/x/onlyin1.0.0.rb
|
186
|
-
EOM
|
186
|
+
EOM
|
187
187
|
end
|
188
188
|
|
189
189
|
it "knife diff --diff-filter=MAT does not show deleted files" do
|
190
190
|
knife("diff --diff-filter=MAT --name-status /cookbooks/x").should_succeed <<~EOM
|
191
191
|
M\t/cookbooks/x/metadata.rb
|
192
192
|
A\t/cookbooks/x/onlyin1.0.0.rb
|
193
|
-
EOM
|
193
|
+
EOM
|
194
194
|
end
|
195
195
|
end
|
196
196
|
|
@@ -214,7 +214,7 @@ EOM
|
|
214
214
|
M\t/cookbooks/x/metadata.rb
|
215
215
|
D\t/cookbooks/x/onlyin1.0.1.rb
|
216
216
|
A\t/cookbooks/x/onlyin1.0.0.rb
|
217
|
-
EOM
|
217
|
+
EOM
|
218
218
|
end
|
219
219
|
end
|
220
220
|
|
@@ -228,7 +228,7 @@ EOM
|
|
228
228
|
M\t/cookbooks/x/metadata.rb
|
229
229
|
D\t/cookbooks/x/onlyin0.9.9.rb
|
230
230
|
A\t/cookbooks/x/onlyin1.0.0.rb
|
231
|
-
EOM
|
231
|
+
EOM
|
232
232
|
end
|
233
233
|
end
|
234
234
|
end
|
@@ -309,7 +309,7 @@ EOM
|
|
309
309
|
when_the_repository "has an environment with bad JSON" do
|
310
310
|
before { file "environments/x.json", "{" }
|
311
311
|
it "knife diff reports an error and does a textual diff" do
|
312
|
-
error_text = "WARN: Parse error reading #{path_to(
|
312
|
+
error_text = "WARN: Parse error reading #{path_to("environments/x.json")} as JSON: parse error: premature EOF"
|
313
313
|
error_match = Regexp.new(Regexp.escape(error_text))
|
314
314
|
knife("diff /environments/x.json").should_succeed(/- "name": "x"/, stderr: error_match)
|
315
315
|
end
|
@@ -353,7 +353,7 @@ EOM
|
|
353
353
|
D\t/roles/x.json
|
354
354
|
D\t/users/admin.json
|
355
355
|
D\t/users/x.json
|
356
|
-
EOM
|
356
|
+
EOM
|
357
357
|
end
|
358
358
|
end
|
359
359
|
|
@@ -390,13 +390,13 @@ EOM
|
|
390
390
|
{
|
391
391
|
"foo": "bar"
|
392
392
|
}
|
393
|
-
EOM
|
393
|
+
EOM
|
394
394
|
end
|
395
395
|
|
396
396
|
it "knife diff reports the role as different" do
|
397
397
|
knife("diff --name-status /").should_succeed <<~EOM
|
398
398
|
M\t/roles/x.json
|
399
|
-
EOM
|
399
|
+
EOM
|
400
400
|
end
|
401
401
|
end
|
402
402
|
|
@@ -426,7 +426,7 @@ EOM
|
|
426
426
|
A\t/nodes/y.json
|
427
427
|
A\t/roles/y.json
|
428
428
|
A\t/users/y.json
|
429
|
-
EOM
|
429
|
+
EOM
|
430
430
|
end
|
431
431
|
|
432
432
|
context "when cwd is the data_bags directory" do
|
@@ -435,13 +435,13 @@ EOM
|
|
435
435
|
knife("diff --name-status").should_succeed <<~EOM
|
436
436
|
A\tx/z.json
|
437
437
|
A\ty
|
438
|
-
EOM
|
438
|
+
EOM
|
439
439
|
end
|
440
440
|
it "knife diff * reports different data bags" do
|
441
441
|
knife("diff --name-status *").should_succeed <<~EOM
|
442
442
|
A\tx/z.json
|
443
443
|
A\ty
|
444
|
-
EOM
|
444
|
+
EOM
|
445
445
|
end
|
446
446
|
end
|
447
447
|
end
|
@@ -457,7 +457,7 @@ EOM
|
|
457
457
|
D\t/nodes
|
458
458
|
D\t/roles
|
459
459
|
D\t/users
|
460
|
-
EOM
|
460
|
+
EOM
|
461
461
|
end
|
462
462
|
end
|
463
463
|
end
|
@@ -477,7 +477,7 @@ EOM
|
|
477
477
|
it "knife diff /cookbooks shows differences" do
|
478
478
|
knife("diff --name-status /cookbooks").should_succeed <<~EOM
|
479
479
|
D\t/cookbooks/x-1.0.1
|
480
|
-
EOM
|
480
|
+
EOM
|
481
481
|
end
|
482
482
|
|
483
483
|
it "knife diff --diff-filter=MAT does not show deleted files" do
|
@@ -504,7 +504,7 @@ EOM
|
|
504
504
|
knife("diff --name-status /cookbooks").should_succeed <<~EOM
|
505
505
|
D\t/cookbooks/x-1.0.1
|
506
506
|
A\t/cookbooks/x-1.0.0
|
507
|
-
EOM
|
507
|
+
EOM
|
508
508
|
end
|
509
509
|
end
|
510
510
|
|
@@ -517,7 +517,7 @@ EOM
|
|
517
517
|
knife("diff --name-status /cookbooks").should_succeed <<~EOM
|
518
518
|
D\t/cookbooks/x-0.9.9
|
519
519
|
A\t/cookbooks/x-1.0.0
|
520
|
-
EOM
|
520
|
+
EOM
|
521
521
|
end
|
522
522
|
end
|
523
523
|
end
|
@@ -592,7 +592,7 @@ EOM
|
|
592
592
|
when_the_repository "has an environment with bad JSON" do
|
593
593
|
before { file "environments/x.json", "{" }
|
594
594
|
it "knife diff reports an error and does a textual diff" do
|
595
|
-
error_text = "WARN: Parse error reading #{path_to(
|
595
|
+
error_text = "WARN: Parse error reading #{path_to("environments/x.json")} as JSON: parse error: premature EOF"
|
596
596
|
error_match = Regexp.new(Regexp.escape(error_text))
|
597
597
|
knife("diff /environments/x.json").should_succeed(/- "name": "x"/, stderr: error_match)
|
598
598
|
end
|
@@ -62,7 +62,7 @@ describe "knife download", :workstation do
|
|
62
62
|
Created /roles/x.json
|
63
63
|
Created /users/admin.json
|
64
64
|
Created /users/x.json
|
65
|
-
EOM
|
65
|
+
EOM
|
66
66
|
knife("diff --name-status /").should_succeed ""
|
67
67
|
end
|
68
68
|
end
|
@@ -110,7 +110,7 @@ EOM
|
|
110
110
|
|
111
111
|
]
|
112
112
|
}
|
113
|
-
EOM
|
113
|
+
EOM
|
114
114
|
end
|
115
115
|
|
116
116
|
it "knife download changes the role" do
|
@@ -142,7 +142,7 @@ EOM
|
|
142
142
|
|
143
143
|
]
|
144
144
|
}
|
145
|
-
EOM
|
145
|
+
EOM
|
146
146
|
end
|
147
147
|
|
148
148
|
it "knife download / does not change anything" do
|
@@ -176,7 +176,7 @@ EOM
|
|
176
176
|
A\t/nodes/y.json
|
177
177
|
A\t/roles/y.json
|
178
178
|
A\t/users/y.json
|
179
|
-
EOM
|
179
|
+
EOM
|
180
180
|
end
|
181
181
|
|
182
182
|
it "knife download --purge deletes the extra files" do
|
@@ -190,7 +190,7 @@ EOM
|
|
190
190
|
Deleted extra entry /nodes/y.json (purge is on)
|
191
191
|
Deleted extra entry /roles/y.json (purge is on)
|
192
192
|
Deleted extra entry /users/y.json (purge is on)
|
193
|
-
EOM
|
193
|
+
EOM
|
194
194
|
knife("diff --name-status /").should_succeed ""
|
195
195
|
end
|
196
196
|
end
|
@@ -219,7 +219,7 @@ EOM
|
|
219
219
|
Created /users
|
220
220
|
Created /users/admin.json
|
221
221
|
Created /users/x.json
|
222
|
-
EOM
|
222
|
+
EOM
|
223
223
|
knife("diff --name-status /").should_succeed ""
|
224
224
|
end
|
225
225
|
|
@@ -245,7 +245,7 @@ EOM
|
|
245
245
|
Created /users
|
246
246
|
Created /users/admin.json
|
247
247
|
Created /users/x.json
|
248
|
-
EOM
|
248
|
+
EOM
|
249
249
|
knife("diff --name-status /").should_succeed ""
|
250
250
|
end
|
251
251
|
|
@@ -273,10 +273,10 @@ EOM
|
|
273
273
|
Created /data_bags
|
274
274
|
Created /data_bags/x
|
275
275
|
Created /data_bags/x/y.json
|
276
|
-
EOM
|
276
|
+
EOM
|
277
277
|
knife("diff --name-status /data_bags").should_succeed <<~EOM
|
278
278
|
D\t/data_bags/x/z.json
|
279
|
-
EOM
|
279
|
+
EOM
|
280
280
|
end
|
281
281
|
|
282
282
|
it "knife download /data_bags/x /data_bags/x/y.json downloads x once" do
|
@@ -285,7 +285,7 @@ EOM
|
|
285
285
|
Created /data_bags/x
|
286
286
|
Created /data_bags/x/y.json
|
287
287
|
Created /data_bags/x/z.json
|
288
|
-
EOM
|
288
|
+
EOM
|
289
289
|
end
|
290
290
|
end
|
291
291
|
end
|
@@ -296,17 +296,17 @@ EOM
|
|
296
296
|
{
|
297
297
|
"id": "deleted"
|
298
298
|
}
|
299
|
-
EOM
|
299
|
+
EOM
|
300
300
|
file "data_bags/x/modified.json", <<~EOM
|
301
301
|
{
|
302
302
|
"id": "modified"
|
303
303
|
}
|
304
|
-
EOM
|
304
|
+
EOM
|
305
305
|
file "data_bags/x/unmodified.json", <<~EOM
|
306
306
|
{
|
307
307
|
"id": "unmodified"
|
308
308
|
}
|
309
|
-
EOM
|
309
|
+
EOM
|
310
310
|
end
|
311
311
|
|
312
312
|
when_the_chef_server "has a modified, unmodified, added and deleted data bag item" do
|
@@ -321,11 +321,11 @@ EOM
|
|
321
321
|
it "knife download of the modified file succeeds" do
|
322
322
|
knife("download /data_bags/x/modified.json").should_succeed <<~EOM
|
323
323
|
Updated /data_bags/x/modified.json
|
324
|
-
EOM
|
324
|
+
EOM
|
325
325
|
knife("diff --name-status /data_bags").should_succeed <<~EOM
|
326
326
|
D\t/data_bags/x/added.json
|
327
327
|
A\t/data_bags/x/deleted.json
|
328
|
-
EOM
|
328
|
+
EOM
|
329
329
|
end
|
330
330
|
it "knife download of the unmodified file does nothing" do
|
331
331
|
knife("download /data_bags/x/unmodified.json").should_succeed ""
|
@@ -333,16 +333,16 @@ EOM
|
|
333
333
|
D\t/data_bags/x/added.json
|
334
334
|
M\t/data_bags/x/modified.json
|
335
335
|
A\t/data_bags/x/deleted.json
|
336
|
-
EOM
|
336
|
+
EOM
|
337
337
|
end
|
338
338
|
it "knife download of the added file succeeds" do
|
339
339
|
knife("download /data_bags/x/added.json").should_succeed <<~EOM
|
340
340
|
Created /data_bags/x/added.json
|
341
|
-
EOM
|
341
|
+
EOM
|
342
342
|
knife("diff --name-status /data_bags").should_succeed <<~EOM
|
343
343
|
M\t/data_bags/x/modified.json
|
344
344
|
A\t/data_bags/x/deleted.json
|
345
|
-
EOM
|
345
|
+
EOM
|
346
346
|
end
|
347
347
|
it "knife download of the deleted file does nothing" do
|
348
348
|
knife("download /data_bags/x/deleted.json").should_succeed ""
|
@@ -350,32 +350,32 @@ EOM
|
|
350
350
|
D\t/data_bags/x/added.json
|
351
351
|
M\t/data_bags/x/modified.json
|
352
352
|
A\t/data_bags/x/deleted.json
|
353
|
-
EOM
|
353
|
+
EOM
|
354
354
|
end
|
355
355
|
it "knife download --purge of the deleted file deletes it" do
|
356
356
|
knife("download --purge /data_bags/x/deleted.json").should_succeed <<~EOM
|
357
357
|
Deleted extra entry /data_bags/x/deleted.json (purge is on)
|
358
|
-
EOM
|
358
|
+
EOM
|
359
359
|
knife("diff --name-status /data_bags").should_succeed <<~EOM
|
360
360
|
D\t/data_bags/x/added.json
|
361
361
|
M\t/data_bags/x/modified.json
|
362
|
-
EOM
|
362
|
+
EOM
|
363
363
|
end
|
364
364
|
it "knife download of the entire data bag downloads everything" do
|
365
365
|
knife("download /data_bags/x").should_succeed <<~EOM
|
366
366
|
Created /data_bags/x/added.json
|
367
367
|
Updated /data_bags/x/modified.json
|
368
|
-
EOM
|
368
|
+
EOM
|
369
369
|
knife("diff --name-status /data_bags").should_succeed <<~EOM
|
370
370
|
A\t/data_bags/x/deleted.json
|
371
|
-
EOM
|
371
|
+
EOM
|
372
372
|
end
|
373
373
|
it "knife download --purge of the entire data bag downloads everything" do
|
374
374
|
knife("download --purge /data_bags/x").should_succeed <<~EOM
|
375
375
|
Created /data_bags/x/added.json
|
376
376
|
Updated /data_bags/x/modified.json
|
377
377
|
Deleted extra entry /data_bags/x/deleted.json (purge is on)
|
378
|
-
EOM
|
378
|
+
EOM
|
379
379
|
knife("diff --name-status /data_bags").should_succeed ""
|
380
380
|
end
|
381
381
|
context "when cwd is the /data_bags directory" do
|
@@ -390,7 +390,7 @@ EOM
|
|
390
390
|
Created x/added.json
|
391
391
|
Updated x/modified.json
|
392
392
|
Deleted extra entry x/deleted.json (purge is on)
|
393
|
-
EOM
|
393
|
+
EOM
|
394
394
|
knife("diff --name-status /data_bags").should_succeed ""
|
395
395
|
end
|
396
396
|
it "knife download --purge * downloads everything" do
|
@@ -398,7 +398,7 @@ EOM
|
|
398
398
|
Created x/added.json
|
399
399
|
Updated x/modified.json
|
400
400
|
Deleted extra entry x/deleted.json (purge is on)
|
401
|
-
EOM
|
401
|
+
EOM
|
402
402
|
knife("diff --name-status /data_bags").should_succeed ""
|
403
403
|
end
|
404
404
|
end
|
@@ -421,7 +421,7 @@ EOM
|
|
421
421
|
knife("diff --name-status /cookbooks").should_succeed <<~EOM
|
422
422
|
D\t/cookbooks/x/y.rb
|
423
423
|
A\t/cookbooks/x/z.rb
|
424
|
-
EOM
|
424
|
+
EOM
|
425
425
|
end
|
426
426
|
it "knife download of a deleted file does nothing" do
|
427
427
|
knife("download /cookbooks/x/z.rb").should_succeed ""
|
@@ -429,37 +429,37 @@ EOM
|
|
429
429
|
M\t/cookbooks/x/metadata.rb
|
430
430
|
D\t/cookbooks/x/y.rb
|
431
431
|
A\t/cookbooks/x/z.rb
|
432
|
-
EOM
|
432
|
+
EOM
|
433
433
|
end
|
434
434
|
it "knife download --purge of a deleted file succeeds" do
|
435
435
|
knife("download --purge /cookbooks/x/z.rb").should_succeed "Deleted extra entry /cookbooks/x/z.rb (purge is on)\n"
|
436
436
|
knife("diff --name-status /cookbooks").should_succeed <<~EOM
|
437
437
|
M\t/cookbooks/x/metadata.rb
|
438
438
|
D\t/cookbooks/x/y.rb
|
439
|
-
EOM
|
439
|
+
EOM
|
440
440
|
end
|
441
441
|
it "knife download of an added file succeeds" do
|
442
442
|
knife("download /cookbooks/x/y.rb").should_succeed "Created /cookbooks/x/y.rb\n"
|
443
443
|
knife("diff --name-status /cookbooks").should_succeed <<~EOM
|
444
444
|
M\t/cookbooks/x/metadata.rb
|
445
445
|
A\t/cookbooks/x/z.rb
|
446
|
-
EOM
|
446
|
+
EOM
|
447
447
|
end
|
448
448
|
it "knife download of the cookbook itself succeeds" do
|
449
449
|
knife("download /cookbooks/x").should_succeed <<~EOM
|
450
450
|
Updated /cookbooks/x/metadata.rb
|
451
451
|
Created /cookbooks/x/y.rb
|
452
|
-
EOM
|
452
|
+
EOM
|
453
453
|
knife("diff --name-status /cookbooks").should_succeed <<~EOM
|
454
454
|
A\t/cookbooks/x/z.rb
|
455
|
-
EOM
|
455
|
+
EOM
|
456
456
|
end
|
457
457
|
it "knife download --purge of the cookbook itself succeeds" do
|
458
458
|
knife("download --purge /cookbooks/x").should_succeed <<~EOM
|
459
459
|
Updated /cookbooks/x/metadata.rb
|
460
460
|
Created /cookbooks/x/y.rb
|
461
461
|
Deleted extra entry /cookbooks/x/z.rb (purge is on)
|
462
|
-
EOM
|
462
|
+
EOM
|
463
463
|
knife("diff --name-status /cookbooks").should_succeed ""
|
464
464
|
end
|
465
465
|
end
|
@@ -482,7 +482,7 @@ EOM
|
|
482
482
|
Updated /cookbooks/x/metadata.rb
|
483
483
|
Created /cookbooks/x/onlyin1.0.1.rb
|
484
484
|
Deleted extra entry /cookbooks/x/onlyin1.0.0.rb (purge is on)
|
485
|
-
EOM
|
485
|
+
EOM
|
486
486
|
knife("diff --name-status /cookbooks").should_succeed ""
|
487
487
|
end
|
488
488
|
end
|
@@ -496,7 +496,7 @@ EOM
|
|
496
496
|
it "knife download /cookbooks/x downloads the updated file" do
|
497
497
|
knife("download --purge /cookbooks/x").should_succeed <<~EOM
|
498
498
|
Updated /cookbooks/x/onlyin1.0.0.rb
|
499
|
-
EOM
|
499
|
+
EOM
|
500
500
|
knife("diff --name-status /cookbooks").should_succeed ""
|
501
501
|
end
|
502
502
|
end
|
@@ -511,7 +511,7 @@ EOM
|
|
511
511
|
Updated /cookbooks/x/metadata.rb
|
512
512
|
Created /cookbooks/x/onlyin1.0.1.rb
|
513
513
|
Deleted extra entry /cookbooks/x/onlyin1.0.0.rb (purge is on)
|
514
|
-
EOM
|
514
|
+
EOM
|
515
515
|
knife("diff --name-status /cookbooks").should_succeed ""
|
516
516
|
end
|
517
517
|
end
|
@@ -526,7 +526,7 @@ EOM
|
|
526
526
|
Updated /cookbooks/x/metadata.rb
|
527
527
|
Created /cookbooks/x/onlyin0.9.9.rb
|
528
528
|
Deleted extra entry /cookbooks/x/onlyin1.0.0.rb (purge is on)
|
529
|
-
EOM
|
529
|
+
EOM
|
530
530
|
knife("diff --name-status /cookbooks").should_succeed ""
|
531
531
|
end
|
532
532
|
end
|
@@ -541,7 +541,7 @@ EOM
|
|
541
541
|
file "roles/x.rb", <<~EOM
|
542
542
|
name "x"
|
543
543
|
description "x"
|
544
|
-
EOM
|
544
|
+
EOM
|
545
545
|
end
|
546
546
|
|
547
547
|
it "knife download refuses to change the role" do
|
@@ -561,11 +561,11 @@ EOM
|
|
561
561
|
end
|
562
562
|
it "knife download succeeds" do
|
563
563
|
warning = <<~EOH
|
564
|
-
WARN: Parse error reading #{path_to(
|
564
|
+
WARN: Parse error reading #{path_to("environments/x.json")} as JSON: parse error: premature EOF
|
565
565
|
{
|
566
566
|
(right here) ------^
|
567
567
|
|
568
|
-
EOH
|
568
|
+
EOH
|
569
569
|
knife("download /environments/x.json").should_succeed "Updated /environments/x.json\n", stderr: warning
|
570
570
|
knife("diff --name-status /environments/x.json").should_succeed ""
|
571
571
|
end
|
@@ -631,7 +631,7 @@ EOH
|
|
631
631
|
Created /roles/x.json
|
632
632
|
Created /users/admin.json
|
633
633
|
Created /users/x.json
|
634
|
-
EOM
|
634
|
+
EOM
|
635
635
|
knife("diff --name-status /").should_succeed ""
|
636
636
|
end
|
637
637
|
end
|
@@ -690,7 +690,7 @@ EOM
|
|
690
690
|
|
691
691
|
]
|
692
692
|
}
|
693
|
-
EOM
|
693
|
+
EOM
|
694
694
|
end
|
695
695
|
|
696
696
|
it "knife download / does not change anything" do
|
@@ -726,7 +726,7 @@ EOM
|
|
726
726
|
A\t/nodes/y.json
|
727
727
|
A\t/roles/y.json
|
728
728
|
A\t/users/y.json
|
729
|
-
EOM
|
729
|
+
EOM
|
730
730
|
end
|
731
731
|
|
732
732
|
it "knife download --purge deletes the extra files" do
|
@@ -741,7 +741,7 @@ EOM
|
|
741
741
|
Deleted extra entry /nodes/y.json (purge is on)
|
742
742
|
Deleted extra entry /roles/y.json (purge is on)
|
743
743
|
Deleted extra entry /users/y.json (purge is on)
|
744
|
-
EOM
|
744
|
+
EOM
|
745
745
|
knife("diff --name-status /").should_succeed ""
|
746
746
|
end
|
747
747
|
end
|
@@ -770,7 +770,7 @@ EOM
|
|
770
770
|
Created /users
|
771
771
|
Created /users/admin.json
|
772
772
|
Created /users/x.json
|
773
|
-
EOM
|
773
|
+
EOM
|
774
774
|
knife("diff --name-status /").should_succeed ""
|
775
775
|
end
|
776
776
|
|
@@ -797,10 +797,10 @@ EOM
|
|
797
797
|
Created /data_bags
|
798
798
|
Created /data_bags/x
|
799
799
|
Created /data_bags/x/y.json
|
800
|
-
EOM
|
800
|
+
EOM
|
801
801
|
knife("diff --name-status /data_bags").should_succeed <<~EOM
|
802
802
|
D\t/data_bags/x/z.json
|
803
|
-
EOM
|
803
|
+
EOM
|
804
804
|
end
|
805
805
|
end
|
806
806
|
end
|
@@ -811,17 +811,17 @@ EOM
|
|
811
811
|
{
|
812
812
|
"id": "deleted"
|
813
813
|
}
|
814
|
-
EOM
|
814
|
+
EOM
|
815
815
|
file "data_bags/x/modified.json", <<~EOM
|
816
816
|
{
|
817
817
|
"id": "modified"
|
818
818
|
}
|
819
|
-
EOM
|
819
|
+
EOM
|
820
820
|
file "data_bags/x/unmodified.json", <<~EOM
|
821
821
|
{
|
822
822
|
"id": "unmodified"
|
823
823
|
}
|
824
|
-
EOM
|
824
|
+
EOM
|
825
825
|
end
|
826
826
|
|
827
827
|
when_the_chef_server "has a modified, unmodified, added and deleted data bag item" do
|
@@ -836,11 +836,11 @@ EOM
|
|
836
836
|
it "knife download of the modified file succeeds" do
|
837
837
|
knife("download /data_bags/x/modified.json").should_succeed <<~EOM
|
838
838
|
Updated /data_bags/x/modified.json
|
839
|
-
EOM
|
839
|
+
EOM
|
840
840
|
knife("diff --name-status /data_bags").should_succeed <<~EOM
|
841
841
|
D\t/data_bags/x/added.json
|
842
842
|
A\t/data_bags/x/deleted.json
|
843
|
-
EOM
|
843
|
+
EOM
|
844
844
|
end
|
845
845
|
it "knife download of the unmodified file does nothing" do
|
846
846
|
knife("download /data_bags/x/unmodified.json").should_succeed ""
|
@@ -848,16 +848,16 @@ EOM
|
|
848
848
|
D\t/data_bags/x/added.json
|
849
849
|
M\t/data_bags/x/modified.json
|
850
850
|
A\t/data_bags/x/deleted.json
|
851
|
-
EOM
|
851
|
+
EOM
|
852
852
|
end
|
853
853
|
it "knife download of the added file succeeds" do
|
854
854
|
knife("download /data_bags/x/added.json").should_succeed <<~EOM
|
855
855
|
Created /data_bags/x/added.json
|
856
|
-
EOM
|
856
|
+
EOM
|
857
857
|
knife("diff --name-status /data_bags").should_succeed <<~EOM
|
858
858
|
M\t/data_bags/x/modified.json
|
859
859
|
A\t/data_bags/x/deleted.json
|
860
|
-
EOM
|
860
|
+
EOM
|
861
861
|
end
|
862
862
|
it "knife download of the deleted file does nothing" do
|
863
863
|
knife("download /data_bags/x/deleted.json").should_succeed ""
|
@@ -865,32 +865,32 @@ EOM
|
|
865
865
|
D\t/data_bags/x/added.json
|
866
866
|
M\t/data_bags/x/modified.json
|
867
867
|
A\t/data_bags/x/deleted.json
|
868
|
-
EOM
|
868
|
+
EOM
|
869
869
|
end
|
870
870
|
it "knife download --purge of the deleted file deletes it" do
|
871
871
|
knife("download --purge /data_bags/x/deleted.json").should_succeed <<~EOM
|
872
872
|
Deleted extra entry /data_bags/x/deleted.json (purge is on)
|
873
|
-
EOM
|
873
|
+
EOM
|
874
874
|
knife("diff --name-status /data_bags").should_succeed <<~EOM
|
875
875
|
D\t/data_bags/x/added.json
|
876
876
|
M\t/data_bags/x/modified.json
|
877
|
-
EOM
|
877
|
+
EOM
|
878
878
|
end
|
879
879
|
it "knife download of the entire data bag downloads everything" do
|
880
880
|
knife("download /data_bags/x").should_succeed <<~EOM
|
881
881
|
Created /data_bags/x/added.json
|
882
882
|
Updated /data_bags/x/modified.json
|
883
|
-
EOM
|
883
|
+
EOM
|
884
884
|
knife("diff --name-status /data_bags").should_succeed <<~EOM
|
885
885
|
A\t/data_bags/x/deleted.json
|
886
|
-
EOM
|
886
|
+
EOM
|
887
887
|
end
|
888
888
|
it "knife download --purge of the entire data bag downloads everything" do
|
889
889
|
knife("download --purge /data_bags/x").should_succeed <<~EOM
|
890
890
|
Created /data_bags/x/added.json
|
891
891
|
Updated /data_bags/x/modified.json
|
892
892
|
Deleted extra entry /data_bags/x/deleted.json (purge is on)
|
893
|
-
EOM
|
893
|
+
EOM
|
894
894
|
knife("diff --name-status /data_bags").should_succeed ""
|
895
895
|
end
|
896
896
|
context "when cwd is the /data_bags directory" do
|
@@ -905,7 +905,7 @@ EOM
|
|
905
905
|
Created x/added.json
|
906
906
|
Updated x/modified.json
|
907
907
|
Deleted extra entry x/deleted.json (purge is on)
|
908
|
-
EOM
|
908
|
+
EOM
|
909
909
|
knife("diff --name-status /data_bags").should_succeed ""
|
910
910
|
end
|
911
911
|
it "knife download --purge * downloads everything" do
|
@@ -913,7 +913,7 @@ EOM
|
|
913
913
|
Created x/added.json
|
914
914
|
Updated x/modified.json
|
915
915
|
Deleted extra entry x/deleted.json (purge is on)
|
916
|
-
EOM
|
916
|
+
EOM
|
917
917
|
knife("diff --name-status /data_bags").should_succeed ""
|
918
918
|
end
|
919
919
|
end
|
@@ -936,7 +936,7 @@ EOM
|
|
936
936
|
knife("diff --name-status /cookbooks").should_succeed <<~EOM
|
937
937
|
D\t/cookbooks/x-1.0.0/y.rb
|
938
938
|
A\t/cookbooks/x-1.0.0/z.rb
|
939
|
-
EOM
|
939
|
+
EOM
|
940
940
|
end
|
941
941
|
it "knife download of a deleted file does nothing" do
|
942
942
|
knife("download /cookbooks/x-1.0.0/z.rb").should_succeed ""
|
@@ -944,37 +944,37 @@ EOM
|
|
944
944
|
M\t/cookbooks/x-1.0.0/metadata.rb
|
945
945
|
D\t/cookbooks/x-1.0.0/y.rb
|
946
946
|
A\t/cookbooks/x-1.0.0/z.rb
|
947
|
-
EOM
|
947
|
+
EOM
|
948
948
|
end
|
949
949
|
it "knife download --purge of a deleted file succeeds" do
|
950
950
|
knife("download --purge /cookbooks/x-1.0.0/z.rb").should_succeed "Deleted extra entry /cookbooks/x-1.0.0/z.rb (purge is on)\n"
|
951
951
|
knife("diff --name-status /cookbooks").should_succeed <<~EOM
|
952
952
|
M\t/cookbooks/x-1.0.0/metadata.rb
|
953
953
|
D\t/cookbooks/x-1.0.0/y.rb
|
954
|
-
EOM
|
954
|
+
EOM
|
955
955
|
end
|
956
956
|
it "knife download of an added file succeeds" do
|
957
957
|
knife("download /cookbooks/x-1.0.0/y.rb").should_succeed "Created /cookbooks/x-1.0.0/y.rb\n"
|
958
958
|
knife("diff --name-status /cookbooks").should_succeed <<~EOM
|
959
959
|
M\t/cookbooks/x-1.0.0/metadata.rb
|
960
960
|
A\t/cookbooks/x-1.0.0/z.rb
|
961
|
-
EOM
|
961
|
+
EOM
|
962
962
|
end
|
963
963
|
it "knife download of the cookbook itself succeeds" do
|
964
964
|
knife("download /cookbooks/x-1.0.0").should_succeed <<~EOM
|
965
965
|
Updated /cookbooks/x-1.0.0/metadata.rb
|
966
966
|
Created /cookbooks/x-1.0.0/y.rb
|
967
|
-
EOM
|
967
|
+
EOM
|
968
968
|
knife("diff --name-status /cookbooks").should_succeed <<~EOM
|
969
969
|
A\t/cookbooks/x-1.0.0/z.rb
|
970
|
-
EOM
|
970
|
+
EOM
|
971
971
|
end
|
972
972
|
it "knife download --purge of the cookbook itself succeeds" do
|
973
973
|
knife("download --purge /cookbooks/x-1.0.0").should_succeed <<~EOM
|
974
974
|
Updated /cookbooks/x-1.0.0/metadata.rb
|
975
975
|
Created /cookbooks/x-1.0.0/y.rb
|
976
976
|
Deleted extra entry /cookbooks/x-1.0.0/z.rb (purge is on)
|
977
|
-
EOM
|
977
|
+
EOM
|
978
978
|
knife("diff --name-status /cookbooks").should_succeed ""
|
979
979
|
end
|
980
980
|
end
|
@@ -998,7 +998,7 @@ EOM
|
|
998
998
|
Created /cookbooks/x-1.0.1
|
999
999
|
Created /cookbooks/x-1.0.1/metadata.rb
|
1000
1000
|
Created /cookbooks/x-1.0.1/onlyin1.0.1.rb
|
1001
|
-
EOM
|
1001
|
+
EOM
|
1002
1002
|
knife("diff --name-status /cookbooks").should_succeed ""
|
1003
1003
|
end
|
1004
1004
|
end
|
@@ -1015,7 +1015,7 @@ EOM
|
|
1015
1015
|
Created /cookbooks/x-0.9.9/metadata.rb
|
1016
1016
|
Created /cookbooks/x-0.9.9/onlyin0.9.9.rb
|
1017
1017
|
Updated /cookbooks/x-1.0.0/onlyin1.0.0.rb
|
1018
|
-
EOM
|
1018
|
+
EOM
|
1019
1019
|
knife("diff --name-status /cookbooks").should_succeed ""
|
1020
1020
|
end
|
1021
1021
|
end
|
@@ -1031,7 +1031,7 @@ EOM
|
|
1031
1031
|
Created /cookbooks/x-1.0.1/metadata.rb
|
1032
1032
|
Created /cookbooks/x-1.0.1/onlyin1.0.1.rb
|
1033
1033
|
Deleted extra entry /cookbooks/x-1.0.0 (purge is on)
|
1034
|
-
EOM
|
1034
|
+
EOM
|
1035
1035
|
knife("diff --name-status /cookbooks").should_succeed ""
|
1036
1036
|
end
|
1037
1037
|
end
|
@@ -1047,7 +1047,7 @@ EOM
|
|
1047
1047
|
Created /cookbooks/x-0.9.9/metadata.rb
|
1048
1048
|
Created /cookbooks/x-0.9.9/onlyin0.9.9.rb
|
1049
1049
|
Deleted extra entry /cookbooks/x-1.0.0 (purge is on)
|
1050
|
-
EOM
|
1050
|
+
EOM
|
1051
1051
|
knife("diff --name-status /cookbooks").should_succeed ""
|
1052
1052
|
end
|
1053
1053
|
end
|
@@ -1106,7 +1106,7 @@ EOM
|
|
1106
1106
|
Created /cookbooks
|
1107
1107
|
Created /cookbooks/x
|
1108
1108
|
Created /cookbooks/x/metadata.rb
|
1109
|
-
EOM
|
1109
|
+
EOM
|
1110
1110
|
end
|
1111
1111
|
end
|
1112
1112
|
end
|
@@ -1189,7 +1189,7 @@ EOM
|
|
1189
1189
|
Created /policies
|
1190
1190
|
Created /policy_groups
|
1191
1191
|
Created /roles
|
1192
|
-
EOM
|
1192
|
+
EOM
|
1193
1193
|
end
|
1194
1194
|
|
1195
1195
|
context "and the server has one of each thing" do
|
@@ -1232,7 +1232,7 @@ EOM
|
|
1232
1232
|
Created /acls/roles/x.json
|
1233
1233
|
Updated /groups/clients.json
|
1234
1234
|
Updated /groups/users.json
|
1235
|
-
EOM
|
1235
|
+
EOM
|
1236
1236
|
end
|
1237
1237
|
|
1238
1238
|
it "knife download / downloads everything" do
|
@@ -1254,7 +1254,7 @@ EOM
|
|
1254
1254
|
Created /policies/x-1.0.0.json
|
1255
1255
|
Created /policy_groups/x.json
|
1256
1256
|
Created /roles/x.json
|
1257
|
-
EOM
|
1257
|
+
EOM
|
1258
1258
|
knife("diff --name-status /").should_succeed ""
|
1259
1259
|
end
|
1260
1260
|
|
@@ -1323,7 +1323,7 @@ EOM
|
|
1323
1323
|
Updated /policies/x-1.0.0.json
|
1324
1324
|
Updated /policy_groups/x.json
|
1325
1325
|
Updated /roles/x.json
|
1326
|
-
EOM
|
1326
|
+
EOM
|
1327
1327
|
knife("diff --name-status /").should_succeed ""
|
1328
1328
|
end
|
1329
1329
|
end
|