Maintenance: Prefer selector from used variable over hardcoded string.

This commit is contained in:
Mantas Masalskis 2019-09-16 12:34:26 +02:00 committed by Thorsten Eckel
parent 6000b9f5c1
commit 89c74ba829

View file

@ -41,7 +41,7 @@ RSpec.describe 'Ticket Update', type: :system do
within(:active_content) do
# update should work now
find('.edit [name=internal_name1]').select('name 2')
find(".edit [name=#{attribute.name}]").select('name 2')
click('.js-attributeBar .js-submit')
expect(page).to have_no_css('.js-submitDropdown .js-submit[disabled]', wait: 2)
end
@ -85,7 +85,7 @@ RSpec.describe 'Ticket Update', type: :system do
},
})
# refresh browser to get macro accessable
# refresh browser to get macro accessible
refresh
# create a new ticket and attempt to update its state without the required select attribute