Skip to content

Commit 0f0d22a

Browse files
author
Cari Spruiell
committed
MC-1176: Create MFTF tests for configuring grid size
- update tests from CR feedback
1 parent 124c2f9 commit 0f0d22a

File tree

3 files changed

+23
-23
lines changed

3 files changed

+23
-23
lines changed

app/code/Magento/PageBuilder/Test/Mftf/Data/CmsConfigData.xml

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,4 +49,17 @@
4949
<data key="empty"/>
5050
<data key="errorMessage">Google Maps Style JSON is invalid. Please paste the valid JSON style.</data>
5151
</entity>
52+
<entity name="PageBuilderDefaultColumnGridSize" type="pagebuilder_default_grid_size">
53+
<data key="section">cms_pagebuilder</data>
54+
<data key="row">row_cms_pagebuilder_column_grid_default</data>
55+
<data key="label">Default Column Grid Size</data>
56+
<data key="invalidDefaultGridSizeErrorMessage">Default grid size must be less than the maximum grid size.</data>
57+
<data key="invalidDigitErrorMessage">Please enter a valid number in this field.</data>
58+
<data key="greaterThanOneErrorMessage">Please enter a number 2 or greater in this field.</data>
59+
</entity>
60+
<entity name="PageBuilderMaximumColumnGridSize" type="pagebuilder_max_grid_size">
61+
<data key="section">cms_pagebuilder</data>
62+
<data key="row">row_cms_pagebuilder_column_grid_max</data>
63+
<data key="label">Maximum Column Grid Size</data>
64+
</entity>
5265
</entities>

app/code/Magento/PageBuilder/Test/Mftf/Data/ColumnData.xml

Lines changed: 0 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -183,24 +183,11 @@
183183
<data key="gridSize_6">6</data>
184184
<data key="gridSize_32">32</data>
185185
<data key="gridSize_50">50</data>
186-
<data key="invalidDefaultGridSizeErrorMessage">Default grid size must be less than the maximum grid size.</data>
187-
<data key="invalidDigitErrorMessage">Please enter a valid number in this field.</data>
188-
<data key="greaterThanOneErrorMessage">Please enter a number 2 or greater in this field.</data>
189186
<data key="invalidNumberErrorMessage">Please enter a valid number.</data>
190187
<data key="minimumGridSizeErrorMessage">The minimum grid size supported is 2.</data>
191188
<data key="maximumGridSizeErrorMessage">The maximum grid size supported is</data>
192189
<data key="smallerThanTotalColumnsErrorMessage">Grid size cannot be smaller than the current total amount of columns, minus any empty columns.</data>
193190
</entity>
194-
<entity name="PageBuilderDefaultColumnGridSize" type="pagebuilder_default_grid_size">
195-
<data key="section">cms_pagebuilder</data>
196-
<data key="row">row_cms_pagebuilder_column_grid_default</data>
197-
<data key="label">Default Column Grid Size</data>
198-
</entity>
199-
<entity name="PageBuilderMaximumColumnGridSize" type="pagebuilder_max_grid_size">
200-
<data key="section">cms_pagebuilder</data>
201-
<data key="row">row_cms_pagebuilder_column_grid_max</data>
202-
<data key="label">Maximum Column Grid Size</data>
203-
</entity>
204191
<entity name="PageBuilderColumnDuplicate" type="pagebuilder_column">
205192
<data key="cannotDuplicateColumnErrorMessage">There is no free space within the column group to perform this action</data>
206193
</entity>

