I wonder what the benchmark for few rails methods would look like. Anyone got a website that can run custom methods?:
User.count
#=> 1000000 (Let's say about that)
u = User.where(account_id: 5)
u.count
#=> 100000
u.map |a| a.account_id = 6 end
Is there a way to test this sort of benchmark? How slow or fast is that iteration?
You can use ruby benchmark module for this kind of test