From 4b88bf80f1df0204467e667b9b1a804ccebf2d64 Mon Sep 17 00:00:00 2001 From: Miles Gould Date: Sun, 5 Jan 2014 13:20:07 +0000 Subject: [PATCH] Test for spec=any in harvests/new. --- spec/views/harvests/new.html.haml_spec.rb | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/spec/views/harvests/new.html.haml_spec.rb b/spec/views/harvests/new.html.haml_spec.rb index a09233fac..3db5bb804 100644 --- a/spec/views/harvests/new.html.haml_spec.rb +++ b/spec/views/harvests/new.html.haml_spec.rb @@ -10,8 +10,9 @@ describe "harvests/new" do assert_select "form", :action => harvests_path, :method => "post" do assert_select "select#harvest_crop_id", :name => "harvest[crop_id]" assert_select "select#harvest_plant_part_id", :name => "harvest[plant_part_id]" - assert_select "input#harvest_quantity", :name => "harvest[quantity]" - assert_select "input#harvest_weight_quantity", :name => "harvest[quantity]" +# some browsers interpret without a step as "integer" + assert_select "input#harvest_quantity[step=any]", :name => "harvest[quantity]" + assert_select "input#harvest_weight_quantity[step=any]", :name => "harvest[quantity]" assert_select "select#harvest_unit", :name => "harvest[unit]" assert_select "select#harvest_weight_unit", :name => "harvest[unit]" assert_select "textarea#harvest_description", :name => "harvest[description]"