You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The registry_key test is not finding the key in Windows Server 2008 R2. It is returning nil when searching for any key.
InSpec and Platform Version
Running using Git Bash on Windows 7. Tests running on Windows Server 2008 R2 local VM.
$ chef gem list inspec
*** LOCAL GEMS ***
debug_inspector (0.0.2)
inspec (0.22.1)
kitchen-inspec (0.13.0, 0.12.3)
Replication Case
Example:
control 'autoplay_disabled' do
impact 0.3
title 'Autoplay/Autorun Disabled'
desc 'Ensures autorun and autoplay are disabled.'
describe registry_key('HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\policies\Explorer') do
its('NoDriveTypeAutoRun') { should eq 1 }
end
end
Stacktrace
20) Registry Key HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\policies\Explorer No
DriveTypeAutoRun should eq 1
Failure/Error: DEFAULT_FAILURE_NOTIFIER = lambda { |failure, _opts| raise failure }
expected: 1
got: nil
(compared using ==)
# ./test/integration/default/config_spec.rb:191:in `block (3 levels) in load'
# C:/Users/jamgoins/.chefdk/gem/ruby/2.1.0/gems/inspec-0.22.1/lib/inspec/runner_rspec.rb:66:in
`run'
# C:/Users/jamgoins/.chefdk/gem/ruby/2.1.0/gems/kitchen-inspec-0.13.0/lib/kitchen/verifier/ins
pec.rb:50:in `call'
# C:/Users/jamgoins/.chefdk/gem/ruby/2.1.0/gems/test-kitchen-1.8.0/lib/kitchen/instance.rb:423
:in `block in verify_action'
# C:/Users/jamgoins/.chefdk/gem/ruby/2.1.0/gems/test-kitchen-1.8.0/lib/kitchen/instance.rb:513
:in `call'
# C:/Users/jamgoins/.chefdk/gem/ruby/2.1.0/gems/test-kitchen-1.8.0/lib/kitchen/instance.rb:513
:in `synchronize_or_call'
# C:/Users/jamgoins/.chefdk/gem/ruby/2.1.0/gems/test-kitchen-1.8.0/lib/kitchen/instance.rb:478
:in `block in action'
# C:/Users/jamgoins/.chefdk/gem/ruby/2.1.0/gems/test-kitchen-1.8.0/lib/kitchen/instance.rb:477
:in `action'
# C:/Users/jamgoins/.chefdk/gem/ruby/2.1.0/gems/test-kitchen-1.8.0/lib/kitchen/instance.rb:415
:in `verify_action'
# C:/Users/jamgoins/.chefdk/gem/ruby/2.1.0/gems/test-kitchen-1.8.0/lib/kitchen/instance.rb:348
:in `block in transition_to'
# C:/Users/jamgoins/.chefdk/gem/ruby/2.1.0/gems/test-kitchen-1.8.0/lib/kitchen/instance.rb:347
:in `each'
# C:/Users/jamgoins/.chefdk/gem/ruby/2.1.0/gems/test-kitchen-1.8.0/lib/kitchen/instance.rb:347
:in `transition_to'
# C:/Users/jamgoins/.chefdk/gem/ruby/2.1.0/gems/test-kitchen-1.8.0/lib/kitchen/instance.rb:160
:in `verify'
# C:/Users/jamgoins/.chefdk/gem/ruby/2.1.0/gems/test-kitchen-1.8.0/lib/kitchen/command.rb:176:
in `public_send'
# C:/Users/jamgoins/.chefdk/gem/ruby/2.1.0/gems/test-kitchen-1.8.0/lib/kitchen/command.rb:176:
in `block (2 levels) in run_action'
The text was updated successfully, but these errors were encountered:
Description
The registry_key test is not finding the key in Windows Server 2008 R2. It is returning nil when searching for any key.
InSpec and Platform Version
Running using Git Bash on Windows 7. Tests running on Windows Server 2008 R2 local VM.
Replication Case
Example:
Stacktrace
The text was updated successfully, but these errors were encountered: