From be3127b265828237813a0d3ca84005add131586f Mon Sep 17 00:00:00 2001 From: John Bintz Date: Sat, 24 Nov 2012 10:19:13 -0500 Subject: [PATCH] ensure text comparisons --- lib/semantic_rails_view_helpers/capybara.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/semantic_rails_view_helpers/capybara.rb b/lib/semantic_rails_view_helpers/capybara.rb index 45fa9a4..e5f52c5 100644 --- a/lib/semantic_rails_view_helpers/capybara.rb +++ b/lib/semantic_rails_view_helpers/capybara.rb @@ -3,7 +3,7 @@ def find_attribute(name, value = nil) yield attribute, @inputs[name] if block_given? - attribute.text.should == value if value + attribute.text.should == value.to_s if value attribute end @@ -30,7 +30,7 @@ end def find_attributes(*attrs) attrs.each do |attr| - find_attribute(attr).text.should == @inputs[attr] + find_attribute(attr).text.should == @inputs[attr].to_s end end