Avoid unnecessary extra page visit

The second spec example below has to load the page after creating a record, so it's not helpful to load it here.
This commit is contained in:
David Cook
2026-04-01 14:48:18 +11:00
parent cacb62f58c
commit 15abea51ab

View File

@@ -328,12 +328,10 @@ RSpec.describe 'As an enterprise user, I can perform actions on the products scr
}
describe "Actions columns (delete)" do
before do
visit admin_products_url
end
it "shows an actions menu with a delete link when clicking on icon for product. " \
"doesn't show delete link for the single variant" do
visit admin_products_url
within product_selector do
page.find(".vertical-ellipsis-menu").click
expect(page).to have_css(delete_option_selector)