summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJose Asuncion <jeunito@gmail.com>2017-07-06 07:27:47 -0700
committerJose Asuncion <jeunito@gmail.com>2017-07-06 07:27:47 -0700
commit606304ec18bd518c2eff9b9b4257aff55df50f2d (patch)
tree15cb1d9c334524bda733f0086f131435f99c3872
parent764524d41d6aac0fcb62c8030ecaa217eda8c746 (diff)
downloadchef-606304ec18bd518c2eff9b9b4257aff55df50f2d.tar.gz
update to conform to chefstyle
-rw-r--r--lib/chef/server_api.rb2
-rw-r--r--spec/unit/server_api_spec.rb2
2 files changed, 2 insertions, 2 deletions
diff --git a/lib/chef/server_api.rb b/lib/chef/server_api.rb
index 3a98b7aa3a..d4644e8fc7 100644
--- a/lib/chef/server_api.rb
+++ b/lib/chef/server_api.rb
@@ -38,7 +38,7 @@ class Chef
super(url, options)
chef_server_attrs = get("/").keys.sort
- raise Chef::Exceptions::NotAChefServerException if [ "guid", "full_name", "name" ].sort != chef_server_attrs
+ raise Chef::Exceptions::NotAChefServerException if %w[ guid full_name name ].sort != chef_server_attrs
end
use Chef::HTTP::JSONInput
diff --git a/spec/unit/server_api_spec.rb b/spec/unit/server_api_spec.rb
index 79ca564793..7326ec3894 100644
--- a/spec/unit/server_api_spec.rb
+++ b/spec/unit/server_api_spec.rb
@@ -55,7 +55,7 @@ describe Chef::ServerAPI do
context "when url is not a chef server" do
let(:org_data) { Hash.new }
it "throws exception" do
- expect{ described_class.new(url, raw_key: SIGNING_KEY_DOT_PEM) }.to raise_exception(Chef::Exceptions::NotAChefServerException)
+ expect { described_class.new(url, raw_key: SIGNING_KEY_DOT_PEM) }.to raise_exception(Chef::Exceptions::NotAChefServerException)
end
end
end