@sapui5/sap.fe.test 1.96.4 → 1.99.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.
Files changed (77) hide show
  1. package/package.json +6 -3
  2. package/src/sap/fe/test/.library +1 -1
  3. package/src/sap/fe/test/BaseActions.js +3 -2
  4. package/src/sap/fe/test/BaseArrangements.js +3 -2
  5. package/src/sap/fe/test/BaseAssertions.js +3 -2
  6. package/src/sap/fe/test/ConfirmDialog.js +3 -2
  7. package/src/sap/fe/test/FCLView.js +3 -2
  8. package/src/sap/fe/test/FeMocks.js +66 -0
  9. package/src/sap/fe/test/FeMocks.ts +77 -0
  10. package/src/sap/fe/test/Flexibility.js +17 -5
  11. package/src/sap/fe/test/FlexibleColumnLayout.js +3 -2
  12. package/src/sap/fe/test/JestTemplatingHelper.js +78 -22
  13. package/src/sap/fe/test/JestTemplatingHelper.ts +66 -22
  14. package/src/sap/fe/test/JourneyRunner.js +11 -5
  15. package/src/sap/fe/test/ListReport.js +11 -16
  16. package/src/sap/fe/test/LocationUtil.js +3 -2
  17. package/src/sap/fe/test/ObjectPage.js +28 -55
  18. package/src/sap/fe/test/Shell.js +3 -2
  19. package/src/sap/fe/test/Stubs.js +3 -2
  20. package/src/sap/fe/test/TemplatePage.js +3 -14
  21. package/src/sap/fe/test/TemplatingTestUtils.js +4 -3
  22. package/src/sap/fe/test/UI5MockHelper.js +249 -39
  23. package/src/sap/fe/test/UI5MockHelper.ts +138 -9
  24. package/src/sap/fe/test/Utils.js +3 -14
  25. package/src/sap/fe/test/api/APIHelper.js +3 -2
  26. package/src/sap/fe/test/api/BaseAPI.js +26 -9
  27. package/src/sap/fe/test/api/ChartActions.js +3 -2
  28. package/src/sap/fe/test/api/ChartAssertions.js +7 -6
  29. package/src/sap/fe/test/api/DialogAPI.js +26 -9
  30. package/src/sap/fe/test/api/DialogActions.js +21 -7
  31. package/src/sap/fe/test/api/DialogAssertions.js +28 -7
  32. package/src/sap/fe/test/api/DialogCreateActions.js +4 -3
  33. package/src/sap/fe/test/api/DialogCreateAssertions.js +4 -3
  34. package/src/sap/fe/test/api/DialogMessageActions.js +19 -3
  35. package/src/sap/fe/test/api/DialogMessageAssertions.js +4 -3
  36. package/src/sap/fe/test/api/DialogType.js +3 -2
  37. package/src/sap/fe/test/api/DialogValueHelpActions.js +4 -3
  38. package/src/sap/fe/test/api/DialogValueHelpAssertions.js +4 -3
  39. package/src/sap/fe/test/api/EditState.js +12 -2
  40. package/src/sap/fe/test/api/FilterBarAPI.js +3 -2
  41. package/src/sap/fe/test/api/FilterBarActions.js +41 -6
  42. package/src/sap/fe/test/api/FilterBarAssertions.js +3 -2
  43. package/src/sap/fe/test/api/FooterAPI.js +3 -2
  44. package/src/sap/fe/test/api/FooterActionsBase.js +3 -2
  45. package/src/sap/fe/test/api/FooterActionsOP.js +3 -2
  46. package/src/sap/fe/test/api/FooterAssertionsBase.js +3 -2
  47. package/src/sap/fe/test/api/FooterAssertionsOP.js +3 -2
  48. package/src/sap/fe/test/api/FormAPI.js +3 -2
  49. package/src/sap/fe/test/api/FormActions.js +3 -2
  50. package/src/sap/fe/test/api/FormAssertions.js +36 -6
  51. package/src/sap/fe/test/api/HeaderAPI.js +3 -2
  52. package/src/sap/fe/test/api/HeaderActions.js +3 -2
  53. package/src/sap/fe/test/api/HeaderActionsLR.js +3 -2
  54. package/src/sap/fe/test/api/HeaderAssertions.js +3 -2
  55. package/src/sap/fe/test/api/HeaderAssertionsLR.js +3 -2
  56. package/src/sap/fe/test/api/HeaderLR.js +3 -2
  57. package/src/sap/fe/test/api/KPICardAPI.js +3 -2
  58. package/src/sap/fe/test/api/KPICardActions.js +43 -0
  59. package/src/sap/fe/test/api/KPICardAssertions.js +22 -17
  60. package/src/sap/fe/test/api/TableAPI.js +3 -2
  61. package/src/sap/fe/test/api/TableActions.js +4 -22
  62. package/src/sap/fe/test/api/TableAssertions.js +17 -6
  63. package/src/sap/fe/test/builder/DialogBuilder.js +3 -2
  64. package/src/sap/fe/test/builder/FEBuilder.js +3 -2
  65. package/src/sap/fe/test/builder/KPIBuilder.js +14 -4
  66. package/src/sap/fe/test/builder/MacroFieldBuilder.js +3 -2
  67. package/src/sap/fe/test/builder/MdcFieldBuilder.js +3 -2
  68. package/src/sap/fe/test/builder/MdcFilterBarBuilder.js +3 -2
  69. package/src/sap/fe/test/builder/MdcFilterFieldBuilder.js +3 -2
  70. package/src/sap/fe/test/builder/MdcTableBuilder.js +15 -2
  71. package/src/sap/fe/test/builder/OverflowToolbarBuilder.js +3 -2
  72. package/src/sap/fe/test/builder/VMBuilder.js +3 -2
  73. package/src/sap/fe/test/internal/FEArrangements.js +3 -2
  74. package/src/sap/fe/test/internal/FEJourneyRunner.js +9 -5
  75. package/src/sap/fe/test/library.js +4 -3
  76. package/src/sap/fe/test/massEdit.js +3 -2
  77. package/ui5.yaml +0 -3
