|
8 | 8 |
|
9 | 9 | <tests xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" |
10 | 10 | xsi:noNamespaceSchemaLocation="urn:magento:mftf:Test/etc/testSchema.xsd"> |
11 | | - <test name="SATest"> |
| 11 | + <test name="AdminVerifyCustomerGroupNotLoggedInForGuestOrderTest"> |
12 | 12 | <annotations> |
13 | | - <features value="OnePageCheckout"/> |
14 | | - <stories value="OnePageCheckout within Offline Payment Methods"/> |
15 | | - <title value="OnePageCheckout as a customer with non-existent customer group assigned to the quote"/> |
16 | | - <description value="Checkout as a customer with non-existent customer group assigned to the quote"/> |
| 13 | + <features value="Checkout"/> |
| 14 | + <stories value="Order view shows customer group for guest orders"/> |
| 15 | + <title value="Admin sees 'NOT LOGGED IN' customer group on guest order view"/> |
| 16 | + <description value="Place a guest order on storefront and verify the customer group is NOT LOGGED IN"/> |
17 | 17 | <severity value="AVERAGE"/> |
18 | | - <testCaseId value="MC-36385"/> |
| 18 | + <testCaseId value="AC-6430"/> |
19 | 19 | <group value="checkout"/> |
20 | 20 | </annotations> |
21 | 21 | <before> |
22 | | - <!-- Create Simple Product --> |
23 | | - <createData entity="SimpleProduct2" stepKey="createSimpleProduct"/> |
| 22 | + <!-- Precondition Step 1:Create Simple Product and Customer --> |
| 23 | + <createData entity="SimpleProduct" stepKey="createSimpleProduct"/> |
24 | 24 | <createData entity="Simple_US_Customer" stepKey="createCustomer"/> |
25 | | - |
26 | | - |
27 | | - |
28 | 25 | </before> |
29 | 26 | <after> |
30 | 27 | <!-- Admin log out --> |
31 | 28 | <actionGroup ref="AdminLogoutActionGroup" stepKey="logout"/> |
32 | | - |
33 | 29 | <!-- Customer log out --> |
34 | 30 | <actionGroup ref="StorefrontCustomerLogoutActionGroup" stepKey="customerLogout"/> |
35 | | - |
36 | 31 | <!-- Delete created product --> |
37 | 32 | <deleteData createDataKey="createSimpleProduct" stepKey="deleteSimpleProduct"/> |
38 | | - |
39 | 33 | <!-- Delete customer --> |
40 | 34 | <deleteData createDataKey="createCustomer" stepKey="deleteCustomer"/> |
41 | 35 | </after> |
42 | | - |
43 | | - <!-- Login as customer --> |
44 | | - |
45 | | - <actionGroup ref="CliIndexerReindexActionGroup" stepKey="performReindex"> |
| 36 | + <!-- Step 1: Navigate to Frontend > place an order through check money with guest checkout. --> |
| 37 | + <actionGroup ref="CliIndexerReindexActionGroup" stepKey="reindex"> |
46 | 38 | <argument name="indices" value=""/> |
47 | 39 | </actionGroup> |
48 | 40 | <!-- Add Simple Product to cart --> |
49 | | - <amOnPage url="{{StorefrontProductPage.url($$createSimpleProduct.custom_attributes[url_key]$$)}}" stepKey="navigateToSimpleProductPage"/> |
| 41 | + <actionGroup ref="StorefrontOpenProductPageActionGroup" stepKey="openProductPage"> |
| 42 | + <argument name="productUrl" value="$$createSimpleProduct.sku$$"/> |
| 43 | + </actionGroup> |
50 | 44 | <waitForPageLoad stepKey="waitForSimpleProductPageLoad"/> |
51 | | - |
52 | | - |
53 | | - <!-- Delete customer group --> |
54 | | - |
55 | 45 | <actionGroup ref="StorefrontAddProductToCartActionGroup" stepKey="addProductToCart"> |
56 | 46 | <argument name="product" value="$$createSimpleProduct$$"/> |
57 | 47 | <argument name="productCount" value="1"/> |
58 | 48 | </actionGroup> |
59 | 49 | <actionGroup ref="GoToCheckoutFromMinicartActionGroup" stepKey="goToCheckoutFromMinicart"/> |
| 50 | + <!-- Guest Checkout Process--> |
60 | 51 | <actionGroup ref="GuestCheckoutFillingShippingSectionActionGroup" stepKey="guestCheckoutFillingShippingSection"> |
61 | 52 | <argument name="customerVar" value="CustomerEntityOne"/> |
62 | 53 | <argument name="customerAddressVar" value="CustomerAddressSimple"/> |
63 | 54 | </actionGroup> |
64 | 55 | <actionGroup ref="CheckoutSelectCheckMoneyOrderPaymentActionGroup" stepKey="guestSelectCheckMoneyOrderPayment"/> |
65 | | - |
66 | | - |
67 | 56 | <actionGroup ref="ClickPlaceOrderActionGroup" stepKey="checkoutPlaceOrder"/> |
68 | 57 | <grabTextFrom selector="{{CheckoutSuccessMainSection.orderNumber}}" stepKey="grabOrderNumber"/> |
69 | | - |
70 | | - <!--Check subtotal in created order--> |
| 58 | + <!-- Step 2: Navigate to admin panel > sales > orders > check customer group --> |
71 | 59 | <actionGroup ref="AdminLoginActionGroup" stepKey="loginAsAdmin"/> |
72 | 60 | <actionGroup ref="FilterOrderGridByIdActionGroup" stepKey="filterOrderById"> |
73 | 61 | <argument name="orderId" value="$grabOrderNumber"/> |
74 | 62 | </actionGroup> |
75 | | - |
76 | 63 | <actionGroup ref="AdminOrderGridClickFirstRowActionGroup" stepKey="clickOrderRow"/> |
77 | | -<!-- <actionGroup ref="AdminOrderGridClickFirstRowActionGroup" stepKey="clickOrderRow"/>--> |
78 | | - |
79 | 64 | <waitForElementVisible selector="{{AdminOrderDetailsInformationSection.customerGroup}}" stepKey="waitForCustomerGroupFieldOnOrderView"/> |
80 | | - <waitForText selector="{{AdminOrderDetailsInformationSection.customerGroup}}" userInput="NOT LOGGED IN" stepKey="assertCustomerGroupIsNotLoggedIn"/> |
81 | | - |
82 | | - |
83 | | - |
| 65 | + <waitForText selector="{{AdminOrderDetailsInformationSection.customerGroup}}" userInput="{{SimpleCatalogPriceRule.customerGroups}}" stepKey="assertCustomerGroupIsNotLoggedIn"/> |
84 | 66 | </test> |
85 | 67 | </tests> |
0 commit comments