17 Apr '12, 7pm

This is my periodic beg for links to something close to as nice for making assertions about HTML text as assert_html:

Rubies: My quest to get the maximum coverage & diagnostics from the leanest possible tests has reached a new level. This is a Rails functional test on an HTML form: user = users(:Moses) get :edit_user, :id => user.id assert_xhtml do form :action => '/users' do fieldset do legend 'Personal Information' label 'First name' input :type => 'text', :name => 'user[first_name]' :value => user.first_name end end end That's all. The assertion expects a form with a given action, containing a fieldset, a legend, a label, and a populated text input field. The assertion forgives any other details, such as intervening structural tags, and complains if any required detail is missing, out of order, or ill-formed. You test HTML by writing an example of what you expect, excluding details you don't care about. When it fails, the assertion will print out your reference HTML, and your sample HT...

Full article: http://www.ruby-forum.com/topic/181145

Tweets

lw test

reelseo.com 20 Apr '12, 3am

New: Google Rich Snippet Tool Allows HTML Input & Product Snippets Go Global

New: Google Rich Snippet Tool Allows HTML Input...

searchengineland.com 17 Apr '12, 12pm

The first is they have added to the rich snippets testing a way to input your HTML and test the HTML before you make the H...

test: test

eco-chick.com 23 Apr '12, 1am

Earth Day Giveaway: BBC’s Frozen Planet Prize Package President Clinton and Trudie Styler Captivate at the Sustainable Ope...

New: test

eco-chick.com 23 Apr '12, 1am

Earth Day Giveaway: BBC’s Frozen Planet Prize Package President Clinton and Trudie Styler Captivate at the Sustainable Ope...

Why Links Matter

Why Links Matter

searchenginewatch.com 10 Apr '12, 1pm

Whenever I'm asked about what I do for a living, I say something like this: "you know those pieces of text that you can cl...