@@ -1,6 +1,7 @@
1
1
  /*
2
- * ! SAPUI5
3
- * (c) Copyright 2009-2022 SAP SE. All rights reserved.
2
+ * ! SAP UI development toolkit for HTML5 (SAPUI5)
3
+ (c) Copyright 2009-2021 SAP SE. All rights reserved
4
+
4
5
  */
5
6
  sap.ui.define(["./DialogAssertions", "sap/ui/test/OpaBuilder", "sap/fe/test/builder/FEBuilder", "sap/fe/test/Utils"], function(
6
7
  DialogAssertions,
@@ -23,7 +24,7 @@ sap.ui.define(["./DialogAssertions", "sap/ui/test/OpaBuilder", "sap/fe/test/buil
23
24
  * @public
24
25
  */
25
26
  var DialogMessageAssertions = function(oDialogBuilder, vDialogDescription) {
26
- return DialogAssertions.call(this, oDialogBuilder, vDialogDescription, 1);
27
+ return DialogAssertions.call(this, oDialogBuilder, vDialogDescription, 0);
27
28
  };
28
29
  DialogMessageAssertions.prototype = Object.create(DialogAssertions.prototype);
29
30
  DialogMessageAssertions.prototype.constructor = DialogMessageAssertions;
@@ -1,6 +1,7 @@
1
1
  /*
2
- * ! SAPUI5
3
- * (c) Copyright 2009-2022 SAP SE. All rights reserved.
2
+ * ! SAP UI development toolkit for HTML5 (SAPUI5)
3
+ (c) Copyright 2009-2021 SAP SE. All rights reserved
4
+
4
5
  */
5
6
  sap.ui.define(
6
7
  [],
@@ -1,6 +1,7 @@
1
1
  /*
2
- * ! SAPUI5
3
- * (c) Copyright 2009-2022 SAP SE. All rights reserved.
2
+ * ! SAP UI development toolkit for HTML5 (SAPUI5)
3
+ (c) Copyright 2009-2021 SAP SE. All rights reserved
4
+
4
5
  */
5
6
  sap.ui.define(
6
7
  [
@@ -31,7 +32,7 @@ sap.ui.define(
31
32
  * @public
32
33
  */
33
34
  var DialogValueHelpActions = function(oDialogBuilder, vDialogDescription) {
34
- return DialogActions.call(this, oDialogBuilder, vDialogDescription);
35
+ return DialogActions.call(this, oDialogBuilder, vDialogDescription, 0);
35
36
  };
36
37
  DialogValueHelpActions.prototype = Object.create(DialogActions.prototype);
37
38
  DialogValueHelpActions.prototype.constructor = DialogValueHelpActions;
@@ -1,6 +1,7 @@
1
1
  /*
2
- * ! SAPUI5
3
- * (c) Copyright 2009-2022 SAP SE. All rights reserved.
2
+ * ! SAP UI development toolkit for HTML5 (SAPUI5)
3
+ (c) Copyright 2009-2021 SAP SE. All rights reserved
4
+
4
5
  */
5
6
  sap.ui.define(
6
7
  [
@@ -30,7 +31,7 @@ sap.ui.define(
30
31
  * @public
31
32
  */
32
33
  var DialogValueHelpAssertions = function(oDialogBuilder, vDialogDescription) {
33
- return DialogAssertions.call(this, oDialogBuilder, vDialogDescription, 1);
34
+ return DialogAssertions.call(this, oDialogBuilder, vDialogDescription, 0);
34
35
  };
35
36
  DialogValueHelpAssertions.prototype = Object.create(DialogAssertions.prototype);
36
37
  DialogValueHelpAssertions.prototype.constructor = DialogValueHelpAssertions;
@@ -1,6 +1,7 @@
1
1
  /*
2
- * ! SAPUI5
3
- * (c) Copyright 2009-2022 SAP SE. All rights reserved.
2
+ * ! SAP UI development toolkit for HTML5 (SAPUI5)
3
+ (c) Copyright 2009-2021 SAP SE. All rights reserved
4
+
4
5
  */
5
6
  sap.ui.define(
6
7
  ["sap/fe/macros/filter/DraftEditState"],
@@ -32,6 +33,15 @@ sap.ui.define(
32
33
  * @type {string}
33
34
  * @public
34
35
  */
36
+ AllHidingDrafts: EditState.ALL_HIDING_DRAFTS.id,
37
+ /**
38
+ * All (Hiding Drafts)
39
+ *
40
+ * @name sap.fe.test.api.EditState.AllHidingDrafts
41
+ * @constant
42
+ * @type {string}
43
+ * @public
44
+ */
35
45
  Unchanged: EditState.UNCHANGED.id,
36
46
  /**
37
47
  * Own Draft
@@ -1,6 +1,7 @@
1
1
  /*
2
- * ! SAPUI5
3
- * (c) Copyright 2009-2022 SAP SE. All rights reserved.
2
+ * ! SAP UI development toolkit for HTML5 (SAPUI5)
3
+ (c) Copyright 2009-2021 SAP SE. All rights reserved
4
+
4
5
  */
5
6
  sap.ui.define(
6
7
  [
@@ -1,6 +1,7 @@
1
1
  /*
2
- * ! SAPUI5
3
- * (c) Copyright 2009-2022 SAP SE. All rights reserved.
2
+ * ! SAP UI development toolkit for HTML5 (SAPUI5)
3
+ (c) Copyright 2009-2021 SAP SE. All rights reserved
4
+
4
5
  */
5
6
  sap.ui.define(
6
7
  [
@@ -234,18 +235,28 @@ sap.ui.define(
234
235
  /**
235
236
  * Saves a variant under the given name, or overwrites the current variant.
236
237
  *
237
- * @param {string} [sVariantName] The name of the new variant. If omitted, the current variant will be overwritten.
238
+ * @param {string} [sVariantName] The name of the new variant. If no new variant name is defined, the current variant will be overwritten.
239
+ * @param {string} [bSetAsDefault] Saves the new variant with option "Set as Default".
240
+ * @param {string} [bApplyAutomatically] Saves the new variant with option "Apply Automatically".
238
241
  * @returns {object} The result of the {@link sap.ui.test.Opa5#waitFor} function, to be used for chained statements
239
242
  *
240
243
  * @public
241
244
  */
242
- FilterBarActions.prototype.iSaveVariant = function(sVariantName) {
245
+ FilterBarActions.prototype.iSaveVariant = function(sVariantName, bSetAsDefault, bApplyAutomatically) {
243
246
  var fnSuccessFunction = Utils.isOfType(sVariantName, String)
244
247
  ? function(oFilterBar) {
245
248
  return VMBuilder.create(this)
246
249
  .hasId(oFilterBar.getId() + "::VariantManagement")
247
- .doSaveAs(sVariantName)
248
- .description(Utils.formatMessage("Saving variant for '{0}' as '{1}'", this.getIdentifier(), sVariantName))
250
+ .doSaveAs(sVariantName, bSetAsDefault, bApplyAutomatically)
251
+ .description(
252
+ Utils.formatMessage(
253
+ "Saving variant for '{0}' as '{1}' with default='{2}' and applyAutomatically='{3}'",
254
+ this.getIdentifier(),
255
+ sVariantName,
256
+ !!bSetAsDefault,
257
+ !!bApplyAutomatically
258
+ )
259
+ )
249
260
  .execute();
250
261
  }
251
262
  : function(oFilterBar) {
@@ -263,6 +274,30 @@ sap.ui.define(
263
274
  );
264
275
  };
265
276
 
277
+ /**
278
+ * Selects the chosen variant.
279
+ *
280
+ * @param {string} sVariantName The name of the variant to be selected
281
+ * @returns {object} The result of the {@link sap.ui.test.Opa5#waitFor} function, to be used for chained statements
282
+ *
283
+ * @public
284
+ */
285
+ FilterBarActions.prototype.iSelectVariant = function(sVariantName) {
286
+ return this.prepareResult(
287
+ this.getBuilder()
288
+ .success(
289
+ function(oFilterBar) {
290
+ return VMBuilder.create(this)
291
+ .hasId(oFilterBar.getId() + "::VariantManagement")
292
+ .doSelectVariant(sVariantName)
293
+ .description(Utils.formatMessage("Selecting variant '{1}' from '{0}'", this.getIdentifier(), sVariantName))
294
+ .execute();
295
+ }.bind(this)
296
+ )
297
+ .execute()
298
+ );
299
+ };
300
+
266
301
  FilterBarActions.prototype.iSelectVisualFilter = function(sVisualFilterIdentifier, sLabelValue, bIsSelected) {
267
302
  // var that = this;
268
303
  return this.prepareResult(
@@ -1,6 +1,7 @@
1
1
  /*
2
- * ! SAPUI5
3
- * (c) Copyright 2009-2022 SAP SE. All rights reserved.
2
+ * ! SAP UI development toolkit for HTML5 (SAPUI5)
3
+ (c) Copyright 2009-2021 SAP SE. All rights reserved
4
+
4
5
  */
5
6
  sap.ui.define(
6
7
  [
@@ -1,6 +1,7 @@
1
1
  /*
2
- * ! SAPUI5
3
- * (c) Copyright 2009-2022 SAP SE. All rights reserved.
2
+ * ! SAP UI development toolkit for HTML5 (SAPUI5)
3
+ (c) Copyright 2009-2021 SAP SE. All rights reserved
4
+
4
5
  */
5
6
  sap.ui.define(
6
7
  [
@@ -1,6 +1,7 @@
1
1
  /*
2
- * ! SAPUI5
3
- * (c) Copyright 2009-2022 SAP SE. All rights reserved.
2
+ * ! SAP UI development toolkit for HTML5 (SAPUI5)
3
+ (c) Copyright 2009-2021 SAP SE. All rights reserved
4
+
4
5
  */
5
6
  sap.ui.define(["./FooterAPI", "sap/fe/test/Utils", "sap/ui/test/OpaBuilder"], function(FooterAPI, Utils, OpaBuilder) {
6
7
  "use strict";
@@ -1,6 +1,7 @@
1
1
  /*
2
- * ! SAPUI5
3
- * (c) Copyright 2009-2022 SAP SE. All rights reserved.
2
+ * ! SAP UI development toolkit for HTML5 (SAPUI5)
3
+ (c) Copyright 2009-2021 SAP SE. All rights reserved
4
+
4
5
  */
5
6
  sap.ui.define(["./FooterActionsBase", "sap/fe/test/Utils", "sap/ui/test/OpaBuilder"], function(FooterActionsBase, Utils, OpaBuilder) {
6
7
  "use strict";
@@ -1,6 +1,7 @@
1
1
  /*
2
- * ! SAPUI5
3
- * (c) Copyright 2009-2022 SAP SE. All rights reserved.
2
+ * ! SAP UI development toolkit for HTML5 (SAPUI5)
3
+ (c) Copyright 2009-2021 SAP SE. All rights reserved
4
+
4
5
  */
5
6
  sap.ui.define(["./FooterAPI", "sap/fe/test/Utils"], function(FooterAPI, Utils) {
6
7
  "use strict";
@@ -1,6 +1,7 @@
1
1
  /*
2
- * ! SAPUI5
3
- * (c) Copyright 2009-2022 SAP SE. All rights reserved.
2
+ * ! SAP UI development toolkit for HTML5 (SAPUI5)
3
+ (c) Copyright 2009-2021 SAP SE. All rights reserved
4
+
4
5
  */
5
6
  sap.ui.define(["./FooterAssertionsBase", "sap/fe/test/Utils", "sap/m/library"], function(FooterAssertionsBase, Utils, mLibrary) {
6
7
  "use strict";
@@ -1,6 +1,7 @@
1
1
  /*
2
- * ! SAPUI5
3
- * (c) Copyright 2009-2022 SAP SE. All rights reserved.
2
+ * ! SAP UI development toolkit for HTML5 (SAPUI5)
3
+ (c) Copyright 2009-2021 SAP SE. All rights reserved
4
+
4
5
  */
5
6
  sap.ui.define(
6
7
  [
@@ -1,6 +1,7 @@
1
1
  /*
2
- * ! SAPUI5
3
- * (c) Copyright 2009-2022 SAP SE. All rights reserved.
2
+ * ! SAP UI development toolkit for HTML5 (SAPUI5)
3
+ (c) Copyright 2009-2021 SAP SE. All rights reserved
4
+
4
5
  */
5
6
  sap.ui.define(
6
7
  [
@@ -1,6 +1,7 @@
1
1
  /*
2
- * ! SAPUI5
3
- * (c) Copyright 2009-2022 SAP SE. All rights reserved.
2
+ * ! SAP UI development toolkit for HTML5 (SAPUI5)
3
+ (c) Copyright 2009-2021 SAP SE. All rights reserved
4
+
4
5
  */
5
6
  sap.ui.define(
6
7
  ["./FormAPI", "sap/fe/test/Utils", "sap/ui/test/OpaBuilder", "sap/fe/test/builder/FEBuilder", "sap/fe/test/builder/MacroFieldBuilder"],
@@ -171,10 +172,39 @@ sap.ui.define(
171
172
  return this.iCheckField(aArguments[0], aArguments[1], Utils.mergeObjects({ controlType: "sap.m.Link" }, aArguments[2]));
172
173
  };
173
174
 
174
- FormAssertions.prototype.iCheckElement = function(sId, oProperties) {
175
- return OpaBuilder.create(this)
176
- .hasId(sId)
177
- .hasProperties(oProperties);
175
+ FormAssertions.prototype.iCheckFormContainersElementCount = function(sFormContainer, iCount, mState) {
176
+ var aArguments = Utils.parseArguments([String, Number, Object], arguments),
177
+ fullSubSectionId = this.getIdentifier().fullSubSectionId,
178
+ mFormState = aArguments[2],
179
+ sView = fullSubSectionId.split("--")[0],
180
+ sForm = fullSubSectionId.split("--")[1].split("::")[2],
181
+ sFormContainerId = sView + "--" + "fe::FormContainer::" + aArguments[0];
182
+ return this.prepareResult(
183
+ this.getBuilder()
184
+ .hasId(sFormContainerId)
185
+ .has(function(oFormContainer) {
186
+ var oMatchingFormContainers;
187
+ if (Object.keys(mFormState).length) {
188
+ oMatchingFormContainers = oFormContainer.getFormElements().filter(function(oFormElement) {
189
+ return Object.keys(mFormState).every(function(sFormElementKey) {
190
+ return mFormState[sFormElementKey] === oFormElement.getProperty(sFormElementKey);
191
+ });
192
+ });
193
+ } else {
194
+ oMatchingFormContainers = oFormContainer.getFormElements();
195
+ }
196
+ return oMatchingFormContainers.length === iCount;
197
+ })
198
+ .description(
199
+ Utils.formatMessage(
200
+ "Form Container '{0}' on Form '{1}' has '{2}' Form Elements.",
201
+ aArguments[0],
202
+ sForm,
203
+ aArguments[1]
204
+ )
205
+ )
206
+ .execute()
207
+ );
178
208
  };
179
209
  return FormAssertions;
180
210
  }
@@ -1,6 +1,7 @@
1
1
  /*
2
- * ! SAPUI5
3
- * (c) Copyright 2009-2022 SAP SE. All rights reserved.
2
+ * ! SAP UI development toolkit for HTML5 (SAPUI5)
3
+ (c) Copyright 2009-2021 SAP SE. All rights reserved
4
+
4
5
  */
5
6
  sap.ui.define(
6
7
  [
@@ -1,6 +1,7 @@
1
1
  /*
2
- * ! SAPUI5
3
- * (c) Copyright 2009-2022 SAP SE. All rights reserved.
2
+ * ! SAP UI development toolkit for HTML5 (SAPUI5)
3
+ (c) Copyright 2009-2021 SAP SE. All rights reserved
4
+
4
5
  */
5
6
  sap.ui.define(["./HeaderAPI", "sap/fe/test/Utils", "sap/ui/test/OpaBuilder", "sap/fe/test/builder/FEBuilder", "./APIHelper"], function(
6
7
  HeaderAPI,
@@ -1,6 +1,7 @@
1
1
  /*
2
- * ! SAPUI5
3
- * (c) Copyright 2009-2022 SAP SE. All rights reserved.
2
+ * ! SAP UI development toolkit for HTML5 (SAPUI5)
3
+ (c) Copyright 2009-2021 SAP SE. All rights reserved
4
+
4
5
  */
5
6
  sap.ui.define(["./HeaderLR", "sap/fe/test/Utils", "sap/ui/test/OpaBuilder", "sap/fe/test/builder/FEBuilder", "./APIHelper"], function(
6
7
  HeaderLR,
@@ -1,6 +1,7 @@
1
1
  /*
2
- * ! SAPUI5
3
- * (c) Copyright 2009-2022 SAP SE. All rights reserved.
2
+ * ! SAP UI development toolkit for HTML5 (SAPUI5)
3
+ (c) Copyright 2009-2021 SAP SE. All rights reserved
4
+
4
5
  */
5
6
  sap.ui.define(
6
7
  [
@@ -1,6 +1,7 @@
1
1
  /*
2
- * ! SAPUI5
3
- * (c) Copyright 2009-2022 SAP SE. All rights reserved.
2
+ * ! SAP UI development toolkit for HTML5 (SAPUI5)
3
+ (c) Copyright 2009-2021 SAP SE. All rights reserved
4
+
4
5
  */
5
6
  sap.ui.define(
6
7
  [
@@ -1,6 +1,7 @@
1
1
  /*
2
- * ! SAPUI5
3
- * (c) Copyright 2009-2022 SAP SE. All rights reserved.
2
+ * ! SAP UI development toolkit for HTML5 (SAPUI5)
3
+ (c) Copyright 2009-2021 SAP SE. All rights reserved
4
+
4
5
  */
5
6
  sap.ui.define(
6
7
  [
@@ -1,6 +1,7 @@
1
1
  /*
2
- * ! SAPUI5
3
- * (c) Copyright 2009-2022 SAP SE. All rights reserved.
2
+ * ! SAP UI development toolkit for HTML5 (SAPUI5)
3
+ (c) Copyright 2009-2021 SAP SE. All rights reserved
4
+
4
5
  */
5
6
  sap.ui.define(["./BaseAPI", "sap/fe/test/Utils", "sap/fe/test/builder/KPIBuilder"], function(BaseAPI, Utils, KPIBuilder) {
6
7
  "use strict";
@@ -0,0 +1,43 @@
1
+ /*
2
+ * ! SAP UI development toolkit for HTML5 (SAPUI5)
3
+ (c) Copyright 2009-2021 SAP SE. All rights reserved
4
+
5
+ */
6
+ sap.ui.define(["./KPICardAPI", "sap/fe/test/Utils", "sap/fe/test/builder/FEBuilder"], function(KPICardAPI, Utils, FEBuilder) {
7
+ "use strict";
8
+
9
+ /**
10
+ * Constructs a new TableAssertions instance.
11
+ *
12
+ * @param {sap.fe.test.builder.KPIBuilder} oBuilderInstance The builder instance used to interact with the UI
13
+ * @returns {sap.fe.test.api.KPICardAssertions} The new instance
14
+ * @class
15
+ * @extends sap.fe.test.api.KPICardAPI
16
+ * @hideconstructor
17
+ * @public
18
+ */
19
+ var KPICardActions = function(oBuilderInstance) {
20
+ return KPICardAPI.call(this, oBuilderInstance);
21
+ };
22
+ KPICardActions.prototype = Object.create(KPICardAPI.prototype);
23
+ KPICardActions.prototype.constructor = KPICardActions;
24
+ KPICardActions.prototype.isAction = true;
25
+
26
+ /**
27
+ * Clicks on the header of the KPI Card.
28
+ *
29
+ * @returns {object} The result of the {@link sap.ui.test.Opa5#waitFor} function, to be used for chained statements
30
+ */
31
+ KPICardActions.prototype.iClickHeader = function() {
32
+ var oKPIBuilder = this.getBuilder();
33
+
34
+ return this.prepareResult(
35
+ oKPIBuilder
36
+ .doClickKPICardHeader()
37
+ .description("Clicking KPI card header")
38
+ .execute()
39
+ );
40
+ };
41
+
42
+ return KPICardActions;
43
+ });
@@ -1,6 +1,7 @@
1
1
  /*
2
- * ! SAPUI5
3
- * (c) Copyright 2009-2022 SAP SE. All rights reserved.
2
+ * ! SAP UI development toolkit for HTML5 (SAPUI5)
3
+ (c) Copyright 2009-2021 SAP SE. All rights reserved
4
+
4
5
  */
5
6
  sap.ui.define(["./KPICardAPI", "sap/fe/test/Utils", "sap/fe/test/builder/FEBuilder"], function(KPICardAPI, Utils, FEBuilder) {
6
7
  "use strict";
@@ -124,10 +125,10 @@ sap.ui.define(["./KPICardAPI", "sap/fe/test/Utils", "sap/fe/test/builder/FEBuild
124
125
  KPICardAssertions.prototype.iSeeHeaderValue = function(sValue, mStates) {
125
126
  var oKPIBuilder = this.getBuilder();
126
127
  var oProperties = mStates || {};
127
- oProperties.value = sValue;
128
+ oProperties.number = sValue;
128
129
 
129
130
  var vTitleMatcher = FEBuilder.create(this)
130
- .hasType("sap.m.NumericContent")
131
+ .hasType("sap.f.cards.NumericIndicators")
131
132
  .hasProperties(oProperties);
132
133
 
133
134
  var sDescription = mStates
@@ -153,21 +154,25 @@ sap.ui.define(["./KPICardAPI", "sap/fe/test/Utils", "sap/fe/test/builder/FEBuild
153
154
  var oKPIBuilder = this.getBuilder();
154
155
 
155
156
  var vIndicatorMatcher = FEBuilder.create(this)
156
- .hasType("sap.f.cards.NumericSideIndicator")
157
+ .hasType("sap.f.cards.NumericIndicators")
157
158
  .hasChildren(
158
159
  FEBuilder.create(this)
159
- .hasType("sap.m.Text")
160
- .hasProperties({ text: sTitle })
161
- )
162
- .hasChildren(
163
- FEBuilder.create(this)
164
- .hasType("sap.m.Text")
165
- .hasProperties({ text: sValue })
166
- )
167
- .hasChildren(
168
- FEBuilder.create(this)
169
- .hasType("sap.m.Text")
170
- .hasProperties({ text: sUnit })
160
+ .hasType("sap.f.cards.NumericSideIndicator")
161
+ .hasChildren(
162
+ FEBuilder.create(this)
163
+ .hasType("sap.m.Text")
164
+ .hasProperties({ text: sTitle })
165
+ )
166
+ .hasChildren(
167
+ FEBuilder.create(this)
168
+ .hasType("sap.m.Text")
169
+ .hasProperties({ text: sTitle })
170
+ )
171
+ .hasChildren(
172
+ FEBuilder.create(this)
173
+ .hasType("sap.m.Text")
174
+ .hasProperties({ text: sValue })
175
+ )
171
176
  );
172
177
 
173
178
  return this.prepareResult(
@@ -1,6 +1,7 @@
1
1
  /*
2
- * ! SAPUI5
3
- * (c) Copyright 2009-2022 SAP SE. All rights reserved.
2
+ * ! SAP UI development toolkit for HTML5 (SAPUI5)
3
+ (c) Copyright 2009-2021 SAP SE. All rights reserved
4
+
4
5
  */
5
6
  sap.ui.define(
6
7
  [
@@ -1,6 +1,7 @@
1
1
  /*
2
- * ! SAPUI5
3
- * (c) Copyright 2009-2022 SAP SE. All rights reserved.
2
+ * ! SAP UI development toolkit for HTML5 (SAPUI5)
3
+ (c) Copyright 2009-2021 SAP SE. All rights reserved
4
+
4
5
  */
5
6
  sap.ui.define(
6
7
  [
@@ -399,25 +400,6 @@ sap.ui.define(
399
400
  );
400
401
  };
401
402
 
402
- /**
403
- * Executes the <code>Paste</code> action on the table.
404
- *
405
- * @returns {object} The result of the {@link sap.ui.test.Opa5#waitFor} function, to be used for chained statements
406
- *
407
- * @public
408
- */
409
- Actions.prototype.iExecutePaste = function() {
410
- var oTableBuilder = this.getBuilder(),
411
- sPasteId = "::StandardAction::Paste";
412
-
413
- return this.prepareResult(
414
- oTableBuilder
415
- .doExecuteAction(FEBuilder.Matchers.id(new RegExp(Utils.formatMessage("{0}$", sPasteId))))
416
- .description(Utils.formatMessage("Pressing paste action of table '{0}'", this.getIdentifier()))
417
- .execute()
418
- );
419
- };
420
-
421
403
  /**
422
404
  * Executes the <code>Fullscreen</code> action on the table.
423
405
  *
@@ -597,7 +579,7 @@ sap.ui.define(
597
579
  };
598
580
 
599
581
  /**
600
- * Selects the variant of the given name.
582
+ * Selects the chosen variant.
601
583
  *
602
584
  * @param {string} sVariantName The name of the variant to be selected
603
585
  * @returns {object} The result of the {@link sap.ui.test.Opa5#waitFor} function, to be used for chained statements
@@ -1,6 +1,7 @@
1
1
  /*
2
- * ! SAPUI5
3
- * (c) Copyright 2009-2022 SAP SE. All rights reserved.
2
+ * ! SAP UI development toolkit for HTML5 (SAPUI5)
3
+ (c) Copyright 2009-2021 SAP SE. All rights reserved
4
+
4
5
  */
5
6
  sap.ui.define(
6
7
  [
@@ -356,15 +357,14 @@ sap.ui.define(
356
357
  };
357
358
 
358
359
  /**
359
- * Checks the <code>Paste</code> action of the table.
360
+ * Checks whether the paste button is available for the table.
360
361
  *
361
- * @param {object} [mState] Defines the expected state of the button
362
362
  * @returns {object} The result of the {@link sap.ui.test.Opa5#waitFor} function, to be used for chained statements
363
363
  *
364
364
  * @public
365
365
  */
366
- TableAssertions.prototype.iCheckPaste = function(mState) {
367
- return this.iCheckAction({ service: "StandardAction", action: "Paste", unbound: true }, mState);
366
+ TableAssertions.prototype.iCheckPaste = function() {
367
+ return this._iCheckTableProvidedAction("Paste");
368
368
  };
369
369
 
370
370
  /**
@@ -691,6 +691,17 @@ sap.ui.define(
691
691
  );
692
692
  };
693
693
 
694
+ TableAssertions.prototype.iCheckTitle = function(sTitle) {
695
+ var oTableBuilder = this.getBuilder();
696
+
697
+ return this.prepareResult(
698
+ oTableBuilder
699
+ .hasTitle(sTitle)
700
+ .description(Utils.formatMessage("Checking table '{0}' has title '{1}'", this.getIdentifier(), sTitle))
701
+ .execute()
702
+ );
703
+ };
704
+
694
705
  return TableAssertions;
695
706
  }
696
707
  );
@@ -1,6 +1,7 @@
1
1
  /*
2
- * ! SAPUI5
3
- * (c) Copyright 2009-2022 SAP SE. All rights reserved.
2
+ * ! SAP UI development toolkit for HTML5 (SAPUI5)
3
+ (c) Copyright 2009-2021 SAP SE. All rights reserved
4
+
4
5
  */
5
6
  sap.ui.define(["./FEBuilder", "./OverflowToolbarBuilder", "sap/ui/test/OpaBuilder", "sap/fe/test/Utils"], function(
6
7
  FEBuilder,
@@ -1,6 +1,7 @@
1
1
  /*
2
- * ! SAPUI5
3
- * (c) Copyright 2009-2022 SAP SE. All rights reserved.
2
+ * ! SAP UI development toolkit for HTML5 (SAPUI5)
3
+ (c) Copyright 2009-2021 SAP SE. All rights reserved
4
+
4
5
  */
5
6
  sap.ui.define(
6
7
  [