summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTim Smith <tsmith@chef.io>2021-04-29 15:47:25 -0700
committerGitHub <noreply@github.com>2021-04-29 15:47:25 -0700
commit70d3dcf7729eda03c7136df6cdeb0968ebca9344 (patch)
tree90469132eb9ad7d81d691b9bd461996acb4240c5
parentda03cf40823c4bc206588fe7a5d29808aab6a91f (diff)
parent7769e4060d105ae86e2f5fa4221688e2cb7387da (diff)
downloadchef-70d3dcf7729eda03c7136df6cdeb0968ebca9344.tar.gz
Merge pull request #11481 from chef/cli_by_default
Make CLI one of the default reporters for Compliance Phase
-rw-r--r--lib/chef/compliance/default_attributes.rb2
-rw-r--r--spec/unit/compliance/runner_spec.rb2
2 files changed, 2 insertions, 2 deletions
diff --git a/lib/chef/compliance/default_attributes.rb b/lib/chef/compliance/default_attributes.rb
index 90ddbbc83a..9196944b92 100644
--- a/lib/chef/compliance/default_attributes.rb
+++ b/lib/chef/compliance/default_attributes.rb
@@ -28,7 +28,7 @@ class Chef
# Controls what is done with the resulting report after the Chef InSpec run.
# Accepts a single string value or an array of multiple values.
# Accepted values: 'chef-server-automate', 'chef-automate', 'json-file', 'audit-enforcer', 'cli'
- "reporter" => "json-file",
+ "reporter" => %w{json-file cli},
# Controls if Chef InSpec profiles should be fetched from Chef Automate or Chef Infra Server
# in addition to the default fetch locations provided by Chef Inspec.
diff --git a/spec/unit/compliance/runner_spec.rb b/spec/unit/compliance/runner_spec.rb
index 3948970137..e60195b8ec 100644
--- a/spec/unit/compliance/runner_spec.rb
+++ b/spec/unit/compliance/runner_spec.rb
@@ -234,7 +234,7 @@ describe Chef::Compliance::Runner do
inputs = runner.inspec_opts[:inputs]
expect(inputs["tacos"]).to eq("lunch")
- expect(inputs["chef_node"]["audit"]["reporter"]).to eq("json-file")
+ expect(inputs["chef_node"]["audit"]["reporter"]).to eq(%w{json-file cli})
expect(inputs["chef_node"]["chef_environment"]).to eq("_default")
end
end