Hide title field for primary progress bars

These bars don't have a title.
This commit is contained in:
Javi Martín
2019-01-04 16:26:35 +01:00
committed by decabeza
parent c5d32c5ab9
commit dfdf0b0636
2 changed files with 18 additions and 0 deletions

View File

@@ -34,6 +34,8 @@ shared_examples "progressable" do |factory_name, path_name|
select "Primary", from: "Type"
expect(page).not_to have_field "Title"
fill_in "Current progress", with: 43
click_button "Create Progress bar"
@@ -65,6 +67,9 @@ shared_examples "progressable" do |factory_name, path_name|
visit path
within("#progress_bar_#{bar.id}") { click_link "Edit" }
expect(page).to have_field "Current progress"
expect(page).not_to have_field "Title"
fill_in "Current progress", with: 44
click_button "Update Progress bar"