summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPete Higgins <pete@peterhiggins.org>2020-05-07 17:49:20 -0700
committerTim Smith <tsmith84@gmail.com>2020-05-18 20:29:40 -0700
commit828e3e525cdeef355f983c02586008a64f70a79c (patch)
treecb398a5f0fe8544f16a36a43bab712f46e429e2d
parent773c285b051b66224d91636b9c8069ce232901cb (diff)
downloadchef-828e3e525cdeef355f983c02586008a64f70a79c.tar.gz
More files free of spelling violations.
Signed-off-by: Pete Higgins <pete@peterhiggins.org>
-rw-r--r--chef-config/lib/chef-config/config.rb8
-rw-r--r--chef-config/lib/chef-config/path_helper.rb2
-rw-r--r--chef-config/spec/unit/config_spec.rb8
-rw-r--r--chef-config/spec/unit/workstation_config_loader_spec.rb10
-rw-r--r--chef-utils/README.md8
-rw-r--r--chef-utils/lib/chef-utils/dsl/platform_family.rb2
-rw-r--r--chef-utils/lib/chef-utils/dsl/which.rb8
-rw-r--r--chef-utils/lib/chef-utils/internal.rb2
-rw-r--r--chef-utils/lib/chef-utils/version_string.rb2
-rw-r--r--chef-utils/spec/unit/dsl/introspection_spec.rb2
-rw-r--r--chef-utils/spec/unit/dsl/which_spec.rb2
-rw-r--r--distro/templates/powershell/chef/chef.psm1.erb6
-rw-r--r--kitchen-tests/cookbooks/end_to_end/recipes/_tests.rb1
13 files changed, 31 insertions, 30 deletions
diff --git a/chef-config/lib/chef-config/config.rb b/chef-config/lib/chef-config/config.rb
index f34f6d82a3..7fc2e2c91e 100644
--- a/chef-config/lib/chef-config/config.rb
+++ b/chef-config/lib/chef-config/config.rb
@@ -479,7 +479,7 @@ module ChefConfig
# 11 (true) or Chef Server 12 (false). Chef Zero can still serve
# policyfile objects in Chef 11 mode, as long as `repo_mode` is set to
# "hosted_everything". The primary differences are:
- # * Chef 11 mode doesn't support multi-tennant, so there is no
+ # * Chef 11 mode doesn't support multi-tenant, so there is no
# distinction between global and org-specific objects (since there are
# no orgs).
# * Chef 11 mode doesn't expose RBAC objects
@@ -527,7 +527,7 @@ module ChefConfig
# switching based on it is almost certainly doing the wrong thing and papering over
# bugs that should be fixed in one or the other class, and will be brittle and destined
# to break in the future (and not necessarily on a major version bump). Checking this value
- # is also not sufficent to determine if we are not running against a server since this can
+ # is also not sufficient to determine if we are not running against a server since this can
# be unset but :local_mode may be set. It would be accurate to check both :solo and :local_mode
# to determine if we're not running against a server, but the more semantically accurate test
# is going to be combining :solo_legacy_mode and :local_mode.
@@ -952,7 +952,7 @@ module ChefConfig
# distribution.
#
# The disadvantages of lazily loading files are that users some time find it
- # confusing that their cookbooks are not fully synchronzied to the cache initially,
+ # confusing that their cookbooks are not fully synchronized to the cache initially,
# and more importantly the time-sensitive URLs which are in the manifest may time
# out on long Chef runs before the resource that uses the file is converged
# (leading to many confusing 403 errors on template/cookbook_file resources).
@@ -1109,7 +1109,7 @@ module ChefConfig
end
# Given a scheme, host, and port, return the correct proxy URI based on the
- # set environment variables, unless exluded by no_proxy, in which case nil
+ # set environment variables, unless excluded by no_proxy, in which case nil
# is returned
def self.proxy_uri(scheme, host, port)
proxy_env_var = ENV["#{scheme}_proxy"].to_s.strip
diff --git a/chef-config/lib/chef-config/path_helper.rb b/chef-config/lib/chef-config/path_helper.rb
index 0d0064838c..8429a08c1f 100644
--- a/chef-config/lib/chef-config/path_helper.rb
+++ b/chef-config/lib/chef-config/path_helper.rb
@@ -139,7 +139,7 @@ module ChefConfig
# backslashes on Windows.
#
# Generally, if the user isn't going to be seeing it, you should be
- # using Pathname#cleanpath intead of this function.
+ # using Pathname#cleanpath instead of this function.
def self.cleanpath(path)
path = Pathname.new(path).cleanpath.to_s
# ensure all forward slashes are backslashes
diff --git a/chef-config/spec/unit/config_spec.rb b/chef-config/spec/unit/config_spec.rb
index 5cf814e7b3..ccfe57c57c 100644
--- a/chef-config/spec/unit/config_spec.rb
+++ b/chef-config/spec/unit/config_spec.rb
@@ -175,11 +175,11 @@ RSpec.describe ChefConfig::Config do
end
context "when passes multiple cookbook_paths in config options" do
- let(:extra_config_options) { ["cookbook_path=[first_cookbook, secound_cookbooks]"] }
+ let(:extra_config_options) { ["cookbook_path=[first_cookbook, second_cookbooks]"] }
it "expanded paths" do
apply_config
- expect(described_class[:cookbook_path]).to eq(["#{current_directory}/first_cookbook", "#{current_directory}/secound_cookbooks"])
+ expect(described_class[:cookbook_path]).to eq(["#{current_directory}/first_cookbook", "#{current_directory}/second_cookbooks"])
end
end
end
@@ -205,8 +205,8 @@ RSpec.describe ChefConfig::Config do
# end
# else
# formatter = "null"
- # log_location = configured-value or defualt
- # log_level = info or defualt
+ # log_location = configured-value or default
+ # log_level = info or default
# end
#
it "has an empty list of formatters by default" do
diff --git a/chef-config/spec/unit/workstation_config_loader_spec.rb b/chef-config/spec/unit/workstation_config_loader_spec.rb
index f5fc7f90e2..c589b298ae 100644
--- a/chef-config/spec/unit/workstation_config_loader_spec.rb
+++ b/chef-config/spec/unit/workstation_config_loader_spec.rb
@@ -52,7 +52,7 @@ RSpec.describe ChefConfig::WorkstationConfigLoader do
end
it "tests a path's existence" do
- expect(config_loader.path_exists?("/nope/nope/nope/nope/frab/jab/nab")).to be(false)
+ expect(config_loader.path_exists?("/nope/nope/nope/nope/slab/jab/nab")).to be(false)
expect(config_loader.path_exists?(__FILE__)).to be(true)
end
@@ -214,7 +214,7 @@ RSpec.describe ChefConfig::WorkstationConfigLoader do
describe "loading the config file" do
- context "when no explicit config is specifed and no implicit config is found" do
+ context "when no explicit config is specified and no implicit config is found" do
before do
allow(config_loader).to receive(:path_exists?).with(an_instance_of(String)).and_return(false)
@@ -230,7 +230,7 @@ RSpec.describe ChefConfig::WorkstationConfigLoader do
context "when an explicit config is given but it doesn't exist" do
- let(:explicit_config_location) { "/nope/nope/nope/frab/jab/nab" }
+ let(:explicit_config_location) { "/nope/nope/nope/slab/jab/nab" }
it "raises a configuration error" do
expect { config_loader.load }.to raise_error(ChefConfig::ConfigurationError)
@@ -402,12 +402,12 @@ RSpec.describe ChefConfig::WorkstationConfigLoader do
end
context "has a non rb file" do
- let(:sytax_error_content) { "{{{{{:{{" }
+ let(:syntax_error_content) { "{{{{{:{{" }
let(:config_content) { "config_d_file_evaluated(true)" }
let!(:not_confd_file) do
Tempfile.new(["Chef-WorkstationConfigLoader-rspec-test", ".foorb"], tempdir).tap do |t|
- t.print(sytax_error_content)
+ t.print(syntax_error_content)
t.close
end
end
diff --git a/chef-utils/README.md b/chef-utils/README.md
index 96a165487d..01feafb3e8 100644
--- a/chef-utils/README.md
+++ b/chef-utils/README.md
@@ -30,9 +30,9 @@ The Platform Family helpers provide an alternative to comparing values from `nod
* `netbsd?`
* `openbsd?`
* `rhel?` - includes redhat, centos, scientific, oracle, and clearos platforms
-* `rhel6?` - includes redhat6, centos6, scientifc6, oracle6, and clearos6 platforms
-* `rhel7?` - includes redhat7, centos7, scientifc7, oracle7, and clearos7 platforms
-* `rhel8?` - includes redhat8, centos8, scientifc8, oracle8, and clearos8 platforms
+* `rhel6?` - includes redhat6, centos6, scientific6, oracle6, and clearos6 platforms
+* `rhel7?` - includes redhat7, centos7, scientific7, oracle7, and clearos7 platforms
+* `rhel8?` - includes redhat8, centos8, scientific8, oracle8, and clearos8 platforms
* `smartos?`
* `solaris2?`
* `suse?` - includes suse and opensuseleap platforms
@@ -41,7 +41,7 @@ The Platform Family helpers provide an alternative to comparing values from `nod
Super Families:
-* `fedora_based?` - anything of fedora lineage (fedora, fedhat, centos, amazon, pidora, etc)
+* `fedora_based?` - anything of fedora lineage (fedora, redhat, centos, amazon, pidora, etc)
* `rpm_based?`- all `fedora_based` systems plus `suse` and any future linux distros based on RPM (excluding AIX)
* `solaris_based?`- all solaris-derived systems (opensolaris, nexentacore, omnios, smartos, etc)
* `bsd_based?`- all bsd-derived systems (freebsd, netbsd, openbsd, dragonflybsd).
diff --git a/chef-utils/lib/chef-utils/dsl/platform_family.rb b/chef-utils/lib/chef-utils/dsl/platform_family.rb
index 8feadeb9c4..cfe6b617e5 100644
--- a/chef-utils/lib/chef-utils/dsl/platform_family.rb
+++ b/chef-utils/lib/chef-utils/dsl/platform_family.rb
@@ -301,7 +301,7 @@ module ChefUtils
end
# RedHat distros -- fedora and rhel platform_families, nothing else. This is most likely not as useful as the
- # "fedora_dervied?" helper.
+ # "fedora_derived?" helper.
#
# @param [Chef::Node] node the node to check
# @since 15.5
diff --git a/chef-utils/lib/chef-utils/dsl/which.rb b/chef-utils/lib/chef-utils/dsl/which.rb
index cc554a5e8a..a91e35da38 100644
--- a/chef-utils/lib/chef-utils/dsl/which.rb
+++ b/chef-utils/lib/chef-utils/dsl/which.rb
@@ -25,7 +25,7 @@ module ChefUtils
# Lookup an executable through the systems search PATH. Allows specifying an array
# of executables to look for. The first executable that is found, along any path entry,
# will be the preferred one and returned first. The extra_path will override any default
- # extra_paths which are added (allwing the user to pass an empty array to remove them).
+ # extra_paths which are added (allowing the user to pass an empty array to remove them).
#
# When passed a block the block will be called with the full pathname of any executables
# which are found, and the block should return truthy or falsey values to further filter
@@ -34,7 +34,7 @@ module ChefUtils
# This is syntactic sugar for `where(...).first`
#
# This helper can be used in target mode in chef or with train using the appropriate
- # wiring extenerally.
+ # wiring externally.
#
# @example Find the most appropriate python executable, searching through the system PATH
# plus additionally the "/usr/libexec" directory, which has the dnf libraries
@@ -55,14 +55,14 @@ module ChefUtils
# Lookup all the instances of an an executable that can be found through the systems search PATH.
# Allows specifying an array of executables to look for. All the instances of the first executable
# that is found will be returned first. The extra_path will override any default extra_paths
- # which are added (allwing the user to pass an empty array to remove them).
+ # which are added (allowing the user to pass an empty array to remove them).
#
# When passed a block the block will be called with the full pathname of any executables
# which are found, and the block should return truthy or falsey values to further filter
# the executable based on arbitrary criteria.
#
# This helper can be used in target mode in chef or with train using the appropriate
- # wiring extenerally.
+ # wiring externally.
#
# @example Find all the python executables, searching through the system PATH plus additionally
# the "/usr/libexec" directory, which have the dnf libraries installed and available.
diff --git a/chef-utils/lib/chef-utils/internal.rb b/chef-utils/lib/chef-utils/internal.rb
index 713ac277de..731a0d1712 100644
--- a/chef-utils/lib/chef-utils/internal.rb
+++ b/chef-utils/lib/chef-utils/internal.rb
@@ -27,7 +27,7 @@ module ChefUtils
#
# This gem may be used by gems like mixlib-shellout which can be consumed by external non-Chef utilities,
# so including brittle code here which depends on the existence of the chef-client will cause broken
- # behavior downstream. You must practice defensive coding, and not make assumptions about runnign within chef-client.
+ # behavior downstream. You must practice defensive coding, and not make assumptions about running within chef-client.
#
# Other consumers may mix in the helper classes and then override the methods here and provide their own custom
# wiring and override what is provided here. They are marked as private because no downstream user should ever touch
diff --git a/chef-utils/lib/chef-utils/version_string.rb b/chef-utils/lib/chef-utils/version_string.rb
index e0888b346e..744704dc63 100644
--- a/chef-utils/lib/chef-utils/version_string.rb
+++ b/chef-utils/lib/chef-utils/version_string.rb
@@ -143,7 +143,7 @@ module ChefUtils
begin
Gem::Requirement.create(other) =~ parsed_version
rescue ArgumentError
- # one side of the comparison wasn't parseable
+ # one side of the comparison wasn't parsable
super
end
end
diff --git a/chef-utils/spec/unit/dsl/introspection_spec.rb b/chef-utils/spec/unit/dsl/introspection_spec.rb
index 2b6c697fd7..44a228061d 100644
--- a/chef-utils/spec/unit/dsl/introspection_spec.rb
+++ b/chef-utils/spec/unit/dsl/introspection_spec.rb
@@ -31,7 +31,7 @@ RSpec.describe ChefUtils::DSL::Introspection do
let(:test_instance) { IntrospectionTestClass.new(node) }
context "#docker?" do
- # FIXME: use a real VividMash for these tests insted of stubbing
+ # FIXME: use a real VividMash for these tests instead of stubbing
it "is false by default" do
expect(node).to receive(:read).with("virtualization", "systems", "docker").and_return(nil)
expect(ChefUtils.docker?(node)).to be false
diff --git a/chef-utils/spec/unit/dsl/which_spec.rb b/chef-utils/spec/unit/dsl/which_spec.rb
index dc0f037a89..cd867c4e72 100644
--- a/chef-utils/spec/unit/dsl/which_spec.rb
+++ b/chef-utils/spec/unit/dsl/which_spec.rb
@@ -78,7 +78,7 @@ RSpec.describe ChefUtils::DSL::Which do
end
context "with a block" do
- test_which("doesnt find it if its false", "foo1", others: [ "/dir1/foo1" ]) do |f|
+ test_which("doesn't find it if its false", "foo1", others: [ "/dir1/foo1" ]) do |f|
false
end
diff --git a/distro/templates/powershell/chef/chef.psm1.erb b/distro/templates/powershell/chef/chef.psm1.erb
index 652dec04f6..f8b24dc54b 100644
--- a/distro/templates/powershell/chef/chef.psm1.erb
+++ b/distro/templates/powershell/chef/chef.psm1.erb
@@ -358,7 +358,7 @@ function Run-RubyCommand($command, $argList) {
# When arguments come into this method, the standard PS rules for interpreting cmdlet arguments
# apply. When using & (call operator) and providing an array of arguments, powershell (verified
# on PS 4.0 on Windows Server 2012R2) will not evaluate them but (contrary to documentation),
- # it will still marginally interpret them. The behaviour of PS 5.0 seems to be different but
+ # it will still marginally interpret them. The behavior of PS 5.0 seems to be different but
# ignore that for now. If any of the provided arguments has a space in it, powershell checks
# the first and last character to ensure that they are " characters (and that's all it checks).
# If they are not, it will blindly surround that argument with " characters. It won't do this
@@ -381,10 +381,10 @@ function Run-RubyCommand($command, $argList) {
# Command line:
# "C:\Program Files (x86)\PowerShell Community Extensions\Pscx3\Pscx\Apps\EchoArgs.exe" "foo '' bar "baz"" "foo '' bar "baz""
#
- # $x = "abc'123'nospace`"lulz`"!!!"
+ # $x = "abc'123'nospace`"lol`"!!!"
# & EchoArgs @($x, $x)
# Command line:
- # "C:\Program Files (x86)\PowerShell Community Extensions\Pscx3\Pscx\Apps\EchoArgs.exe" abc'123'nospace"lulz"!!! abc'123'nospace"lulz"!!!
+ # "C:\Program Files (x86)\PowerShell Community Extensions\Pscx3\Pscx\Apps\EchoArgs.exe" abc'123'nospace"lol"!!! abc'123'nospace"lol"!!!
#
# $x = "`"`"Look ma! Tonnes of spaces! 'foo' 'bar'`"`""
# & EchoArgs @($x, $x)
diff --git a/kitchen-tests/cookbooks/end_to_end/recipes/_tests.rb b/kitchen-tests/cookbooks/end_to_end/recipes/_tests.rb
index d74a310394..7f51361693 100644
--- a/kitchen-tests/cookbooks/end_to_end/recipes/_tests.rb
+++ b/kitchen-tests/cookbooks/end_to_end/recipes/_tests.rb
@@ -16,6 +16,7 @@ end
# this caught a regression in 12.14.70 before it was released when i
# ran it in lamont-ci, so added the test here so everyone else other than
# me gets coverage for this as well.
+# cspell:disable-next-line
file "/tmp/chef-test-\xFDmlaut" do
content "testing illegal UTF-8 char in the filename"
end