1
私はバンドラ経由スペックを実行すると、私はエラーを取得していない...非推奨の「春のRSpecの」と警告ではなく、「RSpecの」
bundle exec rspec -fd spec/controllers/blah.rb
しかし、私は春を使用するbinstubを経由して、それを実行したときに、私が取得これらの多くのエラー:
./bin/rspec -fd spec/controllers/blah.rb
DEPRECATION WARNING: `serialized_attributes` is deprecated without replacement, and will be removed in Rails 5.0.
なぜですか?
私は停止して起動しようとしました。無効。 config/environments/test.rb
で
私はこれを持っている:
# Print deprecation notices to the stderr.
config.active_support.deprecation = :stderr
参考
...
$ bundle list | grep -E '(rspec|spring)'
* rspec-core (3.0.4)
* rspec-expectations (3.0.4)
* rspec-mocks (3.0.4)
* rspec-rails (3.0.2)
* rspec-support (3.0.4)
* spring (1.7.2)
* spring-commands-rspec (1.0.4)
要求されたよう
、私の./bin/rspec
ファイル...
$ cat ./bin/rspec
#!/usr/bin/env ruby
begin
load File.expand_path('../spring', __FILE__)
rescue LoadError => e
raise unless e.message.include?('spring')
end
# frozen_string_literal: true
#
# This file was generated by Bundler.
#
# The application 'rspec' is installed as part of a gem, and
# this file is here to facilitate running it.
#
require "pathname"
ENV["BUNDLE_GEMFILE"] ||= File.expand_path("../../Gemfile",
Pathname.new(__FILE__).realpath)
require "rubygems"
require "bundler/setup"
load Gem.bin_path("rspec-core", "rspec")
そのではないではない春を経て、RSpecのために抑制する理由しかし、これは答えません
config.active_support.deprecation = :stderr
config.active_support.deprecation = :silence
に?!:
'。/ bin/rspec'の内容は何ですか? –
'--color --require spec_helper'(愚かなコメントフォーマットです!) – Nick
私は' --deprecation-out/dev/null'を使ってみましたが、運が無かった... – Nick