app/code/Magento/PageBuilder/Test/Mftf/Test/AdminPageBuilderColumnGridConfigurationTest.xml

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@
4141
<actionGroup ref="saveStoreConfigurationAndValidateFieldError" stepKey="saveStoreConfigurationAndValidateFieldError1">
4242
<argument name="inputFieldError" value="{{ContentManagementSection.ColumnGridDefaultInputField}}"/>
4343
<argument name="errorMessageSelector" value="{{ContentManagementSection.ColumnGridDefaultInputFieldError}}"/>
44-
<argument name="errorMessage" value="{{PageBuilderGridSize.invalidDefaultGridSizeErrorMessage}}"/>
44+
<argument name="errorMessage" value="{{PageBuilderDefaultColumnGridSize.invalidDefaultGridSizeErrorMessage}}"/>
4545
</actionGroup>
4646
<!-- Enter Valid Default Grid Size -->
4747
<comment userInput="Enter Valid Default Grid Size" stepKey="comment2"/>
@@ -58,7 +58,7 @@
5858
<actionGroup ref="saveStoreConfigurationAndValidateFieldError" stepKey="saveStoreConfigurationAndValidateFieldError2">
5959
<argument name="inputFieldError" value="{{ContentManagementSection.ColumnGridDefaultInputField}}"/>
6060
<argument name="errorMessageSelector" value="{{ContentManagementSection.ColumnGridDefaultInputFieldError}}"/>
61-
<argument name="errorMessage" value="{{PageBuilderGridSize.invalidDefaultGridSizeErrorMessage}}"/>
61+
<argument name="errorMessage" value="{{PageBuilderDefaultColumnGridSize.invalidDefaultGridSizeErrorMessage}}"/>
6262
</actionGroup>
6363
<!-- Enter Valid Maximum Grid Size -->
6464
<comment userInput="Enter Valid Maximum Grid Size" stepKey="comment4"/>
@@ -75,7 +75,7 @@
7575
<actionGroup ref="saveStoreConfigurationAndValidateFieldError" stepKey="saveStoreConfigurationAndValidateFieldError3">
7676
<argument name="inputFieldError" value="{{ContentManagementSection.ColumnGridDefaultInputField}}"/>
7777
<argument name="errorMessageSelector" value="{{ContentManagementSection.ColumnGridDefaultInputFieldError}}"/>
78-
<argument name="errorMessage" value="{{PageBuilderGridSize.invalidDigitErrorMessage}}"/>
78+
<argument name="errorMessage" value="{{PageBuilderDefaultColumnGridSize.invalidDigitErrorMessage}}"/>
7979
</actionGroup>
8080
<!-- Enter Invalid Default Grid Size Zero -->
8181
<comment userInput="Enter Invalid Default Grid Size Zero" stepKey="commentZeroNumber"/>
@@ -85,7 +85,7 @@
8585
<actionGroup ref="saveStoreConfigurationAndValidateFieldError" stepKey="saveStoreConfigurationAndValidateFieldError4">
8686
<argument name="inputFieldError" value="{{ContentManagementSection.ColumnGridDefaultInputField}}"/>
8787
<argument name="errorMessageSelector" value="{{ContentManagementSection.ColumnGridDefaultInputFieldError}}"/>
88-
<argument name="errorMessage" value="{{PageBuilderGridSize.greaterThanOneErrorMessage}}"/>
88+
<argument name="errorMessage" value="{{PageBuilderDefaultColumnGridSize.greaterThanOneErrorMessage}}"/>
8989
</actionGroup>
9090
<!-- Enter Invalid Default Grid Size One -->
9191
<comment userInput="Enter Invalid Default Grid Size One" stepKey="commentDefaultOne"/>
@@ -95,7 +95,7 @@
9595
<actionGroup ref="saveStoreConfigurationAndValidateFieldError" stepKey="saveStoreConfigurationAndValidateFieldErrorOne">
9696
<argument name="inputFieldError" value="{{ContentManagementSection.ColumnGridDefaultInputField}}"/>
9797
<argument name="errorMessageSelector" value="{{ContentManagementSection.ColumnGridDefaultInputFieldError}}"/>
98-
<argument name="errorMessage" value="{{PageBuilderGridSize.greaterThanOneErrorMessage}}"/>
98+
<argument name="errorMessage" value="{{PageBuilderDefaultColumnGridSize.greaterThanOneErrorMessage}}"/>
9999
</actionGroup>
100100
<!-- Enter Invalid Default Grid Size Float -->
101101
<comment userInput="Enter Invalid Default Grid Size Float" stepKey="commentFloatNumber"/>
@@ -105,7 +105,7 @@
105105
<actionGroup ref="saveStoreConfigurationAndValidateFieldError" stepKey="saveStoreConfigurationAndValidateFieldError5">
106106
<argument name="inputFieldError" value="{{ContentManagementSection.ColumnGridDefaultInputField}}"/>
107107
<argument name="errorMessageSelector" value="{{ContentManagementSection.ColumnGridDefaultInputFieldError}}"/>
108-
<argument name="errorMessage" value="{{PageBuilderGridSize.invalidDigitErrorMessage}}"/>
108+
<argument name="errorMessage" value="{{PageBuilderDefaultColumnGridSize.invalidDigitErrorMessage}}"/>
109109
</actionGroup>
110110
<!-- Restore Default Values for Default and Maximum Grid Size -->
111111
<comment userInput="Restore Default Values for Default and Maximum Grid Size" stepKey="comment5"/>
@@ -119,7 +119,7 @@
119119
<actionGroup ref="saveStoreConfigurationAndValidateFieldError" stepKey="saveStoreConfigurationAndValidateFieldError6">
120120
<argument name="inputFieldError" value="{{ContentManagementSection.ColumnGridMaxInputField}}"/>
121121
<argument name="errorMessageSelector" value="{{ContentManagementSection.ColumnGridMaxInputFieldError}}"/>
122-
<argument name="errorMessage" value="{{PageBuilderGridSize.invalidDigitErrorMessage}}"/>
122+
<argument name="errorMessage" value="{{PageBuilderDefaultColumnGridSize.invalidDigitErrorMessage}}"/>
123123
</actionGroup>
124124
<!-- Enter Invalid Max Default Grid Size Zero -->
125125
<comment userInput="Enter Invalid Max Default Grid Size Zero" stepKey="commentZeroNumberMax"/>
@@ -129,7 +129,7 @@
129129
<actionGroup ref="saveStoreConfigurationAndValidateFieldError" stepKey="saveStoreConfigurationAndValidateFieldError7">
130130
<argument name="inputFieldError" value="{{ContentManagementSection.ColumnGridMaxInputField}}"/>
131131
<argument name="errorMessageSelector" value="{{ContentManagementSection.ColumnGridMaxInputFieldError}}"/>
132-
<argument name="errorMessage" value="{{PageBuilderGridSize.greaterThanOneErrorMessage}}"/>
132+
<argument name="errorMessage" value="{{PageBuilderDefaultColumnGridSize.greaterThanOneErrorMessage}}"/>
133133
</actionGroup>
134134
<!-- Enter Invalid Max Default Grid Size One -->
135135
<comment userInput="Enter Invalid Max Default Grid Size One" stepKey="commentMaxOne"/>
@@ -139,7 +139,7 @@
139139
<actionGroup ref="saveStoreConfigurationAndValidateFieldError" stepKey="saveStoreConfigurationAndValidateFieldErrorMaxOne">
140140
<argument name="inputFieldError" value="{{ContentManagementSection.ColumnGridMaxInputField}}"/>
141141
<argument name="errorMessageSelector" value="{{ContentManagementSection.ColumnGridMaxInputFieldError}}"/>
142-
<argument name="errorMessage" value="{{PageBuilderGridSize.greaterThanOneErrorMessage}}"/>
142+
<argument name="errorMessage" value="{{PageBuilderDefaultColumnGridSize.greaterThanOneErrorMessage}}"/>
143143
</actionGroup>
144144
<!-- Enter Invalid Max Default Grid Size Float -->
145145
<comment userInput="Enter Invalid Max Default Grid Size Float" stepKey="commentFloatNumberMax"/>
@@ -149,7 +149,7 @@
149149
<actionGroup ref="saveStoreConfigurationAndValidateFieldError" stepKey="saveStoreConfigurationAndValidateFieldError8">
150150
<argument name="inputFieldError" value="{{ContentManagementSection.ColumnGridMaxInputField}}"/>
151151
<argument name="errorMessageSelector" value="{{ContentManagementSection.ColumnGridMaxInputFieldError}}"/>
152-
<argument name="errorMessage" value="{{PageBuilderGridSize.invalidDigitErrorMessage}}"/>
152+
<argument name="errorMessage" value="{{PageBuilderDefaultColumnGridSize.invalidDigitErrorMessage}}"/>
153153
</actionGroup>
154154
<click selector="{{ContentManagementSection.UseSystem('column_grid_max')}}" stepKey="restoreDefaultMaxGridSize" />
155155
<actionGroup ref="saveStoreConfiguration" stepKey="saveStoreConfiguration6"/>

0 commit comments

Comments
 (0)