spec/unit/policyfile/uploader_spec.rb in chef-dk-4.1.7 vs spec/unit/policyfile/uploader_spec.rb in chef-dk-4.2.0
- old
+ new
@@ -46,23 +46,24 @@
}
end
let(:policyfile_lock) do
instance_double("ChefDK::PolicyfileLock", name: "example",
- to_lock: policyfile_lock_data) end
+ to_lock: policyfile_lock_data)
+ end
let(:policy_group) { "unit-test" }
let(:http_client) { instance_double("Chef::ServerAPI") }
let(:policy_document_native_api) { false }
let(:uploader) do
described_class.new(policyfile_lock,
- policy_group,
- http_client: http_client,
- policy_document_native_api: policy_document_native_api)
+ policy_group,
+ http_client: http_client,
+ policy_document_native_api: policy_document_native_api)
end
let(:policyfile_as_data_bag_item) do
policyfile_as_data_bag_item = {
@@ -99,19 +100,19 @@
def lock_double(name, identifier, dotted_decimal_id)
cache_path = "/home/user/cache_path/#{name}"
lock = instance_double("ChefDK::Policyfile::CookbookLock",
- name: name,
- version: "1.0.0",
- identifier: identifier,
- dotted_decimal_identifier: dotted_decimal_id,
- cookbook_path: cache_path)
+ name: name,
+ version: "1.0.0",
+ identifier: identifier,
+ dotted_decimal_identifier: dotted_decimal_id,
+ cookbook_path: cache_path)
cookbook_version = instance_double("Chef::CookbookVersion",
- name: name,
- identifier: lock.identifier,
- version: dotted_decimal_id)
+ name: name,
+ identifier: lock.identifier,
+ version: dotted_decimal_id)
allow(cookbook_version).to receive(:identifier=).with(lock.identifier)
allow(ChefDK::Policyfile::ReadCookbookForCompatModeUpload)
.to receive(:load)