mirror of
https://github.com/Growstuff/growstuff.git
synced 2026-05-06 14:56:35 -04:00
@@ -54,6 +54,10 @@ FactoryGirl.define do
|
||||
factory :uppercasecrop do
|
||||
name "Swiss chard"
|
||||
end
|
||||
|
||||
factory :autoloaded_crop do
|
||||
creator "cropbot"
|
||||
end
|
||||
|
||||
#for testing crop request
|
||||
factory :crop_request do
|
||||
|
||||
@@ -40,6 +40,14 @@ feature "Planting a crop", :js => true do
|
||||
expect(page).to have_content "Planting was successfully created"
|
||||
expect(page).to have_content "maize"
|
||||
end
|
||||
|
||||
scenario "Editing a planting to add details" do
|
||||
visit planting_path(planting)
|
||||
click_link "Edit"
|
||||
fill_in "Tell us more about it", :with => "Some extra notes"
|
||||
click_button "Save"
|
||||
expect(page).to have_content "Planting was successfully updated"
|
||||
end
|
||||
|
||||
scenario "Marking a planting as finished" do
|
||||
fill_autocomplete "crop", :with => "mai"
|
||||
|
||||
Reference in New Issue
Block a user