summaryrefslogtreecommitdiff
path: root/spec/support/shared/functional
diff options
context:
space:
mode:
Diffstat (limited to 'spec/support/shared/functional')
-rw-r--r--spec/support/shared/functional/directory_resource.rb4
-rw-r--r--spec/support/shared/functional/http.rb8
-rw-r--r--spec/support/shared/functional/securable_resource.rb12
-rw-r--r--spec/support/shared/functional/win32_service.rb2
4 files changed, 13 insertions, 13 deletions
diff --git a/spec/support/shared/functional/directory_resource.rb b/spec/support/shared/functional/directory_resource.rb
index 39bdc313e5..51c7550a78 100644
--- a/spec/support/shared/functional/directory_resource.rb
+++ b/spec/support/shared/functional/directory_resource.rb
@@ -68,14 +68,14 @@ shared_examples_for "a directory resource" do
def allowed_acl(sid, expected_perms)
[
ACE.access_allowed(sid, expected_perms[:specific]),
- ACE.access_allowed(sid, expected_perms[:generic], (Chef::ReservedNames::Win32::API::Security::INHERIT_ONLY_ACE | Chef::ReservedNames::Win32::API::Security::CONTAINER_INHERIT_ACE | Chef::ReservedNames::Win32::API::Security::OBJECT_INHERIT_ACE))
+ ACE.access_allowed(sid, expected_perms[:generic], (Chef::ReservedNames::Win32::API::Security::INHERIT_ONLY_ACE | Chef::ReservedNames::Win32::API::Security::CONTAINER_INHERIT_ACE | Chef::ReservedNames::Win32::API::Security::OBJECT_INHERIT_ACE)),
]
end
def denied_acl(sid, expected_perms)
[
ACE.access_denied(sid, expected_perms[:specific]),
- ACE.access_denied(sid, expected_perms[:generic], (Chef::ReservedNames::Win32::API::Security::INHERIT_ONLY_ACE | Chef::ReservedNames::Win32::API::Security::CONTAINER_INHERIT_ACE | Chef::ReservedNames::Win32::API::Security::OBJECT_INHERIT_ACE))
+ ACE.access_denied(sid, expected_perms[:generic], (Chef::ReservedNames::Win32::API::Security::INHERIT_ONLY_ACE | Chef::ReservedNames::Win32::API::Security::CONTAINER_INHERIT_ACE | Chef::ReservedNames::Win32::API::Security::OBJECT_INHERIT_ACE)),
]
end
diff --git a/spec/support/shared/functional/http.rb b/spec/support/shared/functional/http.rb
index 963fbf1c5b..cfbb8e3689 100644
--- a/spec/support/shared/functional/http.rb
+++ b/spec/support/shared/functional/http.rb
@@ -81,7 +81,7 @@ module ChefHTTPShared
# (expected_content should be uncompressed)
@api.get("/nyan_cat_content_length.png", 200, nil,
{
- 'Content-Length' => nyan_uncompressed_size.to_s,
+ 'Content-Length' => nyan_uncompressed_size.to_s
}
) {
File.open(nyan_uncompressed_filename, "rb") do |f|
@@ -94,7 +94,7 @@ module ChefHTTPShared
{
'Content-Length' => nyan_compressed_size.to_s,
'Content-Type' => 'application/gzip',
- 'Content-Encoding' => 'gzip'
+ 'Content-Encoding' => 'gzip',
}
) {
File.open(nyan_compressed_filename, "rb") do |f|
@@ -109,7 +109,7 @@ module ChefHTTPShared
# (expected_content should be uncompressed)
@api.get("/nyan_cat_truncated.png", 200, nil,
{
- 'Content-Length' => (nyan_uncompressed_size + 1).to_s,
+ 'Content-Length' => (nyan_uncompressed_size + 1).to_s
}
) {
File.open(nyan_uncompressed_filename, "rb") do |f|
@@ -122,7 +122,7 @@ module ChefHTTPShared
{
'Content-Length' => (nyan_compressed_size + 1).to_s,
'Content-Type' => 'application/gzip',
- 'Content-Encoding' => 'gzip'
+ 'Content-Encoding' => 'gzip',
}
) {
File.open(nyan_compressed_filename, "rb") do |f|
diff --git a/spec/support/shared/functional/securable_resource.rb b/spec/support/shared/functional/securable_resource.rb
index b3c32356aa..1e8edec9ae 100644
--- a/spec/support/shared/functional/securable_resource.rb
+++ b/spec/support/shared/functional/securable_resource.rb
@@ -111,28 +111,28 @@ shared_context "use Windows permissions", :windows_only do
let(:expected_read_execute_perms) do
{
:generic => Chef::ReservedNames::Win32::API::Security::GENERIC_READ | Chef::ReservedNames::Win32::API::Security::GENERIC_EXECUTE,
- :specific => Chef::ReservedNames::Win32::API::Security::FILE_GENERIC_READ | Chef::ReservedNames::Win32::API::Security::FILE_GENERIC_EXECUTE
+ :specific => Chef::ReservedNames::Win32::API::Security::FILE_GENERIC_READ | Chef::ReservedNames::Win32::API::Security::FILE_GENERIC_EXECUTE,
}
end
let(:expected_write_perms) do
{
:generic => Chef::ReservedNames::Win32::API::Security::GENERIC_WRITE,
- :specific => Chef::ReservedNames::Win32::API::Security::FILE_GENERIC_WRITE
+ :specific => Chef::ReservedNames::Win32::API::Security::FILE_GENERIC_WRITE,
}
end
let(:expected_modify_perms) do
{
:generic => Chef::ReservedNames::Win32::API::Security::GENERIC_READ | Chef::ReservedNames::Win32::API::Security::GENERIC_WRITE | Chef::ReservedNames::Win32::API::Security::GENERIC_EXECUTE | Chef::ReservedNames::Win32::API::Security::DELETE,
- :specific => Chef::ReservedNames::Win32::API::Security::FILE_GENERIC_READ | Chef::ReservedNames::Win32::API::Security::FILE_GENERIC_WRITE | Chef::ReservedNames::Win32::API::Security::FILE_GENERIC_EXECUTE | Chef::ReservedNames::Win32::API::Security::DELETE
+ :specific => Chef::ReservedNames::Win32::API::Security::FILE_GENERIC_READ | Chef::ReservedNames::Win32::API::Security::FILE_GENERIC_WRITE | Chef::ReservedNames::Win32::API::Security::FILE_GENERIC_EXECUTE | Chef::ReservedNames::Win32::API::Security::DELETE,
}
end
let(:expected_full_control_perms) do
{
:generic => Chef::ReservedNames::Win32::API::Security::GENERIC_ALL,
- :specific => Chef::ReservedNames::Win32::API::Security::FILE_ALL_ACCESS
+ :specific => Chef::ReservedNames::Win32::API::Security::FILE_ALL_ACCESS,
}
end
@@ -470,7 +470,7 @@ shared_examples_for "a securable resource without existing target" do
expect(explicit_aces).to eq([
ACE.access_allowed(SID.Guest, Security::FILE_GENERIC_READ | Security::FILE_GENERIC_WRITE | Security::FILE_GENERIC_EXECUTE | Security::DELETE),
ACE.access_allowed(SID.Administrators, Security::FILE_GENERIC_READ | Security::FILE_GENERIC_EXECUTE),
- ACE.access_allowed(SID.Everyone, Security::FILE_GENERIC_READ)
+ ACE.access_allowed(SID.Everyone, Security::FILE_GENERIC_READ),
])
end
@@ -483,7 +483,7 @@ shared_examples_for "a securable resource without existing target" do
expect(explicit_aces).to eq([
ACE.access_allowed(SID.Guest, Security::FILE_GENERIC_READ),
ACE.access_allowed(SID.Administrators, Security::FILE_GENERIC_WRITE | Security::DELETE),
- ACE.access_allowed(SID.Everyone, Security::FILE_GENERIC_EXECUTE)
+ ACE.access_allowed(SID.Everyone, Security::FILE_GENERIC_EXECUTE),
])
end
diff --git a/spec/support/shared/functional/win32_service.rb b/spec/support/shared/functional/win32_service.rb
index 2ee1a8ad88..8eca7a47fa 100644
--- a/spec/support/shared/functional/win32_service.rb
+++ b/spec/support/shared/functional/win32_service.rb
@@ -47,7 +47,7 @@ shared_context "using Win32::Service" do
:service_display_name => "Spec Test Service",
:service_description => "Service for testing Chef::Application::WindowsServiceManager.",
:service_file_path => File.expand_path(File.join(File.dirname(__FILE__), '../../platforms/win32/spec_service.rb')),
- :delayed_start => true
+ :delayed_start => true,
}
}