diff options
author | Tim Smith <tsmith@chef.io> | 2017-04-28 12:27:59 -0700 |
---|---|---|
committer | Tim Smith <tsmith@chef.io> | 2017-05-12 09:29:33 -0700 |
commit | 1556de1044ae31f5a5ebba77972048314966214b (patch) | |
tree | 3e304917a36125659580ae86703dfc445b55d9d4 | |
parent | 94413e636c12f68f283f0284312a059fb943da31 (diff) | |
download | chef-1556de1044ae31f5a5ebba77972048314966214b.tar.gz |
Chefstyle fixes
Signed-off-by: Tim Smith <tsmith@chef.io>
-rw-r--r-- | lib/chef/resource/apt_preference.rb | 2 | ||||
-rw-r--r-- | spec/unit/provider/apt_preference_spec.rb | 4 |
2 files changed, 3 insertions, 3 deletions
diff --git a/lib/chef/resource/apt_preference.rb b/lib/chef/resource/apt_preference.rb index 78b55d0dba..6fb313726a 100644 --- a/lib/chef/resource/apt_preference.rb +++ b/lib/chef/resource/apt_preference.rb @@ -27,7 +27,7 @@ class Chef property :package_name, String, name_property: true, regex: [/^([a-z]|[A-Z]|[0-9]|_|-|\.|\*|\+)+$/] property :glob, String property :pin, String, required: true - property :pin_priority, [String,Integer], required: true + property :pin_priority, [String, Integer], required: true default_action :add allowed_actions :add, :remove diff --git a/spec/unit/provider/apt_preference_spec.rb b/spec/unit/provider/apt_preference_spec.rb index 4711d11f70..d0dbe8de25 100644 --- a/spec/unit/provider/apt_preference_spec.rb +++ b/spec/unit/provider/apt_preference_spec.rb @@ -25,7 +25,7 @@ describe Chef::Provider::AptPreference do before do stub_const("Chef::Provider::AptPreference::APT_PREFERENCE_DIR", pref_dir) - new_resource.pin = '1.0.1' + new_resource.pin = "1.0.1" new_resource.pin_priority 1001 end @@ -56,7 +56,7 @@ describe Chef::Provider::AptPreference do it "creates a sanitized .pref file" do provider.run_action(:add) expect(new_resource).to be_updated_by_last_action - expect(File.read(::File.join(pref_dir,'libmysqlclient16_1wildcard.pref'))).to match(/Package: libmysqlclient16.1*.*Pin: 1.0.1.*Pin-Priority: 1001/m) + expect(File.read(::File.join(pref_dir, "libmysqlclient16_1wildcard.pref"))).to match(/Package: libmysqlclient16.1*.*Pin: 1.0.1.*Pin-Priority: 1001/m) end end |