I am testing a rails 4.1.0 application with rspec-rails 3.0.1. rspec command is printing a large number of warnings about the gems I am using in the application. I have included a part of the output below. I want to know whether is it possible to suppress this.
/home/indika/Documents/rails/news_app/config/initializers/kramdown.rb:6: warning: method redefined; discarding old convert_img
/home/indika/.rbenv/versions/2.1.1/lib/ruby/gems/2.1.0/gems/kramdown-1.4.0/lib/kramdown/converter/html.rb:259: warning: previous definition of convert_img was here
/home/indika/.rbenv/versions/2.1.1/lib/ruby/gems/2.1.0/gems/mail-2.5.4/lib/mail/network/delivery_methods/sendmail.rb:53: warning: shadowing outer local variable - to
/home/indika/.rbenv/versions/2.1.1/lib/ruby/gems/2.1.0/gems/factory_girl-4.4.0/lib/factory_girl/find_definitions.rb:16: warning: File.exists? is a deprecated name, use File.exist? instead
/home/indika/.rbenv/versions/2.1.1/lib/ruby/gems/2.1.0/gems/factory_girl-4.4.0/lib/factory_girl/find_definitions.rb:16: warning: File.exists? is a deprecated name, use File.exist? instead
/home/indika/.rbenv/versions/2.1.1/lib/ruby/gems/2.1.0/gems/factory_girl-4.4.0/lib/factory_girl/find_definitions.rb:16: warning: File.exists? is a deprecated name, use File.exist? instead
/home/indika/Documents/rails/news_app/spec/factories/news_articles.rb:1: warning: method redefined; discarding old ruby_iterator_code
/home/indika/Documents/rails/news_app/spec/factories/news_articles.rb:1: warning: previous definition of ruby_iterator_code was here
/home/indika/.rbenv/versions/2.1.1/lib/ruby/gems/2.1.0/gems/database_cleaner-1.3.0/lib/database_cleaner/configuration.rb:45: warning: instance variable @cleaners not initialized
/home/indika/.rbenv/versions/2.1.1/lib/ruby/gems/2.1.0/gems/rouge-1.5.1/lib/rouge/regex_lexer.rb:136: warning: instance variable @loaded not initialized
/home/indika/.rbenv/versions/2.1.1/lib/ruby/gems/2.1.0/gems/rouge-1.5.1/lib/rouge/regex_lexer.rb:136: warning: instance variable @loaded not initialized
/home/indika/.rbenv/versions/2.1.1/lib/ruby/gems/2.1.0/gems/rouge-1.5.1/lib/rouge/regex_lexer.rb:136: warning: instance variable @loaded not initialized
/home/indika/.rbenv/versions/2.1.1/lib/ruby/gems/2.1.0/gems/kramdown-1.4.0/lib/kramdown/parser/kramdown/link.rb:18: warning: character class has duplicated range: /[\s\n]+/
/home/indika/.rbenv/versions/2.1.1/lib/ruby/gems/2.1.0/gems/rouge-1.5.1/lib/rouge/regex_lexer.rb:136: warning: instance variable @loaded not initialized
/home/indika/.rbenv/versions/2.1.1/lib/ruby/gems/2.1.0/gems/capybara-2.4.1/lib/capybara/queries/text_query.rb:26: warning: instance variable @type not initialized
/home/indika/.rbenv/versions/2.1.1/lib/ruby/gems/2.1.0/gems/capybara-2.4.1/lib/capybara/queries/text_query.rb:26: warning: instance variable @type not initialized
/home/indika/.rbenv/versions/2.1.1/lib/ruby/gems/2.1.0/gems/capybara-2.4.1/lib/capybara/queries/text_query.rb:26: warning: instance variable @type not initialized
/home/indika/.rbenv/versions/2.1.1/lib/ruby/gems/2.1.0/gems/capybara-2.4.1/lib/capybara/queries/text_query.rb:26: warning: instance variable @type not initialized
./home/indika/.rbenv/versions/2.1.1/lib/ruby/gems/2.1.0/gems/capybara-2.4.1/lib/capybara/queries/text_query.rb:26: warning: instance variable @type not initialized
/home/indika/.rbenv/versions/2.1.1/lib/ruby/gems/2.1.0/gems/capybara-2.4.1/lib/capybara/queries/text_query.rb:26: warning: instance variable @type not initialized
.
Finished in 0.55369 seconds (files took 4.56 seconds to load)
2 examples, 0 failures
removing --warnings
option from your .rspec
file would do the trick
Guard with RSpec on Rails 4 giving a lot of warnings
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With