Pastie now auto-senses if line-wrap is a bad or good idea. Feedback?
## mark a section (Learn more)
describe "/layouts/application.html.haml" do def do_render render '/layouts/application.html.haml' end it "should have xml declaration" do do_render response.should have_text(%r{\A<\?xml version='1.0' encoding='utf-8' \?>}m) end it "should have xhtml transitional doctype" do do_render response.should have_text(%r{DOCTYPE html.*XHTML 1.0 Transitional//EN}) end it "should have html attributes" do do_render response.should have_tag("html[lang='en-US']") ### TODO: change to have_tag at some point. The xml namespace throws 'Invalid operation/value' ### Any suggestions? response.should have_text(%r{^<html.*xml:lang='en-US'}) end end
This paste will be private.
From the Design Piracy series on my blog: