mirror of
https://github.com/openfoodfoundation/openfoodnetwork
synced 2026-01-26 20:56:48 +00:00
28 lines
770 B
Ruby
28 lines
770 B
Ruby
# frozen_string_literal: true
|
|
|
|
require "spec_helper"
|
|
|
|
feature '
|
|
As an admin
|
|
I want to manage product properties
|
|
' do
|
|
include AuthenticationWorkflow
|
|
|
|
scenario "creating and editing a property" do
|
|
login_to_admin_section
|
|
visit spree.admin_properties_path
|
|
|
|
click_link 'New Property'
|
|
fill_in 'property_name', with: 'New property!'
|
|
fill_in 'property_presentation', with: 'New property presentation!'
|
|
click_button 'Create'
|
|
expect(page).to have_content 'New property!'
|
|
|
|
page.find('td.actions a.icon-edit').click
|
|
expect(page).to have_field 'property_name', with: 'New property!'
|
|
fill_in 'property_name', with: 'New changed property!'
|
|
click_button 'Update'
|
|
expect(page).to have_content 'New changed property!'
|
|
end
|
|
end
|