Rails[1] provide access to the rendered template _without_ going 
through a browser, which can then be queried through XPath (if the 
template uses XHTML). It can also provide access to the attributes 
assigned to make the template. And even to check which template was 
used.

This is done by using mock requests and responses and works extremely 
well. It's considerably faster than going through HTTP for every 
request (which is often what slows down functional/acceptance testing 
and make them run for hours). It also gives you the opportunity to set 
and check conditions through code that might have been incovenient to 
generate through regular interfacing. Basically mocking.

So you have the opportunity to either XPath query the final XHTML or 
examine the variables that the template is supposed to be generated 
from. The latter is often a lot easier and catches most errors (by 
basically just testing controller and model) that computers are good at 
(comparing objects) and leaves the stuff that computers are less good 
at it human testing (does this look right?).

[1] Rails is that web-application framework that I've been talking 
about for far too long without sharing much code yet ;)
--
David Heinemeier Hansson,
http://www.instiki.org/      -- A No-Step-Three Wiki in Ruby
http://www.basecamphq.com/   -- Web-based Project Management
http://www.loudthinking.com/ -- Broadcasting Brain
http://www.nextangle.com/    -- Development & Consulting Services