Fix Dangerous query method warning
Fix Dangerous query method warning

Warning:
 >DEPRECATION WARNING: Dangerous query method (method whose arguments are used as raw SQL) called with non-attribute argument(s): "`when` DESC, id DESC". Non-attribute arguments will be disallowed in Rails 6.0. This method should not be called with user-provided values, such as request parameters or model attributes. Known-safe values can be passed by wrapping them in Arel.sql(). (called from test_observation_all at /vagrant/mushroom-observer/test/models/query_test.rb:2392)

Solution: use ActiveRecord::QueryMethods instead of raw SQL

MushroomObserver/mushroom-observer,MushroomObserver/mushroom-observer,JoeCohen/mushroom-observer,pellaea/mushroom-observer,pellaea/mushroom-observer,pellaea/mushroom-observer,pellaea/mushroom-observer,JoeCohen/mushroom-observer,MushroomObserver/mushroom-observer,MushroomObserver/mushroom-observer,JoeCohen/mushroom-observer,MushroomObserver/mushroom-observer,JoeCohen/mushroom-observer,MushroomObserver/mushroom-observer,pellaea/mushroom-observer,MushroomObserver/mushroom-observer,pellaea/mushroom-observer,pellaea/mushroom-observer,JoeCohen/mushroom-observer,JoeCohen/mushroom-observer,JoeCohen/mushroom-observer