logux / logux_rails

Rails client for Logux server

Home Page:https://logux.org/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Fix spec warnings

ai opened this issue · comments

➤ b rake spec
/home/ai/.rubies/2.5.3/bin/ruby -I/home/ai/Dev/logux_rails/.bundle/gems/rspec-core-3.8.0/lib:/home/ai/Dev/logux_rails/.bundle/gems/rspec-support-3.8.0/lib /home/ai/Dev/logux_rails/.bundle/gems/rspec-core-3.8.0/exe/rspec --pattern spec/\*\*\{,/\*/\*\*\}/\*_spec.rb
[Coveralls] Set up the SimpleCov formatter.
[Coveralls] Using SimpleCov's default settings.
DEPRECATION WARNING: Leaving `ActiveRecord::ConnectionAdapters::SQLite3Adapter.represent_boolean_as_integer`
set to false is deprecated. SQLite databases have used 't' and 'f' to serialize
boolean values and must have old data converted to 1 and 0 (its native boolean
serialization) before setting this flag to true. Conversion can be accomplished
by setting up a rake task which runs

  ExampleModel.where("boolean_column = 't'").update_all(boolean_column: 1)
  ExampleModel.where("boolean_column = 'f'").update_all(boolean_column: 0)

for all models and all boolean columns, after which the flag must be set to
true by adding the following to your application.rb file:

  Rails.application.config.active_record.sqlite3.represent_boolean_as_integer = true
 (called from <top (required)> at /home/ai/Dev/logux_rails/spec/rails_helper.rb:13)
...............................WARNING: Using `expect { }.not_to raise_error(SpecificErrorClass)` risks false positives, since literally any other error would cause the expectation to pass, including those raised by Ruby (e.g. NoMethodError, NameError and ArgumentError), meaning the code you are intending to test may not even get reached. Instead consider using `expect { }.not_to raise_error` or `expect { }.to raise_error(DifferentSpecificErrorClass)`. This message can be suppressed by setting: `RSpec::Expectations.configuration.on_potential_false_positives = :nothing`. Called from /home/ai/Dev/logux_rails/spec/logux/model/updates_deprecator_spec.rb:18:in `block (3 levels) in <top (required)>'.
...................................

@wilddima warnings are not the Logux way :)