2008-11-26 13:32:22 +00:00
|
|
|
require File.expand_path(File.dirname(__FILE__) + "/../../spec_helper")
|
|
|
|
|
|
|
|
|
2008-11-26 18:47:36 +00:00
|
|
|
describe "field_with_id" do
|
2008-11-26 13:32:22 +00:00
|
|
|
it "should work when there is a single quote in the ID" do
|
2008-11-27 05:27:13 +00:00
|
|
|
with_html <<-HTML
|
|
|
|
<html>
|
|
|
|
<form>
|
|
|
|
<input type="text" id="user's name">
|
|
|
|
</form>
|
|
|
|
</html>
|
|
|
|
HTML
|
2009-04-08 00:30:12 +00:00
|
|
|
|
2008-11-27 05:27:13 +00:00
|
|
|
field_with_id("user's name").id.should == "user's name"
|
2008-11-26 13:32:22 +00:00
|
|
|
end
|
|
|
|
end
|