summaryrefslogtreecommitdiff
path: root/chef-config/spec
diff options
context:
space:
mode:
authorLamont Granquist <lamont@scriptkiddie.org>2019-03-11 11:49:31 -0700
committerLamont Granquist <lamont@scriptkiddie.org>2019-03-11 11:49:31 -0700
commit66015ba654469f4dacfd78d40b02aafee52bbf1b (patch)
treeb00d0de111d18980f446b006ac63ef599eea8108 /chef-config/spec
parent4037976199b728d4bdc18fd428e8d40a84c97e2b (diff)
downloadchef-66015ba654469f4dacfd78d40b02aafee52bbf1b.tar.gz
Extract Action Collection from Data Collector
See the PR for details on this change. Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
Diffstat (limited to 'chef-config/spec')
-rw-r--r--chef-config/spec/unit/config_spec.rb19
1 files changed, 16 insertions, 3 deletions
diff --git a/chef-config/spec/unit/config_spec.rb b/chef-config/spec/unit/config_spec.rb
index b6e88f0bc8..0e17753185 100644
--- a/chef-config/spec/unit/config_spec.rb
+++ b/chef-config/spec/unit/config_spec.rb
@@ -1,7 +1,7 @@
#
# Author:: Adam Jacob (<adam@chef.io>)
# Author:: Kyle Goodwin (<kgoodwin@primerevenue.com>)
-# Copyright:: Copyright 2008-2016, Chef Software Inc.
+# Copyright:: Copyright 2008-2019, Chef Software Inc.
# License:: Apache License, Version 2.0
#
# Licensed under the Apache License, Version 2.0 (the "License");
@@ -1197,10 +1197,23 @@ RSpec.describe ChefConfig::Config do
end
- context "for Chef Solo" do
+ context "for Chef Solo legacy mode" do
before do
- ChefConfig::Config[:solo] = true
+ ChefConfig::Config[:solo_legacy_mode] = true
+ end
+
+ it "sets the data collector server URL to nil" do
+ ChefConfig::Config[:chef_server_url] = "https://chef.example/organizations/myorg"
+ expect(ChefConfig::Config[:data_collector][:server_url]).to be_nil
+ end
+
+ end
+
+ context "for local mode" do
+
+ before do
+ ChefConfig::Config[:local_mode] = true
end
it "sets the data collector server URL to nil" do