Skip to content

Instantly share code, notes, and snippets.

@jim
Created October 1, 2008 16:45
Show Gist options
  • Save jim/14116 to your computer and use it in GitHub Desktop.
Save jim/14116 to your computer and use it in GitHub Desktop.
it "should wrap with a div" do
input = <<-HTML
<p>
In order to attain the greatest possible clearness,
let us return to our example of the railway carriage supposed
to be travelling uniformly.
</p>
HTML
output = <<-HTML
<div class="klass" id="div_3">
<p>
In order to attain the greatest possible clearness,
let us return to our example of the railway carriage supposed
to be travelling uniformly.
</p>
</div>
HTML
wrap_with_div(input, :class => 'klass', :id => 'div_3').should match_markup(output)
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment