summaryrefslogtreecommitdiff
path: root/spec/unit/resource_collection/resource_set_spec.rb
diff options
context:
space:
mode:
authorLamont Granquist <lamont@scriptkiddie.org>2016-02-05 15:07:44 -0800
committerLamont Granquist <lamont@scriptkiddie.org>2016-02-05 15:07:44 -0800
commitcb4ee84e418164e8d2e85147efad711a42ff2799 (patch)
treef225de7251a8b49b8d183dd168bab0a0addbe23f /spec/unit/resource_collection/resource_set_spec.rb
parentd1cf34b059a16a81e0fc48de52ba29863bb41fe6 (diff)
parent686113531d23f30e9973d659c456ae33eb9cff1f (diff)
downloadchef-cb4ee84e418164e8d2e85147efad711a42ff2799.tar.gz
Merge pull request #4526 from chef/lcg/whitespace-style
whitespace fixes
Diffstat (limited to 'spec/unit/resource_collection/resource_set_spec.rb')
-rw-r--r--spec/unit/resource_collection/resource_set_spec.rb12
1 files changed, 6 insertions, 6 deletions
diff --git a/spec/unit/resource_collection/resource_set_spec.rb b/spec/unit/resource_collection/resource_set_spec.rb
index cacd555b4b..2f8ba0e1aa 100644
--- a/spec/unit/resource_collection/resource_set_spec.rb
+++ b/spec/unit/resource_collection/resource_set_spec.rb
@@ -78,13 +78,13 @@ describe Chef::ResourceCollection::ResourceSet do
it "should find a resource by type symbol and array of names" do
collection.insert_as(zen_master)
collection.insert_as(zen_master2)
- check_by_names(collection.find(:zen_master => [zen_master_name,zen_master2_name]), zen_master_name, zen_master2_name)
+ check_by_names(collection.find(:zen_master => [zen_master_name, zen_master2_name]), zen_master_name, zen_master2_name)
end
it "should find a resource by type symbol and array of names with custom names" do
collection.insert_as(zen_master, :zzz, "name1")
collection.insert_as(zen_master2, :zzz, "name2")
- check_by_names(collection.find( :zzz => ["name1","name2"]), zen_master_name, zen_master2_name)
+ check_by_names(collection.find( :zzz => ["name1", "name2"]), zen_master_name, zen_master2_name)
end
it "should find resources of multiple kinds (:zen_master => a, :zen_follower => b)" do
@@ -98,7 +98,7 @@ describe Chef::ResourceCollection::ResourceSet do
collection.insert_as(zen_master, :zzz, "name1")
collection.insert_as(zen_master2, :zzz, "name2")
collection.insert_as(zen_follower, :yyy, "name3")
- check_by_names(collection.find(:zzz => ["name1","name2"], :yyy => ["name3"]),
+ check_by_names(collection.find(:zzz => ["name1", "name2"], :yyy => ["name3"]),
zen_master_name, zen_follower_name, zen_master2_name)
end
@@ -138,13 +138,13 @@ describe Chef::ResourceCollection::ResourceSet do
collection.insert_as(zen_master2, :zzz, "name2")
collection.insert_as(zen_follower, :yyy, "name3")
check_by_names(collection.find("zzz[name1,name2]", "yyy[name3]"),
- zen_master_name, zen_follower_name,zen_master2_name)
+ zen_master_name, zen_follower_name, zen_master2_name)
end
it "should only keep the last copy when multiple instances of a Resource are inserted" do
collection.insert_as(zen_master)
expect(collection.find("zen_master[#{zen_master_name}]")).to eq(zen_master)
- new_zm =zen_master.dup
+ new_zm = zen_master.dup
new_zm.retries = 10
expect(new_zm).to_not eq(zen_master)
collection.insert_as(new_zm)
@@ -192,7 +192,7 @@ describe Chef::ResourceCollection::ResourceSet do
def check_by_names(results, *names)
expect(results.size).to eq(names.size)
names.each do |name|
- expect(results.detect{|r| r.name == name}).to_not eq(nil)
+ expect(results.detect { |r| r.name == name }).to_not eq(nil)
end
end