Ruby in Rails

Ruby, Rails, Ruby on Rails Tutorials

  • Home
  • Rails
  • Ruby
  • About
GitHub icon LinkedIn icon
Subscribe
Rails

Rails test jbuilder json response with rspec

Testing jbuilder response in rspec integration tests requires an extra helper method to be included in test. Requests in integration tests do not render json response unless we include render_views helper.

Akshay Mohite Akshay Mohite 3 min read
Rails

Rails counter cache associations

Rails provides an ability to cache count of associated table records. This gives an edge that avoids querying to get number of records of associated table.

Akshay Mohite Akshay Mohite 3 min read
Rails

Rails 6.1 ActiveRecord deprecates update_attributes methods

Rails 6.1 ActiveRecord deprecates update_attributes method calls. This method was renamed to update method.

Akshay Mohite Akshay Mohite 1 min read
Rails

Rails changed behavior of attribute_changed in callbacks

Rails changed behavior of attribute_changed? in after and before callbacks. Older versions will throw deprecation warnings indicating which methods to use instead.

Akshay Mohite Akshay Mohite 2 min read
Rails

Rails 6 supports Multi Environment Credentials

Rails 6 adds support for multi environment credentials. Rails 5.2 includes encrypted credentials for Rails applications.

Akshay Mohite Akshay Mohite 1 min read
Rails

Rails 6 faster & memory efficient Date#advance

Rails 6 includes a change in Date#advance method that optimised memory usage and time required to perform advance operation.

Akshay Mohite Akshay Mohite 4 min read
« Newer Posts Page 6 of 23 Older Posts »
Ruby in Rails © 2023
Latest Posts Github Twitter LinkedIn

Subscribe to Ruby in Rails

Stay up to date! Get all the latest posts delivered straight to your inbox