Skip to content

Instantly share code, notes, and snippets.

@cored
Created November 5, 2018 16:55
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save cored/65d99502897e556d95b24b7232836883 to your computer and use it in GitHub Desktop.
Save cored/65d99502897e556d95b24b7232836883 to your computer and use it in GitHub Desktop.
context "with different shipping preferences" do
let(:shipment1) { build(:shipment, shipping_preference: "parcel", products: [product_a]) }
let(:shipment2) { build(:shipment, shipping_preference: "courier", products: [product_b]) }
it "does not swap for the bundling product" do
expect(shipments_out).to match_array(shipments_in)
expect(products_skus_in_shipments(shipments_out)).to match_array(
[
[product_a.sku],
[product_b.sku],
]
)
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment