summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLamont Granquist <lamont@scriptkiddie.org>2016-08-09 14:00:14 -0700
committerLamont Granquist <lamont@scriptkiddie.org>2016-08-16 18:41:25 -0700
commit854827b839510fd7921829452756c9aa81c45c84 (patch)
treea068622d63b0570f62e1885e7bac2f04e3ab8eae
parent86b7ae916e37a17e9f764bcc6699b7cd38e6d732 (diff)
downloadchef-854827b839510fd7921829452756c9aa81c45c84.tar.gz
fixing Style/ConstantName cop
-rw-r--r--lib/chef/cookbook_site_streaming_uploader.rb2
-rw-r--r--lib/chef/win32/api/error.rb4
-rw-r--r--lib/chef/win32/api/net.rb2
-rw-r--r--lib/chef/win32/eventlog.rb2
-rw-r--r--spec/support/shared/functional/securable_resource.rb8
5 files changed, 9 insertions, 9 deletions
diff --git a/lib/chef/cookbook_site_streaming_uploader.rb b/lib/chef/cookbook_site_streaming_uploader.rb
index 760a48ab3a..c0e85ff984 100644
--- a/lib/chef/cookbook_site_streaming_uploader.rb
+++ b/lib/chef/cookbook_site_streaming_uploader.rb
@@ -31,7 +31,7 @@ class Chef
# inspired by http://stanislavvitvitskiy.blogspot.com/2008/12/multipart-post-in-ruby.html
class CookbookSiteStreamingUploader
- DefaultHeaders = { "accept" => "application/json", "x-chef-version" => ::Chef::VERSION }
+ DefaultHeaders = { "accept" => "application/json", "x-chef-version" => ::Chef::VERSION } # rubocop:disable Style/ConstantName
class << self
diff --git a/lib/chef/win32/api/error.rb b/lib/chef/win32/api/error.rb
index dc83f9cb2b..12ccdb5ee9 100644
--- a/lib/chef/win32/api/error.rb
+++ b/lib/chef/win32/api/error.rb
@@ -194,12 +194,12 @@ class Chef
ERROR_INVALID_EXE_SIGNATURE = 191
ERROR_EXE_MARKED_INVALID = 192
ERROR_BAD_EXE_FORMAT = 193
- ERROR_ITERATED_DATA_EXCEEDS_64k = 194
+ ERROR_ITERATED_DATA_EXCEEDS_64k = 194 # rubocop:disable Style/ConstantName
ERROR_INVALID_MINALLOCSIZE = 195
ERROR_DYNLINK_FROM_INVALID_RING = 196
ERROR_IOPL_NOT_ENABLED = 197
ERROR_INVALID_SEGDPL = 198
- ERROR_AUTODATASEG_EXCEEDS_64k = 199
+ ERROR_AUTODATASEG_EXCEEDS_64k = 199 # rubocop:disable Style/ConstantName
ERROR_RING2SEG_MUST_BE_MOVABLE = 200
ERROR_RELOC_CHAIN_XEEDS_SEGLIM = 201
ERROR_INFLOOP_IN_RELOC_CHAIN = 202
diff --git a/lib/chef/win32/api/net.rb b/lib/chef/win32/api/net.rb
index bec00f638a..abf0dd83ec 100644
--- a/lib/chef/win32/api/net.rb
+++ b/lib/chef/win32/api/net.rb
@@ -45,7 +45,7 @@ class Chef
USE_FORCE = 1
USE_LOTS_OF_FORCE = 2 #every windows API should support this flag
- NERR_Success = 0
+ NERR_Success = 0 # rubocop:disable Style/ConstantName
ERROR_MORE_DATA = 234
ffi_lib "netapi32"
diff --git a/lib/chef/win32/eventlog.rb b/lib/chef/win32/eventlog.rb
index 4254b8ead3..eae0ae4abf 100644
--- a/lib/chef/win32/eventlog.rb
+++ b/lib/chef/win32/eventlog.rb
@@ -26,6 +26,6 @@ if Chef::Platform.windows? && (not Chef::Platform.windows_server_2003?)
end
require "win32/eventlog"
- Chef::Win32EventLogLoaded = true
+ Chef::Win32EventLogLoaded = true # rubocop:disable Style/ConstantName
end
end
diff --git a/spec/support/shared/functional/securable_resource.rb b/spec/support/shared/functional/securable_resource.rb
index 17b78dda9d..95f4f4bd49 100644
--- a/spec/support/shared/functional/securable_resource.rb
+++ b/spec/support/shared/functional/securable_resource.rb
@@ -81,7 +81,7 @@ shared_context "use Windows permissions", :windows_only do
SID ||= Chef::ReservedNames::Win32::Security::SID
ACE ||= Chef::ReservedNames::Win32::Security::ACE
ACL ||= Chef::ReservedNames::Win32::Security::ACL
- SecurableObject ||= Chef::ReservedNames::Win32::Security::SecurableObject
+ SecurableObject ||= Chef::ReservedNames::Win32::Security::SecurableObject # rubocop:disable Style/ConstantName
end
def get_security_descriptor(path)
@@ -139,8 +139,8 @@ shared_context "use Windows permissions", :windows_only do
RSpec::Matchers.define :have_expected_properties do |mask, type, flags|
match do |ace|
ace.mask == mask &&
- ace.type == type &&
- ace.flags == flags
+ ace.type == type &&
+ ace.flags == flags
end
end
@@ -439,7 +439,7 @@ shared_examples_for "a securable resource without existing target" do
context "with a mode attribute" do
if windows?
- Security ||= Chef::ReservedNames::Win32::API::Security
+ Security ||= Chef::ReservedNames::Win32::API::Security # rubocop:disable Style/ConstantName
end
it "respects mode in string form as an octal number" do