1
0
Fork 0
mirror of https://github.com/rails/rails.git synced 2022-11-09 12:12:34 -05:00

Ignore warnings such as Psych.safe_load is deprecated

Addressing warnings are important but it should be out of this test scope.

https://travis-ci.org/rails/rails/jobs/454145524#L4122-L4131

```
.F
Failure:
ApplicationTests::BinSetupTest#test_bin_setup_output [test/application/bin_setup_test.rb:49]:
--- expected
+++ actual
@@ -1,4 +1,5 @@
 "== Installing dependencies ==
+warning: Passing permitted_classes with the 2nd argument of Psych.safe_load is deprecated. Use keyword argument like Psych.safe_load(yaml, permitted_classes: ...) instead.
 The Gemfile's dependencies are satisfied

 == Preparing database ==
rails test test/application/bin_setup_test.rb:38
```
This commit is contained in:
Yasuo Honda 2018-11-13 11:19:03 +00:00
parent 82f2e9741f
commit 8ac8396259

View file

@ -45,6 +45,8 @@ module ApplicationTests
output.sub!(/^Resolving dependencies\.\.\.\n/, "")
# Suppress Bundler platform warnings from output
output.gsub!(/^The dependency .* will be unused .*\.\n/, "")
# Ignore warnings such as `Psych.safe_load is deprecated`
output.gsub!(/^warning:\s.*\n/, "")
assert_equal(<<~OUTPUT, output)
== Installing dependencies ==