Removed unnecessary to_a calls, fixed deprecation warning and enabled query log in injection tests.