From a99d785ea08d6a69a06a3973f184f1279fbc2b72 Mon Sep 17 00:00:00 2001 From: Bryan Helmkamp Date: Mon, 7 Apr 2008 22:07:50 -0400 Subject: [PATCH] Fix button matching regexp --- lib/webrat/field.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/webrat/field.rb b/lib/webrat/field.rb index e021652..5eabc40 100644 --- a/lib/webrat/field.rb +++ b/lib/webrat/field.rb @@ -102,7 +102,7 @@ module Webrat class ButtonField < Field def matches_value?(value) - @element["value"] =~ /^\W*#{Regexp.escape(value.to_s)}\b*/i + @element["value"] =~ /^\W*#{Regexp.escape(value.to_s)}/i end def to_param