Fix ActiveRecord all deprecation by replacing it with to_a
Remove deprecated test case