Skip to content

Commit

Permalink
12777: add specs
Browse files Browse the repository at this point in the history
  • Loading branch information
chahmedejaz committed Sep 2, 2024
1 parent 08b30e1 commit e290164
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions spec/system/admin/invoice_print_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -300,6 +300,21 @@
expect(page).to have_content "Total (Excl. tax): $1,458.67"
end
end

context "Line item with variant having variant_unit as 'items'" do
before do
line_item1.variant.update_columns(variant_unit: "items", display_as: "1 bucket")
login_as_admin
visit spree.print_admin_order_path(order1, params: url_params)
convert_pdf_to_page
end

it 'should have correct display as value' do
# first line item
expect(page).to have_content Spree::Product.first.name.to_s
expect(page).to have_content "(1 bucket)" # display as
end
end
end

context "added" do
Expand Down

0 comments on commit e290164

Please sign in to comment.