Skip to content

Commit

Permalink
Per review, fix the tab spec
Browse files Browse the repository at this point in the history
Both tabs have the product name, so add check got the image on the
product details tab.
  • Loading branch information
rioug committed Sep 13, 2024
1 parent 3f6aaa7 commit 38721d9
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion spec/system/admin/products_v3/actions_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -493,13 +493,14 @@ def expect_other_columns_visible

within "#product-preview-modal" do
# Shop tab
expect(page).to have_selector("h3 a span", text: "Apples")
expect(page).to have_selector("h3", text: "Apples")
add_buttons = page.all(".add-variant")
expect(add_buttons.length).to eql(2)

# Product Details tab
find("a", text: "Product details").click # click_link doesn't work
expect(page).to have_selector("h3", text: "Apples")
expect(page).to have_selector(".product-img")

# Closing the modal
click_button "Close"
Expand Down

0 comments on commit 38721d9

Please sign in to comment.