@sap-ux/ui5-test-writer 1.16.3 → 1.18.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -15,11 +15,12 @@
15
15
  * ╚═══════════════════════════════════════════════════════════════════════╝ *
16
16
  ******************************************************************************/
17
17
 
18
+ <%_ const needsSortOrder = startLR && ((textAnnotationColumns && textAnnotationColumns.length > 0) || (tabs && tabs.some(function(tab) { return tab.textAnnotationColumns && tab.textAnnotationColumns.length > 0; }))); -%>
18
19
  sap.ui.define([
19
20
  "sap/ui/test/opaQunit",
20
- "./pages/JourneyRunner"<% if (textAnnotationColumns && textAnnotationColumns.length > 0) { %>,
21
+ "./pages/JourneyRunner"<% if (needsSortOrder) { %>,
21
22
  "sap/ui/core/library"<% } %>
22
- ], function (opaTest, runner<% if (textAnnotationColumns && textAnnotationColumns.length > 0) { %>, coreLibrary<% } %>) {
23
+ ], function (opaTest, runner<% if (needsSortOrder) { %>, coreLibrary<% } %>) {
23
24
  "use strict";
24
25
 
25
26
  function journey() {
@@ -77,34 +78,166 @@ sap.ui.define([
77
78
  // });
78
79
 
79
80
  <%_ if (tabs && tabs.length > 0) { -%>
80
- opaTest("Check table columns and actions per tab", function (Given, When, Then) {
81
- <%_ tabs.forEach(function(tab) { _%>
81
+ <%_ tabs.forEach(function(tab) { -%>
82
+ /// View "<%- tab.key %>" ///
83
+ <%_ if (tab.createButton.visible && !isALP) { -%>
84
+ opaTest(<%- JSON.stringify("Check the create button in view " + tab.key) %>, function (Given, When, Then) {
82
85
  When.onThe<%- startLR%>Generated.iGoToView({ key: "<%- tab.key %>" });
83
- <%_ if (tab.createButton.visible && !isALP) { _%>
84
86
  Then.onThe<%- startLR%>Generated.onTable("<%- tab.key %>").iCheckCreate({ visible: true });
85
- // When.onThe<%- startLR%>Generated.onTable("<%- tab.key %>").iPressCreate();
87
+ // When.onThe<%- startLR%>Generated.onTable("<%- tab.key %>").iExecuteCreate();
88
+ });
89
+
90
+ <%_ } -%>
91
+ <%_ if (tab.deleteButton.visible) { -%>
92
+ opaTest(<%- JSON.stringify("Check the delete button in view " + tab.key) %>, function (Given, When, Then) {
93
+ When.onThe<%- startLR%>Generated.iGoToView({ key: "<%- tab.key %>" });
94
+ <%_ const deleteIsSelectionGated = tab.deleteButton.enabled === true; _%>
95
+ <%_ if (deleteIsSelectionGated) { _%>
96
+ Then.onThe<%- startLR%>Generated.onTable("<%- tab.key %>").iCheckDelete({ visible: true, enabled: false });
97
+ <%_ if (!hideFilterBar) { _%>
98
+ // Populate the table and select a row so Delete becomes enabled.
99
+ When.onThe<%- startLR%>Generated.onFilterBar().iExecuteSearch();
86
100
  <%_ } _%>
87
- <%_ if (tab.deleteButton.visible) { _%>
88
- // When.onThe<%- startLR%>Generated.onTable("<%- tab.key %>").iPressDelete();
101
+ When.onThe<%- startLR%>Generated.onTable("<%- tab.key %>").iSelectRows(0);
102
+ Then.onThe<%- startLR%>Generated.onTable("<%- tab.key %>").iCheckDelete({ visible: true, enabled: true });
103
+ // When.onThe<%- startLR%>Generated.onTable("<%- tab.key %>").iExecuteDelete();
104
+ // Deselect the row so the following actions start with an empty selection.
105
+ When.onThe<%- startLR%>Generated.onTable("<%- tab.key %>").iSelectRows(0);
106
+ <%_ } else { _%>
89
107
  Then.onThe<%- startLR%>Generated.onTable("<%- tab.key %>").iCheckDelete({ visible: true });
108
+ // When.onThe<%- startLR%>Generated.onTable("<%- tab.key %>").iExecuteDelete();
90
109
  <%_ } _%>
91
- <%_ tab.toolBarActions.forEach(function(item) { _%>
92
- <%_ if (item.visible) { _%>
93
- <%_ if (item.custom) { _%>
110
+ });
111
+
112
+ <%_ } -%>
113
+ <%_ tab.toolBarActions.forEach(function(item) { -%>
114
+ <%_ if (item.visible) { -%>
115
+ opaTest(<%- JSON.stringify("Check the " + item.label + " action in view " + tab.key) %>, function (Given, When, Then) {
116
+ When.onThe<%- startLR%>Generated.iGoToView({ key: "<%- tab.key %>" });
117
+ <%_ if (item.menuActions) { _%>
118
+ <%_ if (item.splitButton) { _%>
119
+ // "<%- item.label %>" is a split menu button (has a default action); its drop-down cannot be opened via the test API, so its menu items are not checked. Pressing it triggers the default action:
120
+ Then.onThe<%- startLR%>Generated.onTable("<%- tab.key %>").iCheckAction("<%- item.label %>");
121
+ // When.onThe<%- startLR%>Generated.onTable("<%- tab.key %>").iExecuteAction("<%- item.label %>");
122
+ <%_ } else { _%>
123
+ Then.onThe<%- startLR%>Generated.onTable("<%- tab.key %>").iCheckAction("<%- item.label %>");
124
+ When.onThe<%- startLR%>Generated.onTable("<%- tab.key %>").iExecuteAction("<%- item.label %>");
125
+ <%_ item.menuActions.forEach(function(menuAction) { _%>
126
+ <%_ if (menuAction.visible) { _%>
127
+ Then.onThe<%- startLR%>Generated.onTable("<%- tab.key %>").iCheckMenuAction("<%- menuAction.label %>");
128
+ // When.onThe<%- startLR%>Generated.onTable("<%- tab.key %>").iExecuteMenuAction("<%- menuAction.label %>");
129
+ <%_ } _%>
130
+ <%_ }); _%>
131
+ <%_ } _%>
132
+ <%_ } else if (item.custom) { _%>
94
133
  <%_ if (item.labelUnresolved) { _%>
95
134
  // TODO: label is an unresolved i18n key; replace with the rendered action text
96
135
  <%_ } _%>
97
- // When.onThe<%- startLR%>Generated.onTable("<%- tab.key %>").iPressAction("<%- item.label %>");
98
136
  Then.onThe<%- startLR%>Generated.onTable("<%- tab.key %>").iCheckAction("<%- item.label %>", { visible: true });
137
+ // When.onThe<%- startLR%>Generated.onTable("<%- tab.key %>").iExecuteAction("<%- item.label %>");
99
138
  <%_ } else { _%>
100
- // When.onThe<%- startLR%>Generated.onTable("<%- tab.key %>").iPressAction({ service: "<%- item.service %>", action: "<%- item.action %>", unbound: <%- item.unbound === true %> });
139
+ <%_ const hasParamDialog = item.parameterDialogFields && item.parameterDialogFields.length > 0; _%>
101
140
  Then.onThe<%- startLR%>Generated.onTable("<%- tab.key %>").iCheckAction({ service: "<%- item.service %>", action: "<%- item.action %>", unbound: <%- item.unbound === true %> }, { enabled: <%- item.enabled === true %> });
141
+ // When.onThe<%- startLR%>Generated.onTable("<%- tab.key %>").iExecuteAction({ service: "<%- item.service %>", action: "<%- item.action %>", unbound: <%- item.unbound === true %> });
142
+ <%_ if (item.selectionEnables && !item.isCritical && !hasParamDialog) { _%>
143
+ <%_ if (!hideFilterBar) { _%>
144
+ // Populate the table and select a row so the action becomes enabled.
145
+ When.onThe<%- startLR%>Generated.onFilterBar().iExecuteSearch();
146
+ <%_ } _%>
147
+ When.onThe<%- startLR%>Generated.onTable("<%- tab.key %>").iSelectRows(0);
148
+ Then.onThe<%- startLR%>Generated.onTable("<%- tab.key %>").iCheckAction({ service: "<%- item.service %>", action: "<%- item.action %>", unbound: <%- item.unbound === true %> }, { enabled: true });
149
+ // Deselect the row so the following actions start with an empty selection.
150
+ When.onThe<%- startLR%>Generated.onTable("<%- tab.key %>").iSelectRows(0);
151
+ <%_ } else if ((item.isCritical || hasParamDialog) && item.enabled === 'dynamic') { _%>
152
+ // "<%- item.label %>" is conditionally enabled (Core.OperationAvailable path); it may be disabled for the selected row. Uncomment and select a row that enables it to test the <%- hasParamDialog ? 'action parameter dialog' : 'confirmation dialog' %>.
153
+ <%_ if (!hideFilterBar) { _%>
154
+ // When.onThe<%- startLR%>Generated.onFilterBar().iExecuteSearch();
155
+ <%_ } _%>
156
+ // When.onThe<%- startLR%>Generated.onTable("<%- tab.key %>").iSelectRows(0);
157
+ // When.onThe<%- startLR%>Generated.onTable("<%- tab.key %>").iExecuteAction({ service: "<%- item.service %>", action: "<%- item.action %>", unbound: <%- item.unbound === true %> });
158
+ <%_ if (hasParamDialog) { _%>
159
+ <%_ item.parameterDialogFields.forEach(function(parameter) { _%>
160
+ // Then.onThe<%- startLR%>Generated.onActionDialog().iCheckActionParameterDialogField({ property: "<%- parameter %>" }, undefined, { visible: true });
161
+ <%_ }); _%>
162
+ // When.onThe<%- startLR%>Generated.onActionDialog().iCancel();
163
+ <%_ } else { _%>
164
+ // Then.onThe<%- startLR%>Generated.onMessageDialog().iCheckState();
165
+ // When.onThe<%- startLR%>Generated.onMessageDialog().iCancel();
102
166
  <%_ } _%>
167
+ // When.onThe<%- startLR%>Generated.onTable("<%- tab.key %>").iSelectRows(0);
168
+ <%_ } else if (item.isCritical || hasParamDialog) { _%>
169
+ <%_ if (!hideFilterBar) { _%>
170
+ // Populate the table so the action below has a row to select.
171
+ When.onThe<%- startLR%>Generated.onFilterBar().iExecuteSearch();
172
+ <%_ } _%>
173
+ <%_ if (item.enabled !== true) { _%>
174
+ When.onThe<%- startLR%>Generated.onTable("<%- tab.key %>").iSelectRows(0);
103
175
  <%_ } _%>
176
+ When.onThe<%- startLR%>Generated.onTable("<%- tab.key %>").iExecuteAction({ service: "<%- item.service %>", action: "<%- item.action %>", unbound: <%- item.unbound === true %> });
177
+ <%_ if (hasParamDialog) { _%>
178
+ <%_ item.parameterDialogFields.forEach(function(parameter) { _%>
179
+ Then.onThe<%- startLR%>Generated.onActionDialog().iCheckActionParameterDialogField({ property: "<%- parameter %>" }, undefined, { visible: true });
104
180
  <%_ }); _%>
105
- <%_ if (Object.keys(tab.tableColumns).length > 0) { _%>
181
+ When.onThe<%- startLR%>Generated.onActionDialog().iCancel();
182
+ <%_ } else { _%>
183
+ Then.onThe<%- startLR%>Generated.onMessageDialog().iCheckState();
184
+ When.onThe<%- startLR%>Generated.onMessageDialog().iCancel();
185
+ <%_ } _%>
186
+ <%_ if (item.enabled !== true) { _%>
187
+ // Deselect the row so the following actions start with an empty selection.
188
+ When.onThe<%- startLR%>Generated.onTable("<%- tab.key %>").iSelectRows(0);
189
+ <%_ } _%>
190
+ <%_ } _%>
191
+ <%_ } _%>
192
+ });
193
+
194
+ <%_ } -%>
195
+ <%_ }); -%>
196
+ <%_ if (Object.keys(tab.tableColumns).length > 0) { -%>
197
+ opaTest(<%- JSON.stringify("Check table columns in view " + tab.key) %>, function (Given, When, Then) {
198
+ When.onThe<%- startLR%>Generated.iGoToView({ key: "<%- tab.key %>" });
106
199
  Then.onThe<%- startLR %>Generated.onTable("<%- tab.key %>").iCheckColumns(undefined, <%- JSON.stringify(tab.tableColumns) %>);
200
+ });
201
+
202
+ <%_ } -%>
203
+ <%_ if (tab.textAnnotationColumns && tab.textAnnotationColumns.length > 0) { -%>
204
+ opaTest(<%- JSON.stringify("Check the Sort options for columns with a Text annotation in view " + tab.key) %>, function (Given, When, Then) {
205
+ When.onThe<%- startLR%>Generated.iGoToView({ key: "<%- tab.key %>" });
206
+ <%_ tab.textAnnotationColumns.forEach(function(column) { _%>
207
+ <%_ if (column.columnProperty) { _%>
208
+ When.onThe<%- startLR%>Generated.onTable("<%- tab.key %>").iChangeSortOrder({ name: "<%- column.columnProperty %>" }, coreLibrary.SortOrder.Ascending);
209
+ Then.onThe<%- startLR%>Generated.onTable("<%- tab.key %>").iCheckSortOrder({ name: "<%- column.columnProperty %>" }, coreLibrary.SortOrder.Ascending, true);
210
+ When.onThe<%- startLR%>Generated.onTable("<%- tab.key %>").iChangeSortOrder({ name: "<%- column.columnProperty %>" }, coreLibrary.SortOrder.None);
211
+ <%_ } _%>
212
+ <%_ if (!column.skipTextPropertyTest && !column.textPropertyNotSortable) { _%>
213
+ When.onThe<%- startLR%>Generated.onTable("<%- tab.key %>").iChangeSortOrder({ name: "<%- column.textProperty %>" }, coreLibrary.SortOrder.Ascending);
214
+ Then.onThe<%- startLR%>Generated.onTable("<%- tab.key %>").iCheckSortOrder({ name: "<%- column.textProperty %>" }, coreLibrary.SortOrder.Ascending, true);
215
+ When.onThe<%- startLR%>Generated.onTable("<%- tab.key %>").iChangeSortOrder({ name: "<%- column.textProperty %>" }, coreLibrary.SortOrder.None);
216
+ <%_ } _%>
217
+ <%_ }); -%>
218
+ });
219
+
220
+ <%_ if (tab.columnPersonalizationSupported !== false) { -%>
221
+ opaTest(<%- JSON.stringify("Check the presence of the text columns for columns with a Text annotation in view " + tab.key) %>, function (Given, When, Then) {
222
+ When.onThe<%- startLR%>Generated.iGoToView({ key: "<%- tab.key %>" });
223
+ When.onThe<%- startLR%>Generated.onTable("<%- tab.key %>").iOpenColumnAdaptation();
224
+ <%_ tab.textAnnotationColumns.forEach(function(column) { _%>
225
+ <%_ if (!column.skipTextPropertyTest) { _%>
226
+ When.onThe<%- startLR%>Generated.onTable("<%- tab.key %>").iAddAdaptationColumn({ name: "<%- column.textProperty %>" });
227
+ Then.onThe<%- startLR%>Generated.onTable("<%- tab.key %>").iCheckAdaptationColumn({ name: "<%- column.textProperty %>" });
107
228
  <%_ } _%>
229
+ <%_ }); -%>
230
+ When.onThe<%- startLR%>Generated.onTable("<%- tab.key %>").iConfirmColumnAdaptation();
231
+ });
232
+
233
+ <%_ } -%>
234
+ <%_ } -%>
235
+ opaTest(<%- JSON.stringify("Check table rows in view " + tab.key) %>, function (Given, When, Then) {
236
+ When.onThe<%- startLR%>Generated.iGoToView({ key: "<%- tab.key %>" });
237
+ <%_ if (!hideFilterBar) { -%>
238
+ // Populate the table so the row check has data.
239
+ When.onThe<%- startLR%>Generated.onFilterBar().iExecuteSearch();
240
+ <%_ } -%>
108
241
  Then.onThe<%- startLR%>Generated.onTable("<%- tab.key %>").iCheckRows();
109
242
  <%_ if (tab.contactCardColumns.length > 0) { _%>
110
243
  // Reveal popin details so low-priority (e.g. contact-card) columns become clickable
@@ -115,27 +248,42 @@ sap.ui.define([
115
248
  When.onThe<%- startLR %>Generated.onTable("<%- tab.key %>").iClickLink(0, "<%- column.property %>");
116
249
  Then.onThe<%- startLR %>Generated.onDialog().iCheckContactDialog({ controlType: "sap.ui.mdc.link.Panel" });
117
250
  <%_ }); _%>
118
- <%_ }); -%>
119
251
  });
252
+
253
+ <%_ }); -%>
120
254
  <%_ } else { -%>
121
- <%_ if ((toolBarActions && toolBarActions.length > 0 ) || (tableColumns && Object.keys(tableColumns).length > 0)) { -%>
122
- opaTest("Check table columns and actions", function (Given, When, Then) {
123
- <%_ if (toolBarActions && toolBarActions.length > 0) { -%>
124
- <%_ if (createButton.visible && !isALP) { _%>
255
+ <%_ if (createButton.visible && !isALP) { -%>
256
+ opaTest("Check the create button", function (Given, When, Then) {
125
257
  Then.onThe<%- startLR%>Generated.onTable(defaultTableId).iCheckCreate({ visible: true });
126
- // When.onThe<%- startLR%>Generated.onTable(defaultTableId).iPressCreate();
258
+ // When.onThe<%- startLR%>Generated.onTable(defaultTableId).iExecuteCreate();
259
+ });
260
+
261
+ <%_ } -%>
262
+ <%_ if (deleteButton.visible) { -%>
263
+ opaTest("Check the delete button", function (Given, When, Then) {
264
+ <%_ /* deleteButton.enabled = Capabilities Deletable (not current UI state); when deletable, Delete is selection-gated: disabled with no selection, enabled once a row is selected. */ -%>
265
+ <%_ const deleteIsSelectionGated = deleteButton.enabled === true; _%>
266
+ <%_ if (deleteIsSelectionGated) { _%>
267
+ Then.onThe<%- startLR%>Generated.onTable(defaultTableId).iCheckDelete({ visible: true, enabled: false });
268
+ <%_ if (!hideFilterBar) { _%>
269
+ // Populate the table and select a row so Delete becomes enabled.
270
+ When.onThe<%- startLR%>Generated.onFilterBar().iExecuteSearch();
127
271
  <%_ } _%>
128
- <%_ if (deleteButton.visible) { _%>
129
- // When.onThe<%- startLR%>Generated.onTable(defaultTableId).iPressDelete();
272
+ When.onThe<%- startLR%>Generated.onTable(defaultTableId).iSelectRows(0);
273
+ Then.onThe<%- startLR%>Generated.onTable(defaultTableId).iCheckDelete({ visible: true, enabled: true });
274
+ // When.onThe<%- startLR%>Generated.onTable(defaultTableId).iExecuteDelete();
275
+ // Deselect the row so the following actions start with an empty selection.
276
+ When.onThe<%- startLR%>Generated.onTable(defaultTableId).iSelectRows(0);
277
+ <%_ } else { _%>
130
278
  Then.onThe<%- startLR%>Generated.onTable(defaultTableId).iCheckDelete({ visible: true });
279
+ // When.onThe<%- startLR%>Generated.onTable(defaultTableId).iExecuteDelete();
131
280
  <%_ } _%>
132
- <%_ const toolBarHasDialogAction = (toolBarActions || []).some(function(action) { return action.visible && !action.menuActions && !action.custom && action.enabled !== 'dynamic' && (action.isCritical || (action.parameterDialogFields && action.parameterDialogFields.length > 0)); }); _%>
133
- <%_ if (!hideFilterBar && toolBarHasDialogAction) { _%>
134
- // Populate the table so the actions below have a row to select.
135
- When.onThe<%- startLR%>Generated.onFilterBar().iExecuteSearch();
136
- <%_ } _%>
137
- <%_ toolBarActions.forEach(function(item) { _%>
138
- <%_ if (item.visible) { _%>
281
+ });
282
+
283
+ <%_ } -%>
284
+ <%_ (toolBarActions || []).forEach(function(item) { -%>
285
+ <%_ if (item.visible) { -%>
286
+ opaTest(<%- JSON.stringify("Check the " + item.label + " action") %>, function (Given, When, Then) {
139
287
  <%_ if (item.menuActions) { _%>
140
288
  <%_ if (item.splitButton) { _%>
141
289
  // "<%- item.label %>" is a split menu button (has a default action); its drop-down cannot be opened via the test API, so its menu items are not checked. Pressing it triggers the default action:
@@ -155,13 +303,22 @@ sap.ui.define([
155
303
  <%_ if (item.labelUnresolved) { _%>
156
304
  // TODO: label is an unresolved i18n key; replace with the rendered action text
157
305
  <%_ } _%>
158
- // When.onThe<%- startLR%>Generated.onTable(defaultTableId).iExecuteAction("<%- item.label %>");
159
306
  Then.onThe<%- startLR%>Generated.onTable(defaultTableId).iCheckAction("<%- item.label %>", { visible: true });
307
+ // When.onThe<%- startLR%>Generated.onTable(defaultTableId).iExecuteAction("<%- item.label %>");
160
308
  <%_ } else { _%>
161
- // When.onThe<%- startLR%>Generated.onTable(defaultTableId).iPressAction({ service: "<%- item.service %>", action: "<%- item.action %>", unbound: <%- item.unbound === true %> });
162
- Then.onThe<%- startLR%>Generated.onTable(defaultTableId).iCheckAction({ service: "<%- item.service %>", action: "<%- item.action %>", unbound: <%- item.unbound === true %> }, { enabled: <%- item.enabled === true %> });
163
309
  <%_ const hasParamDialog = item.parameterDialogFields && item.parameterDialogFields.length > 0; _%>
164
- <%_ if ((item.isCritical || hasParamDialog) && item.enabled === 'dynamic') { _%>
310
+ Then.onThe<%- startLR%>Generated.onTable(defaultTableId).iCheckAction({ service: "<%- item.service %>", action: "<%- item.action %>", unbound: <%- item.unbound === true %> }, { enabled: <%- item.enabled === true %> });
311
+ // When.onThe<%- startLR%>Generated.onTable(defaultTableId).iExecuteAction({ service: "<%- item.service %>", action: "<%- item.action %>", unbound: <%- item.unbound === true %> });
312
+ <%_ if (item.selectionEnables && !item.isCritical && !hasParamDialog) { _%>
313
+ <%_ if (!hideFilterBar) { _%>
314
+ // Populate the table and select a row so the action becomes enabled.
315
+ When.onThe<%- startLR%>Generated.onFilterBar().iExecuteSearch();
316
+ <%_ } _%>
317
+ When.onThe<%- startLR%>Generated.onTable(defaultTableId).iSelectRows(0);
318
+ Then.onThe<%- startLR%>Generated.onTable(defaultTableId).iCheckAction({ service: "<%- item.service %>", action: "<%- item.action %>", unbound: <%- item.unbound === true %> }, { enabled: true });
319
+ // Deselect the row so the following actions start with an empty selection.
320
+ When.onThe<%- startLR%>Generated.onTable(defaultTableId).iSelectRows(0);
321
+ <%_ } else if ((item.isCritical || hasParamDialog) && item.enabled === 'dynamic') { _%>
165
322
  // "<%- item.label %>" is conditionally enabled (Core.OperationAvailable path); it may be disabled for the selected row. Uncomment and select a row that enables it to test the <%- hasParamDialog ? 'action parameter dialog' : 'confirmation dialog' %>.
166
323
  <%_ if (!hideFilterBar) { _%>
167
324
  // When.onThe<%- startLR%>Generated.onFilterBar().iExecuteSearch();
@@ -179,6 +336,10 @@ sap.ui.define([
179
336
  <%_ } _%>
180
337
  // When.onThe<%- startLR%>Generated.onTable(defaultTableId).iSelectRows(0);
181
338
  <%_ } else if (item.isCritical || hasParamDialog) { _%>
339
+ <%_ if (!hideFilterBar) { _%>
340
+ // Populate the table so the action below has a row to select.
341
+ When.onThe<%- startLR%>Generated.onFilterBar().iExecuteSearch();
342
+ <%_ } _%>
182
343
  <%_ if (item.enabled !== true) { _%>
183
344
  When.onThe<%- startLR%>Generated.onTable(defaultTableId).iSelectRows(0);
184
345
  <%_ } _%>
@@ -198,41 +359,46 @@ sap.ui.define([
198
359
  <%_ } _%>
199
360
  <%_ } _%>
200
361
  <%_ } _%>
201
- <%_ } _%>
202
- <%_ }); -%>
203
- <%_ } -%>
204
- <%_ if (tableColumns && Object.keys(tableColumns).length > 0) { -%>
362
+ });
363
+
364
+ <%_ } -%>
365
+ <%_ }); -%>
366
+ <%_ if (tableColumns && Object.keys(tableColumns).length > 0) { -%>
367
+ opaTest("Check table columns", function (Given, When, Then) {
205
368
  Then.onThe<%- startLR %>Generated.onTable(defaultTableId).iCheckColumns(undefined, <%- JSON.stringify(tableColumns) %>);
206
- <%_ } -%>
207
369
  });
370
+
208
371
  <%_ } -%>
209
372
  <%_ if (startLR && textAnnotationColumns && textAnnotationColumns.length > 0) { -%>
210
- opaTest("Check text annotation for columns", function (Given, When, Then) {
373
+ opaTest("Check the Sort options for columns with a Text annotation", function (Given, When, Then) {
211
374
  <%_ textAnnotationColumns.forEach(function(column) { _%>
212
375
  <%_ if (column.columnProperty) { _%>
213
376
  When.onThe<%- startLR%>Generated.onTable(defaultTableId).iChangeSortOrder({ name: "<%- column.columnProperty %>" }, coreLibrary.SortOrder.Ascending);
214
377
  Then.onThe<%- startLR%>Generated.onTable(defaultTableId).iCheckSortOrder({ name: "<%- column.columnProperty %>" }, coreLibrary.SortOrder.Ascending, true);
215
378
  When.onThe<%- startLR%>Generated.onTable(defaultTableId).iChangeSortOrder({ name: "<%- column.columnProperty %>" }, coreLibrary.SortOrder.None);
216
379
  <%_ } _%>
217
- <%_ if (!column.skipTextPropertyTest) { _%>
380
+ <%_ if (!column.skipTextPropertyTest && !column.textPropertyNotSortable) { _%>
218
381
  When.onThe<%- startLR%>Generated.onTable(defaultTableId).iChangeSortOrder({ name: "<%- column.textProperty %>" }, coreLibrary.SortOrder.Ascending);
219
382
  Then.onThe<%- startLR%>Generated.onTable(defaultTableId).iCheckSortOrder({ name: "<%- column.textProperty %>" }, coreLibrary.SortOrder.Ascending, true);
220
383
  When.onThe<%- startLR%>Generated.onTable(defaultTableId).iChangeSortOrder({ name: "<%- column.textProperty %>" }, coreLibrary.SortOrder.None);
221
384
  <%_ } _%>
222
385
  <%_ }); -%>
223
386
  });
387
+
224
388
  <%_ } -%>
225
389
  <%_ if (startLR && textAnnotationColumns && textAnnotationColumns.length > 0 && columnPersonalizationSupported !== false) { -%>
226
- opaTest("Check columns in adaptation dialog", function (Given, When, Then) {
390
+ opaTest("Check the presence of the text columns for columns with a Text annotation", function (Given, When, Then) {
227
391
  When.onThe<%- startLR%>Generated.onTable(defaultTableId).iOpenColumnAdaptation();
228
392
  <%_ textAnnotationColumns.forEach(function(column) { _%>
393
+ <%_ if (!column.skipTextPropertyTest) { _%>
229
394
  When.onThe<%- startLR%>Generated.onTable(defaultTableId).iAddAdaptationColumn({ name: "<%- column.textProperty %>" });
230
395
  Then.onThe<%- startLR%>Generated.onTable(defaultTableId).iCheckAdaptationColumn({ name: "<%- column.textProperty %>" });
396
+ <%_ } _%>
231
397
  <%_ }); -%>
232
398
  When.onThe<%- startLR%>Generated.onTable(defaultTableId).iConfirmColumnAdaptation();
233
399
  });
234
- <%_ } -%>
235
400
 
401
+ <%_ } -%>
236
402
  <%_ if (contactCardColumns.length > 0) { -%>
237
403
  opaTest("Check contact card links", function (Given, When, Then) {
238
404
  // Reveal popin details so low-priority (e.g. contact-card) columns become clickable