diff options
author | Tim Smith <tsmith84@gmail.com> | 2021-12-26 18:50:43 -0800 |
---|---|---|
committer | Tim Smith <tsmith84@gmail.com> | 2021-12-26 18:50:43 -0800 |
commit | f84a238a1d8d0060d5064eee0b74ed942088d4fd (patch) | |
tree | d26039e8502c84a0c2e2c947227bab5f02139c81 /spec/support/ruby_installer.rb | |
parent | 50a0001bae754c66feb69c84b64cb305a03a34d2 (diff) | |
download | chef-Performance_RegexpMatch.tar.gz |
Resolve Performance/RegexpMatch warningsPerformance_RegexpMatch
Do regex checks without creating objects for the results.
Signed-off-by: Tim Smith <tsmith@chef.io>
Diffstat (limited to 'spec/support/ruby_installer.rb')
-rw-r--r-- | spec/support/ruby_installer.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/spec/support/ruby_installer.rb b/spec/support/ruby_installer.rb index ae282d3b2d..d03525268f 100644 --- a/spec/support/ruby_installer.rb +++ b/spec/support/ruby_installer.rb @@ -48,4 +48,4 @@ rescue LoadError $stderr.puts "Failed to load ruby_installer. Assuming Ruby Installer is not being used." end -add_libarchive_dll_directory if RUBY_PLATFORM =~ /mswin|mingw32|windows/ +add_libarchive_dll_directory if RUBY_PLATFORM.match?(/mswin|mingw32|windows/) |