23
23
<requiredEntity createDataKey =" createCategory" />
24
24
<field key =" price" >100</field >
25
25
</createData >
26
- <createData entity =" Simple_US_Customer" stepKey =" customer" />
26
+ <createData entity =" Simple_US_Customer" stepKey =" createCustomer" />
27
+ <createData entity =" DisableFlatRateShippingMethodConfig" stepKey =" disableFlatRate" />
28
+ <createData entity =" FreeShippinMethodConfig" stepKey =" enableFreeShippingMethod" />
29
+ <createData entity =" setFreeShippingSubtotal" stepKey =" setFreeShippingSubtotal" />
27
30
<actionGroup ref =" LoginAsAdmin" stepKey =" loginAsAdmin" />
28
- <actionGroup ref =" DisableFlatRate" stepKey =" disableFlatRate" />
29
- <actionGroup ref =" EnableFreeShipping" stepKey =" enableFreeShipping" >
30
- <argument name =" orderAmount" value =" 101" />
31
- </actionGroup >
32
- <actionGroup ref =" ClearCacheActionGroup" stepKey =" clearCacheBefore" />
31
+ <magentoCLI command =" cache:flush" stepKey =" flushCache" />
33
32
</before >
34
33
<after >
35
34
<deleteData createDataKey =" createCategory" stepKey =" deleteCategory" />
36
35
<deleteData createDataKey =" createProduct" stepKey =" deleteProduct" />
37
- <deleteData createDataKey =" customer" stepKey =" deleteCustomer" />
38
- <actionGroup ref =" EnableFlatRate" stepKey =" enableFlatRate" />
39
- <actionGroup ref =" DisableFreeShipping" stepKey =" disableFreeShipping" />
40
- <actionGroup ref =" ClearCacheActionGroup" stepKey =" clearCacheAfter" />
41
- <amOnPage url =" {{AdminLogoutPage.url}}" stepKey =" amOnLogoutPage" />
36
+ <deleteData createDataKey =" createCustomer" stepKey =" deleteCustomer" />
37
+ <createData entity =" FlatRateShippingMethodConfig" stepKey =" enableFlatRate" />
38
+ <createData entity =" FreeShippinMethodDefault" stepKey =" disableFreeShippingMethod" />
39
+ <createData entity =" setFreeShippingSubtotalToDefault" stepKey =" setFreeShippingSubtotalToDefault" />
40
+ <actionGroup ref =" logout" stepKey =" logout" />
41
+ <magentoCLI command =" cache:flush" stepKey =" flushCache2" />
42
42
</after >
43
-
43
+ <!-- Create new order with existing customer -->
44
44
<actionGroup ref =" navigateToNewOrderPageExistingCustomer" stepKey =" goToCreateOrderPage" >
45
- <argument name =" customer" value =" Simple_US_Customer " />
45
+ <argument name =" customer" value =" $$createCustomer$$ " />
46
46
</actionGroup >
47
-
48
- <!-- Admin creates order-->
47
+ <!-- Add product to order-->
49
48
<actionGroup ref =" addSimpleProductToOrder" stepKey =" addProductToOrder" >
50
- <argument name =" product" value =" SimpleProduct " />
49
+ <argument name =" product" value =" $$createProduct$$ " />
51
50
</actionGroup >
52
51
53
52
<click selector =" {{AdminOrderFormPaymentSection.header}}" stepKey =" unfocus" />
54
53
<waitForPageLoad stepKey =" waitForJavascriptToFinish" />
55
- <click selector =" {{AdminOrderFormPaymentSection.getShippingMethods}}" stepKey =" clickShippingMethods" />
54
+ <!-- Click *Get shipping methods and rates* and see that Free Shipping is absent-->
55
+ <click selector =" {{AdminOrderFormPaymentSection.getShippingMethods}}" stepKey =" clickGetShippingMehods" />
56
56
<dontSeeElement selector =" {{AdminOrderFormPaymentSection.freeShippingOption}}" stepKey =" seeAbsentFreeShipping" />
57
-
58
- <!-- Submit Order and verify information-->
57
+ <!-- Submit Order and verify that Order isn't placed-->
59
58
<click selector =" {{AdminOrderFormActionSection.SubmitOrder}}" stepKey =" clickSubmitOrder" />
60
59
61
- <dontSeeElement selector =" {{AdminOrderDetailsMessagesSection .successMessage}}" stepKey =" seeSuccessMessage" />
62
- <seeElement selector =" {{AdminOrderDetailsMessagesSection .errorMessage}}" stepKey =" seeErrorMessage" />
60
+ <dontSeeElement selector =" {{AdminMessagesSection .successMessage}}" stepKey =" seeSuccessMessage" />
61
+ <seeElement selector =" {{AdminMessagesSection .errorMessage}}" stepKey =" seeErrorMessage" />
63
62
</test >
64
63
</tests >
0 commit comments