What should I do testing for an old application?

I got this Ruby on Rails application with incomplete testing, (many
controllers or views do not have unit test at all).

Should I go back to write all unit test for each of controller or
view, then do integration test? Or I just forget about all of them,
keep going ahead with my new functions with my new unit test?

My concerns here are: I also need to upgrade Ruby and Rails, or re-
factoring the program. How can I test to make sure the whole
application will be running just fine after all the upgrading and re-
factoring?

Thanks,
Li

Suki wrote:

I got this Ruby on Rails application with incomplete testing, (many
controllers or views do not have unit test at all).

Should I go back to write all unit test for each of controller or
view, then do integration test? Or I just forget about all of them,
keep going ahead with my new functions with my new unit test?

My concerns here are: I also need to upgrade Ruby and Rails, or re-
factoring the program. How can I test to make sure the whole
application will be running just fine after all the upgrading and re-
factoring?

Write the tests before upgrading and refactoring. The tests will tell
you if the changes break anything. That’s what they’re for!

(BTW, integration tests are probably less useful than Cucumber
features.)

Thanks,
Li

Best,

Marnen Laibow-Koser
http://www.marnen.org
[email protected]

Thank you very much! I was thinking about it, but afraid to waste too
much of my time. Your response confirm my thinking. Great. I just go
ahead do it.

On Oct 28, 1:53 pm, Marnen Laibow-Koser <rails-mailing-l…@andreas-