Class: Specinfra::Command::Windows::Base::File
- Inherits:
-
Specinfra::Command::Windows::Base
- Object
- Specinfra::Command::Windows::Base
- Specinfra::Command::Windows::Base::File
- Defined in:
- vendor_modules/concat/spec/acceptance/specinfra_stubs.rb
Overview
class Specinfra::Command::Windows::Base::File
Class Method Summary collapse
Class Method Details
.check_is_owned_by(file, owner) ⇒ Object
6 7 8 9 10 11 |
# File 'vendor_modules/concat/spec/acceptance/specinfra_stubs.rb', line 6 def check_is_owned_by(file, owner) Backend::PowerShell::Command.new do exec "if((Get-Item '#{file}').GetAccessControl().Owner -match '#{owner}' -or ((Get-Item '#{file}').GetAccessControl().Owner -match '#{owner}').Length -gt 0){ exit 0 } else { exit 1 }" end end |