summaryrefslogtreecommitdiff
path: root/lib/chef/dsl
diff options
context:
space:
mode:
authortyler-ball <tyleraball@gmail.com>2014-11-10 09:52:06 -0800
committertyler-ball <tyleraball@gmail.com>2014-12-17 18:47:27 -0800
commit73594ef27855e6f1dabb57fdffa04adc881f06be (patch)
treeca9e00cddcf0b9b0ffc7b48f4627decd1b8b2918 /lib/chef/dsl
parent2bb912157470f55975f2e50e3792132478639a78 (diff)
downloadchef-73594ef27855e6f1dabb57fdffa04adc881f06be.tar.gz
Wiring audit event proxy to send events correctly to the audit_reporter
Diffstat (limited to 'lib/chef/dsl')
-rw-r--r--lib/chef/dsl/audit.rb2
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/chef/dsl/audit.rb b/lib/chef/dsl/audit.rb
index 42a1927efb..1849b65633 100644
--- a/lib/chef/dsl/audit.rb
+++ b/lib/chef/dsl/audit.rb
@@ -29,6 +29,8 @@ class Chef
# Adds the controls group and block (containing controls to execute) to the runner's list of pending examples
def controls(*args, &block)
raise ::Chef::Exceptions::NoAuditsProvided unless block
+ name = args[0]
+ raise AuditNameMissing if name.nil? || name.empty?
run_context.controls_groups << ::RSpec::Core::ExampleGroup.__controls__(*args, &block)
end