SQLTerminal.app
now available

XPath.app
now available
Want fresh tech tips in your inbox?

Change the Default Controller Name in Rails Functional Tests

       

Rails will infer the controller you want to test from the class name of the test case. For example...

class PeopleControllerTest < ActionController::TestCase
end

will test the app/controllers/people_controller.rb.

To change this is trivial. Use the "test" method inside your test case.

class PeopleControllerImportContactsFromGmailTest < ActionController::TestCase
     tests PeopleController
end

You might want to do this to separate actions in your controller by file in your test suite.

Tagged w/ #rails #ruby on rails #testing #functional tests #configuration

Apps I've Built

XPath Expression Editor
Practice and improve your XPath skills with XPath Editor
Click to buy on the App Store
Photo Location Changer
Easily change the location on your photos and videos
Click here for more info about the app
Photo Date Changer
Easily change the dates and times on your photos and videos
Click here for more info about the app
VocabReminder
English dictionary with notifications so you won't forget what you're studying!
Click here for more info about the app
VocabQuiz
The app that quizzes and scores you on your vocabulary!
Click here for more info about the app