diff options
author | tyler-ball <tyleraball@gmail.com> | 2014-12-03 16:58:14 -0800 |
---|---|---|
committer | tyler-ball <tyleraball@gmail.com> | 2014-12-17 18:52:22 -0800 |
commit | 92f21502937682a3db715bf7c3a3b79e1bd784bc (patch) | |
tree | 30c3b07771c738553836611c20dceec0652cd358 /lib/chef/audit | |
parent | d454a7214b2738acd9a00e1f29737927a4a4d5d7 (diff) | |
download | chef-92f21502937682a3db715bf7c3a3b79e1bd784bc.tar.gz |
if in why_run, do not enter the audit phase - because people run why_run to see converge statistics
Diffstat (limited to 'lib/chef/audit')
-rw-r--r-- | lib/chef/audit/runner.rb | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/lib/chef/audit/runner.rb b/lib/chef/audit/runner.rb index b3df70f705..5d485a8804 100644 --- a/lib/chef/audit/runner.rb +++ b/lib/chef/audit/runner.rb @@ -35,10 +35,18 @@ class Chef do_run end - def failed_examples? + def failed? RSpec.world.reporter.failed_examples.size > 0 end + def num_failed + RSpec.world.reporter.failed_examples.size + end + + def num_total + RSpec.world.reporter.examples.size + end + private # Prepare to run audits: # - Require files |