[rspec-users] Test HTML output from Rails helper

Ashley Moran ashley.moran at patchspace.co.uk
Sat Oct 18 07:39:06 EDT 2008


On Oct 18, 2008, at 10:50 am, Scott Taylor wrote:

> No - that's not really an option.  The rails stack has no idea about  
> a DOM.
>
> One option, though, is to stub methods and use message  
> expectations.  For instance, if you had a helper like the following:


Hi Scott

Another option would be Hpricot[1], which makes manipulating HTML  
easier than CSV data.

Ashley

[1] http://code.whytheluckystiff.net/hpricot/

-- 
http://www.patchspace.co.uk/
http://aviewfromafar.net/



More information about the rspec-users mailing list