Changed the test to be compitable with the rails 4