|
3 | 3 | import static com.shopify.checkoutkitreactnative.TestFixtures.createTestCart; |
4 | 4 |
|
5 | 5 | import androidx.activity.ComponentActivity; |
| 6 | +import androidx.annotation.NonNull; |
| 7 | +import androidx.annotation.Nullable; |
6 | 8 |
|
7 | 9 | import com.facebook.react.bridge.JavaOnlyMap; |
8 | 10 | import com.facebook.react.bridge.ReactApplicationContext; |
|
14 | 16 | import com.shopify.checkoutsheetkit.Preloading; |
15 | 17 | import com.shopify.checkoutsheetkit.ColorScheme; |
16 | 18 | import com.shopify.checkoutsheetkit.Authentication; |
| 19 | +import com.shopify.checkoutsheetkit.lifecycleevents.CartPaymentInstrument; |
17 | 20 | import com.shopify.checkoutsheetkit.lifecycleevents.CheckoutCompleteEvent; |
18 | 21 | import com.shopify.checkoutsheetkit.lifecycleevents.CheckoutStartEvent; |
19 | 22 | import com.shopify.checkoutsheetkit.lifecycleevents.Cart; |
|
44 | 47 | import android.content.Context; |
45 | 48 |
|
46 | 49 | import java.util.ArrayList; |
| 50 | +import java.util.Collection; |
| 51 | +import java.util.Collections; |
| 52 | +import java.util.Iterator; |
| 53 | +import java.util.List; |
| 54 | +import java.util.ListIterator; |
47 | 55 |
|
48 | 56 | @RunWith(MockitoJUnitRunner.class) |
49 | 57 | public class ShopifyCheckoutSheetKitModuleTest { |
@@ -543,18 +551,19 @@ public void testCompleteConfigurationAndEventFlow() { |
543 | 551 |
|
544 | 552 | private Cart buildMinimalCart(String cartId, String amount, String currencyCode) { |
545 | 553 | return new Cart( |
546 | | - cartId, |
547 | | - new ArrayList<>(), // lines |
548 | | - new CartCost( |
549 | | - new Money(amount, currencyCode), |
550 | | - new Money(amount, currencyCode) |
551 | | - ), |
552 | | - new CartBuyerIdentity(null, null, null, null), |
553 | | - new ArrayList<>(), // deliveryGroups |
554 | | - new ArrayList<>(), // discountCodes |
555 | | - new ArrayList<>(), // appliedGiftCards |
556 | | - new ArrayList<>(), // discountAllocations |
557 | | - new CartDelivery(new ArrayList<>()) |
| 554 | + cartId, |
| 555 | + new ArrayList<>(), // lines |
| 556 | + new CartCost( |
| 557 | + new Money(amount, currencyCode), |
| 558 | + new Money(amount, currencyCode) |
| 559 | + ), |
| 560 | + new CartBuyerIdentity(null, null, null, null), |
| 561 | + new ArrayList<>(), // deliveryGroups |
| 562 | + new ArrayList<>(), // discountCodes |
| 563 | + new ArrayList<>(), // appliedGiftCards |
| 564 | + new ArrayList<>(), // discountAllocations |
| 565 | + new CartDelivery(new ArrayList<>()), |
| 566 | + new ArrayList<>() { } // paymentInstruments |
558 | 567 | ); |
559 | 568 | } |
560 | 569 |
|
|
0 commit comments