Finish coverage of editing
This commit is contained in:
parent
62f3b10184
commit
9f260a691c
2 changed files with 12 additions and 0 deletions
|
@ -46,6 +46,16 @@ describe "Workouts" do
|
|||
|
||||
page.should have_content 'Workout updated'
|
||||
end
|
||||
|
||||
it "should not edit with bad data" do
|
||||
visit workouts_path
|
||||
find("#workout_#{@workout.id}").click_link 'Edit'
|
||||
|
||||
fill_in 'Date', :with => '2013-13-13'
|
||||
click_button 'Update Workout'
|
||||
|
||||
page.should have_content "Date is not a valid date"
|
||||
end
|
||||
end
|
||||
|
||||
describe "GET /workouts/new" do
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue