Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Suppress deprecation warnings of
Psych.safe_load
args in Ruby 2.6
Follow up of #6395 (comment). The interface of `Psych.safe_load` will change from Ruby 2.6. ruby/ruby@1c92766 This PR suppresses the following wargnins in Ruby 2.6.0-dev. ```console % cd path/to/codeclimate/repo % ruby -v ruby 2.6.0dev (2018-10-21 trunk 65252) [x86_64-darwin17] % bundle exec rake (snip) warning: Passing whitelist_classes with the 2nd argument of Psych.safe_load is deprecated. Use keyword argument like Psych.safe_load(yaml, whitelist_classes: ...) instead. warning: Passing whitelist_symbols with the 3rd argument of Psych.safe_load is deprecated. Use keyword argument like Psych.safe_load(yaml, whitelist_symbols: ...) instead. warning: Passing aliases with the 4th argument of Psych.safe_load is deprecated. Use keyword argument like Psych.safe_load(yaml, aliases: ...) instead. warning: Passing filename with the 5th argument of Psych.safe_load is deprecated. Use keyword argument like Psych.safe_load(yaml, filename: ...) instead. (snip) Failures: 1) CC::CLI::VersionChecker prints nothing when up to date Failure/Error: expect(stderr).to eq "" expected: "" got: "warning: Passing whitelist_classes with the 2nd argument of Psych.safe_load is deprecated. Use keywo....safe_load is deprecated. Use keyword argument like Psych.safe_load(yaml, filename: ...) instead.\n" (snip) 2) CC::CLI::VersionChecker does nothing when API is unavailable Failure/Error: expect(stderr).to eq "" expected: "" got: "warning: Passing whitelist_classes with the 2nd argument of Psych.safe_load is deprecated. Use keywo....safe_load is deprecated. Use keyword argument like Psych.safe_load(yaml, filename: ...) instead.\n" (snip) 3) CC::CLI::VersionChecker does nothing if checked recently Failure/Error: expect(stderr).to eq "" expected: "" got: "warning: Passing whitelist_classes with the 2nd argument of Psych.safe_load is deprecated. Use keywo....safe_load is deprecated. Use keyword argument like Psych.safe_load(yaml, filename: ...) instead.\n" (snip) Finished in 0.63326 seconds (files took 0.71064 seconds to load) 338 examples, 3 failures Failed examples: rspec ./spec/cc/cli/version_checker_spec.rb:71 # CC::CLI::VersionChecker prints nothing when up to date rspec ./spec/cc/cli/version_checker_spec.rb:81 # CC::CLI::VersionChecker does nothing when API is unavailable rspec ./spec/cc/cli/version_checker_spec.rb:96 # CC::CLI::VersionChecker does nothing if checked recently ```
- Loading branch information