diff options
author | Claire McQuin <claire@getchef.com> | 2014-12-08 16:19:08 -0800 |
---|---|---|
committer | Claire McQuin <claire@getchef.com> | 2014-12-08 16:19:08 -0800 |
commit | 186c1b6dca809445dfbeb3f34e06e29eeb0e79aa (patch) | |
tree | 7f8ef47f5d39423425a6295e5c4d6718c8f66727 /spec | |
parent | bd7939da4acd04963336759f8b1386a0f5fca6c2 (diff) | |
parent | c6e5654a18f236dd75bb59472e80887c27310d99 (diff) | |
download | chef-186c1b6dca809445dfbeb3f34e06e29eeb0e79aa.tar.gz |
Merge branch 'audit-mode' of github.com:opscode/chef into mcquin/audit_reporter_spec
Diffstat (limited to 'spec')
26 files changed, 110 insertions, 99 deletions
diff --git a/spec/functional/resource/aixinit_service_spec.rb b/spec/functional/resource/aixinit_service_spec.rb index 3d3234f0f7..19b65ca2a0 100755 --- a/spec/functional/resource/aixinit_service_spec.rb +++ b/spec/functional/resource/aixinit_service_spec.rb @@ -28,7 +28,7 @@ describe Chef::Resource::Service, :requires_root, :aix_only do # Platform specific validation routines. def service_should_be_started(file_name) - # The existance of this file indicates that the service was started. + # The existence of this file indicates that the service was started. expect(File.exists?("/tmp/#{file_name}")).to be_truthy end diff --git a/spec/support/pedant/pedant_config.rb b/spec/support/pedant/pedant_config.rb index f7d14d8f17..3f8219fc59 100644 --- a/spec/support/pedant/pedant_config.rb +++ b/spec/support/pedant/pedant_config.rb @@ -26,7 +26,7 @@ # If you are doing development testing, you can specify the address of # the Solr server. The presence of this parameter will enable tests -# to force commits to Solr, greatly decreasing the amout of time +# to force commits to Solr, greatly decreasing the amount of time # needed for testing the search endpoint. This is only an # optimization for development! If you are testing a "live" Chef # Server, or otherwise do not have access to the Solr server from your @@ -36,7 +36,7 @@ #search_server "http://localhost:8983" # Related to the 'search_server' parameter, this specifies the maximum -# amout of time (in seconds) that search endpoint requests should be +# amount of time (in seconds) that search endpoint requests should be # retried before giving up. If not explicitly set, it will default to # 65 seconds; only set it if you know that your Solr commit interval # differs significantly from this. diff --git a/spec/support/shared/functional/file_resource.rb b/spec/support/shared/functional/file_resource.rb index bcc2a7da25..4f8e2f5b71 100644 --- a/spec/support/shared/functional/file_resource.rb +++ b/spec/support/shared/functional/file_resource.rb @@ -813,7 +813,7 @@ shared_examples_for "a configured file resource" do # Regression test for http://tickets.opscode.com/browse/CHEF-4082 context "when notification is configured" do - describe "when path is specified with normal seperator" do + describe "when path is specified with normal separator" do before do @notified_resource = Chef::Resource.new("punk", resource.run_context) resource.notifies(:run, @notified_resource, :immediately) @@ -826,7 +826,7 @@ shared_examples_for "a configured file resource" do end end - describe "when path is specified with windows seperator", :windows_only do + describe "when path is specified with windows separator", :windows_only do let(:path) { File.join(test_file_dir, make_tmpname(file_base)).gsub(::File::SEPARATOR, ::File::ALT_SEPARATOR) } diff --git a/spec/support/shared/functional/http.rb b/spec/support/shared/functional/http.rb index 9a3389306d..963fbf1c5b 100644 --- a/spec/support/shared/functional/http.rb +++ b/spec/support/shared/functional/http.rb @@ -131,7 +131,7 @@ module ChefHTTPShared } # - # in the presense of a transfer-encoding header, we must ignore the content-length (this bad content-length should work) + # in the presence of a transfer-encoding header, we must ignore the content-length (this bad content-length should work) # # (expected_content should be uncompressed) diff --git a/spec/support/shared/unit/api_error_inspector.rb b/spec/support/shared/unit/api_error_inspector.rb index e85fa971e9..29faa07f29 100644 --- a/spec/support/shared/unit/api_error_inspector.rb +++ b/spec/support/shared/unit/api_error_inspector.rb @@ -23,7 +23,7 @@ # runs without error, but don't make assertions about the output. This is # because aspects such as how information gets formatted, what's included, etc. # are still in flux. When testing an inspector, change the outputter to use -# STDOUT and manually check the ouput. +# STDOUT and manually check the output. shared_examples_for "an api error inspector" do diff --git a/spec/unit/application/knife_spec.rb b/spec/unit/application/knife_spec.rb index 806a596a61..3c215eac7f 100644 --- a/spec/unit/application/knife_spec.rb +++ b/spec/unit/application/knife_spec.rb @@ -33,6 +33,11 @@ describe Chef::Application::Knife do end end + after(:each) do + # reset some really nasty global state + NoopKnifeCommand.reset_config_loader! + end + before(:each) do # Prevent code from getting loaded on every test invocation. allow(Chef::Knife).to receive(:load_commands) @@ -109,7 +114,6 @@ describe Chef::Application::Knife do end expect(Chef::Config[:client_key]).to eq(full_path) end - end describe "with environment configuration" do @@ -168,6 +172,6 @@ describe Chef::Application::Knife do @knife.run end end - end + end diff --git a/spec/unit/config_spec.rb b/spec/unit/config_spec.rb index 58fb229c96..ed2003e8bf 100644 --- a/spec/unit/config_spec.rb +++ b/spec/unit/config_spec.rb @@ -426,7 +426,7 @@ describe Chef::Config do let(:locales) { locale_array.join("\n") } before do - allow(Chef::Config).to receive(:shell_out_with_systems_locale).with("locale -a").and_return(shell_out) + allow(Chef::Config).to receive(:shell_out_with_systems_locale!).with("locale -a").and_return(shell_out) end shared_examples_for "a suitable locale" do @@ -493,7 +493,7 @@ describe Chef::Config do let(:locale_array) { [] } before do - allow(Chef::Config).to receive(:shell_out_with_systems_locale).and_raise("THIS IS AN ERROR") + allow(Chef::Config).to receive(:shell_out_with_systems_locale!).and_raise("THIS IS AN ERROR") end it "should default to 'en_US.UTF-8'" do diff --git a/spec/unit/cookbook/metadata_spec.rb b/spec/unit/cookbook/metadata_spec.rb index a1903a1948..760ae5dd2a 100644 --- a/spec/unit/cookbook/metadata_spec.rb +++ b/spec/unit/cookbook/metadata_spec.rb @@ -441,7 +441,7 @@ describe Chef::Cookbook::Metadata do }.not_to raise_error end - it "should let type be hash (backwards compatability only)" do + it "should let type be hash (backwards compatibility only)" do expect { metadata.attribute("db/mysql/databases", :type => "hash") }.not_to raise_error diff --git a/spec/unit/cookbook_version_spec.rb b/spec/unit/cookbook_version_spec.rb index 3d0348553b..6dd3429ffc 100644 --- a/spec/unit/cookbook_version_spec.rb +++ b/spec/unit/cookbook_version_spec.rb @@ -396,7 +396,7 @@ describe Chef::CookbookVersion do expect(@cookbook_version).to have_template_for_node(@node, ["test.erb"]) end - it "should see a template using an array lookup with non-existant elements" do + it "should see a template using an array lookup with non-existent elements" do expect(@cookbook_version).to have_template_for_node(@node, ["missing.txt", "test.erb"]) end @@ -408,23 +408,23 @@ describe Chef::CookbookVersion do expect(@cookbook_version).to have_cookbook_file_for_node(@node, ["test.txt"]) end - it "should see a file using an array lookup with non-existant elements" do + it "should see a file using an array lookup with non-existent elements" do expect(@cookbook_version).to have_cookbook_file_for_node(@node, ["missing.txt", "test.txt"]) end - it "should not see a non-existant template" do + it "should not see a non-existent template" do expect(@cookbook_version).not_to have_template_for_node(@node, "missing.erb") end - it "should not see a non-existant template using an array lookup" do + it "should not see a non-existent template using an array lookup" do expect(@cookbook_version).not_to have_template_for_node(@node, ["missing.erb"]) end - it "should not see a non-existant file" do + it "should not see a non-existent file" do expect(@cookbook_version).not_to have_cookbook_file_for_node(@node, "missing.txt") end - it "should not see a non-existant file using an array lookup" do + it "should not see a non-existent file using an array lookup" do expect(@cookbook_version).not_to have_cookbook_file_for_node(@node, ["missing.txt"]) end diff --git a/spec/unit/formatters/error_inspectors/resource_failure_inspector_spec.rb b/spec/unit/formatters/error_inspectors/resource_failure_inspector_spec.rb index ee957ed450..a42d234601 100644 --- a/spec/unit/formatters/error_inspectors/resource_failure_inspector_spec.rb +++ b/spec/unit/formatters/error_inspectors/resource_failure_inspector_spec.rb @@ -114,20 +114,20 @@ describe Chef::Formatters::ErrorInspectors::ResourceFailureInspector do describe "recipe_snippet" do before do # fake code to run through #recipe_snippet - source_file = [ "if true", "var = non_existant", "end" ] + source_file = [ "if true", "var = non_existent", "end" ] allow(IO).to receive(:readlines).and_return(source_file) allow(File).to receive(:exists?).and_return(true) end it "parses a Windows path" do - source_line = "C:/Users/btm/chef/chef/spec/unit/fake_file.rb:2: undefined local variable or method `non_existant' for main:Object (NameError)" + source_line = "C:/Users/btm/chef/chef/spec/unit/fake_file.rb:2: undefined local variable or method `non_existent' for main:Object (NameError)" @resource.source_line = source_line @inspector = Chef::Formatters::ErrorInspectors::ResourceFailureInspector.new(@resource, :create, @exception) expect(@inspector.recipe_snippet).to match(/^# In C:\/Users\/btm/) end it "parses a unix path" do - source_line = "/home/btm/src/chef/chef/spec/unit/fake_file.rb:2: undefined local variable or method `non_existant' for main:Object (NameError)" + source_line = "/home/btm/src/chef/chef/spec/unit/fake_file.rb:2: undefined local variable or method `non_existent' for main:Object (NameError)" @resource.source_line = source_line @inspector = Chef::Formatters::ErrorInspectors::ResourceFailureInspector.new(@resource, :create, @exception) expect(@inspector.recipe_snippet).to match(/^# In \/home\/btm/) @@ -145,7 +145,7 @@ describe Chef::Formatters::ErrorInspectors::ResourceFailureInspector do expect(@inspector.recipe_snippet).to be_nil end - it "does not raise an exception trying to load a non-existant file (CHEF-3411)" do + it "does not raise an exception trying to load a non-existent file (CHEF-3411)" do @resource.source_line = "/somewhere/in/space" @inspector = Chef::Formatters::ErrorInspectors::ResourceFailureInspector.new(@resource, :create, @exception) expect { @inspector.recipe_snippet }.not_to raise_error diff --git a/spec/unit/handler_spec.rb b/spec/unit/handler_spec.rb index a9aa0e0b50..e7f67405fc 100644 --- a/spec/unit/handler_spec.rb +++ b/spec/unit/handler_spec.rb @@ -84,7 +84,7 @@ describe Chef::Handler do end it "has a shortcut for the success? and failed? predicates" do - expect(@handler.success?).to be_falsey # becuase there's an exception + expect(@handler.success?).to be_falsey # because there's an exception expect(@handler.failed?).to be_truthy end diff --git a/spec/unit/knife/core/bootstrap_context_spec.rb b/spec/unit/knife/core/bootstrap_context_spec.rb index 1291571358..af8fa3f698 100644 --- a/spec/unit/knife/core/bootstrap_context_spec.rb +++ b/spec/unit/knife/core/bootstrap_context_spec.rb @@ -205,4 +205,18 @@ EXPECTED end end + describe "prerelease" do + it "isn't set in the config_content by default" do + expect(bootstrap_context.config_content).not_to include("prerelease") + end + + describe "when configured via cli" do + let(:config) {{:prerelease => true}} + + it "uses CLI value" do + expect(bootstrap_context.latest_current_chef_version_string).to eq("-p") + end + end + end + end diff --git a/spec/unit/knife/node_run_list_remove_spec.rb b/spec/unit/knife/node_run_list_remove_spec.rb index ea951e21dd..ceceef7178 100644 --- a/spec/unit/knife/node_run_list_remove_spec.rb +++ b/spec/unit/knife/node_run_list_remove_spec.rb @@ -66,9 +66,24 @@ describe Chef::Knife::NodeRunListRemove do expect(@node.run_list).not_to include('role[monkey]') expect(@node.run_list).not_to include('recipe[duck::type]') end + + it "should remove the items from the run list when name args contains whitespace" do + @node.run_list << 'role[monkey]' + @node.run_list << 'recipe[duck::type]' + @knife.name_args = [ 'adam', 'role[monkey], recipe[duck::type]' ] + @knife.run + expect(@node.run_list).not_to include('role[monkey]') + expect(@node.run_list).not_to include('recipe[duck::type]') + end + + it "should remove the items from the run list when name args contains multiple run lists" do + @node.run_list << 'role[blah]' + @node.run_list << 'recipe[duck::type]' + @knife.name_args = [ 'adam', 'role[monkey], recipe[duck::type]', 'role[blah]' ] + @knife.run + expect(@node.run_list).not_to include('role[monkey]') + expect(@node.run_list).not_to include('recipe[duck::type]') + end end end end - - - diff --git a/spec/unit/knife_spec.rb b/spec/unit/knife_spec.rb index d35ba4fa5f..8f652e58c7 100644 --- a/spec/unit/knife_spec.rb +++ b/spec/unit/knife_spec.rb @@ -44,6 +44,10 @@ describe Chef::Knife do @stderr = StringIO.new end + after(:each) do + Chef::Knife.reset_config_loader! + end + describe "after loading a subcommand" do before do Chef::Knife.reset_subcommands! @@ -64,7 +68,7 @@ describe Chef::Knife do expect(KnifeSpecs::TestNameMapping.subcommand_category).to eq('test') end - it "has an explictly defined category if set" do + it "has an explicitly defined category if set" do expect(KnifeSpecs::TestExplicitCategory.subcommand_category).to eq('cookbook site') end @@ -268,6 +272,7 @@ describe Chef::Knife do @knife.config[:verbosity] = 1 @knife.config[:config_file] = fake_config config_loader = double("Chef::WorkstationConfigLoader", :load => true, :no_config_found? => false, :chef_config_dir => "/etc/chef", :config_location => fake_config) + allow(config_loader).to receive(:explicit_config_file=).with(fake_config).and_return(fake_config) allow(Chef::WorkstationConfigLoader).to receive(:new).and_return(config_loader) end diff --git a/spec/unit/lwrp_spec.rb b/spec/unit/lwrp_spec.rb index 0fb0ea7cab..35963dec64 100644 --- a/spec/unit/lwrp_spec.rb +++ b/spec/unit/lwrp_spec.rb @@ -247,7 +247,7 @@ describe "LWRP" do end end - it "ammends actions when they are already defined" do + it "amends actions when they are already defined" do raise_if_deprecated! expect(child.actions).to eq([:eat, :sleep, :drink]) end diff --git a/spec/unit/mixin/deep_merge_spec.rb b/spec/unit/mixin/deep_merge_spec.rb index 779445e04e..d107323f32 100644 --- a/spec/unit/mixin/deep_merge_spec.rb +++ b/spec/unit/mixin/deep_merge_spec.rb @@ -290,32 +290,6 @@ describe Chef::Mixin::DeepMerge do end - describe "role_merge" do - it "errors out if knockout merge use is detected in an array" do - hash_dst = {"property" => ["2","4"]} - hash_src = {"property" => ["1","!merge:4"]} - expect {@dm.role_merge(hash_dst, hash_src)}.to raise_error(Chef::Mixin::DeepMerge::InvalidSubtractiveMerge) - end - - it "errors out if knockout merge use is detected in an array (reversed merge order)" do - hash_dst = {"property" => ["1","!merge:4"]} - hash_src = {"property" => ["2","4"]} - expect {@dm.role_merge(hash_dst, hash_src)}.to raise_error(Chef::Mixin::DeepMerge::InvalidSubtractiveMerge) - end - - it "errors out if knockout merge use is detected in a string" do - hash_dst = {"property" => ["2","4"]} - hash_src = {"property" => "!merge"} - expect {@dm.role_merge(hash_dst, hash_src)}.to raise_error(Chef::Mixin::DeepMerge::InvalidSubtractiveMerge) - end - - it "errors out if knockout merge use is detected in a string (reversed merge order)" do - hash_dst = {"property" => "!merge"} - hash_src= {"property" => ["2","4"]} - expect {@dm.role_merge(hash_dst, hash_src)}.to raise_error(Chef::Mixin::DeepMerge::InvalidSubtractiveMerge) - end - end - describe "hash-only merging" do it "merges Hashes like normal deep merge" do merge_ee_hash = {"top_level_a" => {"1_deep_a" => "1-a-merge-ee", "1_deep_b" => "1-deep-b-merge-ee"}, "top_level_b" => "top-level-b-merge-ee"} diff --git a/spec/unit/monkey_patches/string_spec.rb b/spec/unit/monkey_patches/string_spec.rb deleted file mode 100644 index 74e3753229..0000000000 --- a/spec/unit/monkey_patches/string_spec.rb +++ /dev/null @@ -1,37 +0,0 @@ -# -# Author:: Devin Ben-Hur <dbenhur@whitepages.com> -# Copyright:: Copyright (c) 2008, 2011 Opscode, Inc. -# License:: Apache License, Version 2.0 -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# - -require 'spec_helper' -require 'chef/monkey_patches/string' - -describe String do - - describe "#ord" do - it "converts each ASCII-8BIT character to corresponding positive Fixnum" do - (0..0xff).each do |num| - ch = num.chr - ch.force_encoding('ASCII-8BIT') if ch.respond_to? :force_encoding - - expect(ch.ord).to be_a_kind_of(Fixnum) - expect(ch.ord).to eq(num) - end - end - - end - -end diff --git a/spec/unit/node/attribute_spec.rb b/spec/unit/node/attribute_spec.rb index 39e40a465f..c924ee2811 100644 --- a/spec/unit/node/attribute_spec.rb +++ b/spec/unit/node/attribute_spec.rb @@ -486,6 +486,34 @@ describe Chef::Node::Attribute do expect(hash.class).to eq(Hash) expect(hash["day"]).to eq("sunday") end + + it "should create a deep copy of the node attribute" do + @attributes.default['foo']['bar']['baz'] = 'fizz' + hash = @attributes['foo'].to_hash + expect(hash).to eql({"bar"=>{"baz"=>"fizz"}}) + hash['bar']['baz'] = 'buzz' + expect(hash).to eql({"bar"=>{"baz"=>"buzz"}}) + expect(@attributes.default['foo']).to eql({"bar"=>{"baz"=>"fizz"}}) + end + + it "should create a deep copy of arrays in the node attribute" do + @attributes.default['foo']['bar'] = ['fizz'] + hash = @attributes['foo'].to_hash + expect(hash).to eql({"bar"=>[ 'fizz' ]}) + hash['bar'].push('buzz') + expect(hash).to eql({"bar"=>[ 'fizz', 'buzz' ]}) + expect(@attributes.default['foo']).to eql({"bar"=>[ 'fizz' ]}) + end + + it "mutating strings should not mutate the attributes" do + pending "this is a bug that should be fixed" + @attributes.default['foo']['bar']['baz'] = 'fizz' + hash = @attributes['foo'].to_hash + expect(hash).to eql({"bar"=>{"baz"=>"fizz"}}) + hash['bar']['baz'] << 'buzz' + expect(hash).to eql({"bar"=>{"baz"=>"fizzbuzz"}}) + expect(@attributes.default['foo']).to eql({"bar"=>{"baz"=>"fizz"}}) + end end describe "dup" do diff --git a/spec/unit/node/immutable_collections_spec.rb b/spec/unit/node/immutable_collections_spec.rb index b1e7b9169b..d0ec81c7f7 100644 --- a/spec/unit/node/immutable_collections_spec.rb +++ b/spec/unit/node/immutable_collections_spec.rb @@ -33,7 +33,7 @@ describe Chef::Node::ImmutableMash do expect(@immutable_mash[:top][:second_level]).to eq("some value") end - it "elelment references like a regular Mash" do + it "element references like a regular Mash" do expect(@immutable_mash[:top_level_2]).to eq(%w[array of values]) end diff --git a/spec/unit/provider/package/rubygems_spec.rb b/spec/unit/provider/package/rubygems_spec.rb index a3a4772229..b4960b2af3 100644 --- a/spec/unit/provider/package/rubygems_spec.rb +++ b/spec/unit/provider/package/rubygems_spec.rb @@ -536,6 +536,14 @@ describe Chef::Provider::Package::Rubygems do expect(@provider.action_install).to be_truthy end + it "installs the gem by shelling out when options are provided but no version is given" do + @new_resource.options('-i /alt/install/location') + @new_resource.version('') + expected ="gem install \"rspec-core\" -q --no-rdoc --no-ri -i /alt/install/location" + expect(@provider).to receive(:shell_out!).with(expected, :env => nil) + expect(@provider.action_install).to be_truthy + end + it "installs the gem via the gems api when options are given as a Hash" do @new_resource.options(:install_dir => '/alt/install/location') expect(@provider.gem_env).to receive(:install).with(@gem_dep, :sources => nil, :install_dir => '/alt/install/location') diff --git a/spec/unit/resource_definition_spec.rb b/spec/unit/resource_definition_spec.rb index 01e28bf091..1371a8b9a6 100644 --- a/spec/unit/resource_definition_spec.rb +++ b/spec/unit/resource_definition_spec.rb @@ -85,7 +85,7 @@ describe Chef::ResourceDefinition do expect(defn.recipe.call).to eql("I am what I am") end - it "should set paramaters based on method_missing" do + it "should set parameters based on method_missing" do defn.mind "to fly" expect(defn.params[:mind]).to eql("to fly") end diff --git a/spec/unit/resource_spec.rb b/spec/unit/resource_spec.rb index bb02d91b23..335956009f 100644 --- a/spec/unit/resource_spec.rb +++ b/spec/unit/resource_spec.rb @@ -324,7 +324,7 @@ describe Chef::Resource do expect(zm.is("one", "two", "three")).to eq(%w|one two three|) end - it "should allow arguments preceeded by is to methods" do + it "should allow arguments preceded by is to methods" do @resource.noop(@resource.is(true)) expect(@resource.noop).to eql(true) end diff --git a/spec/unit/run_list/run_list_expansion_spec.rb b/spec/unit/run_list/run_list_expansion_spec.rb index 927257875e..859219d346 100644 --- a/spec/unit/run_list/run_list_expansion_spec.rb +++ b/spec/unit/run_list/run_list_expansion_spec.rb @@ -97,7 +97,7 @@ describe Chef::RunList::RunListExpansion do expect(@expansion.recipes).to eq(['lobster', 'crabrevenge', 'fist']) end - it "has the merged attributes from the roles with outer roles overridding inner" do + it "has the merged attributes from the roles with outer roles overriding inner" do expect(@expansion.default_attrs).to eq({'foo' => 'bar'}) expect(@expansion.override_attrs).to eq({'baz' => 'qux'}) end @@ -109,7 +109,7 @@ describe Chef::RunList::RunListExpansion do end - describe "after expanding a run list with a non existant role" do + describe "after expanding a run list with a non existent role" do before do allow(@expansion).to receive(:fetch_role) { @expansion.role_not_found('crabrevenge', "role[base]") } @expansion.expand diff --git a/spec/unit/shell_spec.rb b/spec/unit/shell_spec.rb index 58dea4c988..0e028f4359 100644 --- a/spec/unit/shell_spec.rb +++ b/spec/unit/shell_spec.rb @@ -47,7 +47,7 @@ describe Shell do describe "reporting its status" do - it "alway says it is running" do + it "always says it is running" do expect(Shell).to be_running end diff --git a/spec/unit/util/dsc/configuration_generator_spec.rb b/spec/unit/util/dsc/configuration_generator_spec.rb index c39c949991..e75e285d43 100644 --- a/spec/unit/util/dsc/configuration_generator_spec.rb +++ b/spec/unit/util/dsc/configuration_generator_spec.rb @@ -137,7 +137,7 @@ describe Chef::Util::DSC::ConfigurationGenerator do describe "#find_configuration_document" do it "should find the mof file" do - # These tests seem way too implementation specific. Unfortunatly, File and Dir + # These tests seem way too implementation specific. Unfortunately, File and Dir # need to be mocked because they are OS specific allow(File).to receive(:join) do |a, b| [a,b].join("++") diff --git a/spec/unit/workstation_config_loader_spec.rb b/spec/unit/workstation_config_loader_spec.rb index 0f60e3ec38..a865103188 100644 --- a/spec/unit/workstation_config_loader_spec.rb +++ b/spec/unit/workstation_config_loader_spec.rb @@ -219,7 +219,7 @@ describe Chef::WorkstationConfigLoader do end - context "when an explict config is given but it doesn't exist" do + context "when an explicit config is given but it doesn't exist" do let(:explicit_config_location) { "/nope/nope/nope/frab/jab/nab" } |