Need a push in the write direction, to write my first functional test in Rails?

Posted by Jason on Stack Overflow See other posts from Stack Overflow or by Jason
Published on 2010-05-19T03:27:18Z Indexed on 2010/05/19 3:30 UTC
Read the original article Hit count: 207

Hi,

I've read quiet a bit of documentation over the last few days about testing in Rails, I'm sitting down to write my first real test and not 100% sure how to tie what I have learned together to achieve the following functional test (testing a controller)

I need to send a GET request to a URL and pass 3 parameters (simple web-service), if the functionality works the keyword "true" is simply returned, otherwise the keyword "false" is returned - its in only value returned & not contained in any , or other tags.

The test should assert that if "true" is returned the test is successful.

This is probably very simple so apologies for such a non-challenging question.

If anyone could point me in the write direction on how I can get started, particularly how I can test the response, I'd be very grateful!

Thanks!

© Stack Overflow or respective owner

Related posts about rails

Related posts about ruby-on-rails