@digital-ai/devops-page-object-release 0.0.25 → 0.0.26
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.
- package/CHANGELOG.md +7 -0
- package/dist/main.js +580 -44
- package/dist/main.js.map +1 -1
- package/dist/module.js +580 -44
- package/dist/module.js.map +1 -1
- package/dist/types.d.ts +158 -24
- package/dist/types.d.ts.map +1 -1
- package/package.json +1 -1
package/dist/main.js
CHANGED
|
@@ -966,6 +966,7 @@ class $f8721861c660dd88$export$2b65d1d97338f32b {
|
|
|
966
966
|
class $3d3f3946c54f5897$export$34addcca3f0ae43f extends (0, $f8721861c660dd88$export$2b65d1d97338f32b) {
|
|
967
967
|
constructor(page){
|
|
968
968
|
super(page);
|
|
969
|
+
this.releaseForm = this.page.locator("#release-properties .form-group");
|
|
969
970
|
}
|
|
970
971
|
async setName(releaseName) {
|
|
971
972
|
await this.page.locator("#release-form-title").click();
|
|
@@ -1012,6 +1013,14 @@ class $3d3f3946c54f5897$export$34addcca3f0ae43f extends (0, $f8721861c660dd88$ex
|
|
|
1012
1013
|
await this.page.locator(`#form-${variableName} .display`).click();
|
|
1013
1014
|
await this.page.locator(`input[name="${variableName}"]`).fill(value);
|
|
1014
1015
|
}
|
|
1016
|
+
async setVariable(variable, value) {
|
|
1017
|
+
await this.releaseForm.filter({
|
|
1018
|
+
hasText: variable
|
|
1019
|
+
}).locator("div[inline-text-editor]").click();
|
|
1020
|
+
await this.releaseForm.filter({
|
|
1021
|
+
hasText: variable
|
|
1022
|
+
}).locator("div[inline-text-editor] input").fill(value);
|
|
1023
|
+
}
|
|
1015
1024
|
}
|
|
1016
1025
|
|
|
1017
1026
|
|
|
@@ -1217,7 +1226,7 @@ class $880df57ffbf6e614$export$9b575f14aa5e09a1 extends (0, $f8721861c660dd88$ex
|
|
|
1217
1226
|
}
|
|
1218
1227
|
|
|
1219
1228
|
|
|
1220
|
-
class $
|
|
1229
|
+
class $59543fc69900e8db$export$f8e64fcf447db2bf extends (0, $f8721861c660dd88$export$2b65d1d97338f32b) {
|
|
1221
1230
|
constructor(page){
|
|
1222
1231
|
super(page);
|
|
1223
1232
|
this.addListValue = this.page.locator(".variable-selector .xl-components-input-full input");
|
|
@@ -1229,7 +1238,7 @@ class $fd4eef3ad2b2e612$export$a87f0ae8695e74be extends (0, $f8721861c660dd88$ex
|
|
|
1229
1238
|
}
|
|
1230
1239
|
async openVariable(variableKey) {
|
|
1231
1240
|
await this.page.locator(`.variables-list .variable`).getByText(variableKey).click();
|
|
1232
|
-
return new $
|
|
1241
|
+
return new $59543fc69900e8db$var$VariableModal(this.page);
|
|
1233
1242
|
}
|
|
1234
1243
|
async addNewVariable(variableName, labelname, description) {
|
|
1235
1244
|
await this.page.locator("#action-toolbar").getByTestId("dot-button").click();
|
|
@@ -1318,14 +1327,16 @@ class $fd4eef3ad2b2e612$export$a87f0ae8695e74be extends (0, $f8721861c660dd88$ex
|
|
|
1318
1327
|
(0, $kKeXs$playwrighttest.expect)(rowLocator.toString()).toContain(type);
|
|
1319
1328
|
}
|
|
1320
1329
|
async clickEditVariable(variableName) {
|
|
1321
|
-
await this.page.locator("
|
|
1322
|
-
|
|
1323
|
-
|
|
1330
|
+
await this.page.locator(".data-row").filter({
|
|
1331
|
+
hasText: variableName
|
|
1332
|
+
}).getByText("Edit").first().click();
|
|
1333
|
+
return new $59543fc69900e8db$var$VariableModal(this.page);
|
|
1324
1334
|
}
|
|
1325
1335
|
async clickDeleteVariable(variableName) {
|
|
1326
|
-
await this.page.locator("
|
|
1327
|
-
|
|
1328
|
-
|
|
1336
|
+
await this.page.locator(".data-row").filter({
|
|
1337
|
+
hasText: variableName
|
|
1338
|
+
}).locator(".action .delete-icon").first().click();
|
|
1339
|
+
return new $59543fc69900e8db$var$DeleteVariableModel(this.page);
|
|
1329
1340
|
}
|
|
1330
1341
|
async expectVariablesCountToBe(count) {
|
|
1331
1342
|
await (0, $kKeXs$playwrighttest.expect)(this.page.locator(".variable .data-row")).toHaveCount(count);
|
|
@@ -1335,7 +1346,7 @@ class $fd4eef3ad2b2e612$export$a87f0ae8695e74be extends (0, $f8721861c660dd88$ex
|
|
|
1335
1346
|
hasText: variableName
|
|
1336
1347
|
})).not.toBeVisible();
|
|
1337
1348
|
}
|
|
1338
|
-
async
|
|
1349
|
+
async clearReleaseVariableSearch() {
|
|
1339
1350
|
await this.page.locator("[id='variables-filter']").clear();
|
|
1340
1351
|
}
|
|
1341
1352
|
async switchPossibleValuesToVariable(variableName) {
|
|
@@ -1356,8 +1367,14 @@ class $fd4eef3ad2b2e612$export$a87f0ae8695e74be extends (0, $f8721861c660dd88$ex
|
|
|
1356
1367
|
if (required) await this.page.getByRole("checkbox").check();
|
|
1357
1368
|
else await this.page.getByRole("checkbox").uncheck();
|
|
1358
1369
|
}
|
|
1370
|
+
async searchFolderVariable(variableName) {
|
|
1371
|
+
await this.page.locator(".searchFilter").fill(variableName);
|
|
1372
|
+
}
|
|
1373
|
+
async clearFolderVarSearch() {
|
|
1374
|
+
await this.page.locator(".searchFilter").clear();
|
|
1375
|
+
}
|
|
1359
1376
|
}
|
|
1360
|
-
class $
|
|
1377
|
+
class $59543fc69900e8db$var$VariableModal extends (0, $f8721861c660dd88$export$2b65d1d97338f32b) {
|
|
1361
1378
|
constructor(page){
|
|
1362
1379
|
super(page);
|
|
1363
1380
|
this.dateUtil = new (0, $880df57ffbf6e614$export$9b575f14aa5e09a1)(page);
|
|
@@ -1400,8 +1417,8 @@ class $fd4eef3ad2b2e612$var$ReleaseVariableModal extends (0, $f8721861c660dd88$e
|
|
|
1400
1417
|
if (possiblevalue instanceof Array) for (const value of possiblevalue)(0, $kKeXs$playwrighttest.expect)(listLocator).toContain(value);
|
|
1401
1418
|
else (0, $kKeXs$playwrighttest.expect)(listLocator).toContain(possiblevalue);
|
|
1402
1419
|
}
|
|
1403
|
-
async expectPossibleVariableValues(
|
|
1404
|
-
await (0, $kKeXs$playwrighttest.expect)(this.page.locator(".variable-dropdown input")).toHaveValue(
|
|
1420
|
+
async expectPossibleVariableValues(possibleVariableValue) {
|
|
1421
|
+
await (0, $kKeXs$playwrighttest.expect)(this.page.locator(".variable-dropdown input")).toHaveValue(possibleVariableValue);
|
|
1405
1422
|
}
|
|
1406
1423
|
async addPossibleValue(value) {
|
|
1407
1424
|
if (value instanceof Array) for (const li of value){
|
|
@@ -1449,7 +1466,7 @@ class $fd4eef3ad2b2e612$var$ReleaseVariableModal extends (0, $f8721861c660dd88$e
|
|
|
1449
1466
|
await (0, $kKeXs$playwrighttest.expect)(this.page.locator("#modal .variable-label input")).toHaveValue(value);
|
|
1450
1467
|
}
|
|
1451
1468
|
async expectRequired(value) {
|
|
1452
|
-
if (value
|
|
1469
|
+
if (value) await (0, $kKeXs$playwrighttest.expect)(this.page.locator('.form-group input[ng-model="var.requiresValue"]')).toBeChecked();
|
|
1453
1470
|
else await (0, $kKeXs$playwrighttest.expect)(this.page.locator('.form-group input[ng-model="var.requiresValue"]')).not.toBeChecked();
|
|
1454
1471
|
}
|
|
1455
1472
|
async setDescription(description) {
|
|
@@ -1467,11 +1484,17 @@ class $fd4eef3ad2b2e612$var$ReleaseVariableModal extends (0, $f8721861c660dd88$e
|
|
|
1467
1484
|
async setValue(value) {
|
|
1468
1485
|
await this.page.locator(".variable-value input").fill(value);
|
|
1469
1486
|
}
|
|
1487
|
+
async clickMultiline() {
|
|
1488
|
+
await this.page.locator("#multiline").click();
|
|
1489
|
+
}
|
|
1490
|
+
async setValueForMultilinePassword(value) {
|
|
1491
|
+
await this.page.locator(".password-textarea").fill(value);
|
|
1492
|
+
}
|
|
1470
1493
|
}
|
|
1471
|
-
class $
|
|
1494
|
+
class $59543fc69900e8db$var$DeleteVariableModel extends (0, $f8721861c660dd88$export$2b65d1d97338f32b) {
|
|
1472
1495
|
constructor(page){
|
|
1473
1496
|
super(page);
|
|
1474
|
-
this.model = new $
|
|
1497
|
+
this.model = new $59543fc69900e8db$var$VariableModal(page);
|
|
1475
1498
|
this.dateUtil = new (0, $880df57ffbf6e614$export$9b575f14aa5e09a1)(page);
|
|
1476
1499
|
}
|
|
1477
1500
|
async deleteVariable() {
|
|
@@ -1674,7 +1697,7 @@ class $eb81c1b930e440ff$export$519356f6c50361f7 extends (0, $f8721861c660dd88$ex
|
|
|
1674
1697
|
}).click();
|
|
1675
1698
|
}
|
|
1676
1699
|
async setVariable(propertyName, variableName) {
|
|
1677
|
-
|
|
1700
|
+
await this.railLocator.locator(`input[id="${propertyName}"]`).fill(variableName);
|
|
1678
1701
|
}
|
|
1679
1702
|
async expectValueFromString(propertyName, propertyValue) {
|
|
1680
1703
|
return await (0, $kKeXs$playwrighttest.expect)(this.railLocator.locator(`.input-scalar-fake-input[id="${propertyName}"]`)).toHaveText(propertyValue);
|
|
@@ -1739,8 +1762,7 @@ class $eb81c1b930e440ff$export$519356f6c50361f7 extends (0, $f8721861c660dd88$ex
|
|
|
1739
1762
|
}
|
|
1740
1763
|
async getDependencyCount() {
|
|
1741
1764
|
await (0, $kKeXs$playwrighttest.expect)(this.railLocator.locator(".gate-task-dependencies")).toBeVisible();
|
|
1742
|
-
|
|
1743
|
-
return count;
|
|
1765
|
+
return await this.railLocator.locator(".gate-task-dependencies .dependency").count();
|
|
1744
1766
|
}
|
|
1745
1767
|
async addDependency() {
|
|
1746
1768
|
await (0, $kKeXs$playwrighttest.expect)(this.railLocator.locator(".add-dependency-btn")).toBeVisible();
|
|
@@ -1783,6 +1805,84 @@ class $eb81c1b930e440ff$export$519356f6c50361f7 extends (0, $f8721861c660dd88$ex
|
|
|
1783
1805
|
}).click();
|
|
1784
1806
|
await (0, $kKeXs$playwrighttest.expect)(this.page.locator(".phase-link-container").locator(".variable").first()).toHaveText(expectedDescription);
|
|
1785
1807
|
}
|
|
1808
|
+
async setReleaseTitle(releaseName) {
|
|
1809
|
+
await this.page.getByLabel("Release title *").fill(releaseName);
|
|
1810
|
+
}
|
|
1811
|
+
async setFolder(folderName) {
|
|
1812
|
+
await this.page.getByPlaceholder("Select a folder").click();
|
|
1813
|
+
await this.page.getByPlaceholder("Search folder...").fill(folderName);
|
|
1814
|
+
await this.page.getByRole("button", {
|
|
1815
|
+
name: folderName
|
|
1816
|
+
}).click();
|
|
1817
|
+
}
|
|
1818
|
+
async setTemplate(templateName) {
|
|
1819
|
+
await this.page.getByLabel("Template").click();
|
|
1820
|
+
await this.page.getByLabel("Template").fill(templateName);
|
|
1821
|
+
await this.page.getByRole("option", {
|
|
1822
|
+
name: templateName
|
|
1823
|
+
}).click();
|
|
1824
|
+
}
|
|
1825
|
+
async clearTemplate() {
|
|
1826
|
+
await this.page.locator("#templateId").click();
|
|
1827
|
+
await this.page.locator("#templateId").clear();
|
|
1828
|
+
}
|
|
1829
|
+
async errorMsgVisible(errorMessage) {
|
|
1830
|
+
await (0, $kKeXs$playwrighttest.expect)(this.page.locator("#dialogTitle")).toContainText(errorMessage);
|
|
1831
|
+
}
|
|
1832
|
+
async isButtonVisible(buttonName, visible = true) {
|
|
1833
|
+
(0, $kKeXs$playwrighttest.expect)(await this.page.getByRole("button", {
|
|
1834
|
+
name: buttonName
|
|
1835
|
+
}).isVisible()).toBe(visible);
|
|
1836
|
+
}
|
|
1837
|
+
async cancelDialogWindow() {
|
|
1838
|
+
await this.page.getByRole("button", {
|
|
1839
|
+
name: "cancel"
|
|
1840
|
+
}).click();
|
|
1841
|
+
}
|
|
1842
|
+
async acceptDialogWindow() {
|
|
1843
|
+
await this.page.getByRole("button", {
|
|
1844
|
+
name: "ok"
|
|
1845
|
+
}).click();
|
|
1846
|
+
}
|
|
1847
|
+
async setRiskProfile(RiskProfile) {
|
|
1848
|
+
await this.page.getByLabel("Risk profile").click();
|
|
1849
|
+
await this.page.getByLabel("Risk profile").fill(RiskProfile);
|
|
1850
|
+
await this.page.getByRole("option", {
|
|
1851
|
+
name: RiskProfile
|
|
1852
|
+
}).click();
|
|
1853
|
+
}
|
|
1854
|
+
async expectTemplate(template) {
|
|
1855
|
+
const templateName = await this.page.locator("#templateId").getAttribute("value");
|
|
1856
|
+
(0, $kKeXs$playwrighttest.expect)(templateName).toEqual(template);
|
|
1857
|
+
}
|
|
1858
|
+
async setAutoCompletePassword(passwordValue) {
|
|
1859
|
+
await this.page.getByTestId("password").getByLabel("Click to switch between").click();
|
|
1860
|
+
await this.page.locator("#password").fill(passwordValue);
|
|
1861
|
+
await this.page.getByRole("option", {
|
|
1862
|
+
name: passwordValue
|
|
1863
|
+
}).click();
|
|
1864
|
+
}
|
|
1865
|
+
async setAutoCompleteField(fieldLabel, value) {
|
|
1866
|
+
await this.page.getByLabel(fieldLabel).click();
|
|
1867
|
+
await this.page.getByLabel(fieldLabel).fill(value);
|
|
1868
|
+
await this.page.getByRole("option", {
|
|
1869
|
+
name: value
|
|
1870
|
+
}).click();
|
|
1871
|
+
}
|
|
1872
|
+
async setNewAutoCompleteField(fieldLabel, value) {
|
|
1873
|
+
await this.page.getByLabel(fieldLabel).click();
|
|
1874
|
+
await this.page.getByLabel(fieldLabel).fill(value);
|
|
1875
|
+
await this.page.getByTestId("dot-action-item-btn").click();
|
|
1876
|
+
}
|
|
1877
|
+
async setTextField(fieldID, value) {
|
|
1878
|
+
await this.page.locator(`[data-test-id="${fieldID}"]`).nth(1).click();
|
|
1879
|
+
await this.page.locator(`input[name='${fieldID}']`).fill(value);
|
|
1880
|
+
}
|
|
1881
|
+
async abortButtonVisibility(visible = true) {
|
|
1882
|
+
(0, $kKeXs$playwrighttest.expect)(await this.page.getByRole("button", {
|
|
1883
|
+
name: "Abort"
|
|
1884
|
+
}).isVisible()).toBe(visible);
|
|
1885
|
+
}
|
|
1786
1886
|
}
|
|
1787
1887
|
class $eb81c1b930e440ff$export$fbbf45eff21470e3 extends (0, $f8721861c660dd88$export$2b65d1d97338f32b) {
|
|
1788
1888
|
constructor(page){
|
|
@@ -1941,6 +2041,25 @@ class $f9016705c1a1eb20$export$aa59788fdecae2f2 extends (0, $f8721861c660dd88$ex
|
|
|
1941
2041
|
|
|
1942
2042
|
|
|
1943
2043
|
|
|
2044
|
+
|
|
2045
|
+
|
|
2046
|
+
class $1fbdec5dc9cde599$export$b7be47b40aa877fc extends (0, $f8721861c660dd88$export$2b65d1d97338f32b) {
|
|
2047
|
+
constructor(page){
|
|
2048
|
+
super(page);
|
|
2049
|
+
}
|
|
2050
|
+
async expectStartDateToBeDisplayed() {
|
|
2051
|
+
(0, $kKeXs$playwrighttest.expect)(await this.page.locator(".flex-section.column").filter({
|
|
2052
|
+
hasText: "Start Date"
|
|
2053
|
+
}).locator(".task-date-view-content").isVisible()).toBe(true);
|
|
2054
|
+
}
|
|
2055
|
+
async expectEndDateToBeDisplayed() {
|
|
2056
|
+
(0, $kKeXs$playwrighttest.expect)(await this.page.locator(".flex-section.column").filter({
|
|
2057
|
+
hasText: "End Date"
|
|
2058
|
+
}).locator(".task-date-view-content").isVisible()).toBe(true);
|
|
2059
|
+
}
|
|
2060
|
+
}
|
|
2061
|
+
|
|
2062
|
+
|
|
1944
2063
|
class $6a21661eb4695574$export$e946776eae644790 extends (0, $f8721861c660dd88$export$2b65d1d97338f32b) {
|
|
1945
2064
|
constructor(page){
|
|
1946
2065
|
super(page);
|
|
@@ -1967,7 +2086,8 @@ class $6a21661eb4695574$export$e946776eae644790 extends (0, $f8721861c660dd88$ex
|
|
|
1967
2086
|
exact: true
|
|
1968
2087
|
});
|
|
1969
2088
|
this.completeButton = this.page.getByRole("button", {
|
|
1970
|
-
name: "Complete"
|
|
2089
|
+
name: "Complete",
|
|
2090
|
+
exact: true
|
|
1971
2091
|
});
|
|
1972
2092
|
}
|
|
1973
2093
|
async openOverviewRail() {
|
|
@@ -1978,6 +2098,7 @@ class $6a21661eb4695574$export$e946776eae644790 extends (0, $f8721861c660dd88$ex
|
|
|
1978
2098
|
}
|
|
1979
2099
|
async openSchedulingRail() {
|
|
1980
2100
|
await this.openRail("Scheduling");
|
|
2101
|
+
return new (0, $1fbdec5dc9cde599$export$b7be47b40aa877fc)(this.page);
|
|
1981
2102
|
}
|
|
1982
2103
|
async openConditionRail() {
|
|
1983
2104
|
await this.openRail("Conditions");
|
|
@@ -2512,6 +2633,7 @@ class $2c89ba54932fbba8$export$f8f26dd395d7e1bd extends (0, $f8721861c660dd88$ex
|
|
|
2512
2633
|
|
|
2513
2634
|
|
|
2514
2635
|
class $9b9a8c3da392d020$export$f43492e8ac3c566 extends (0, $f8721861c660dd88$export$2b65d1d97338f32b) {
|
|
2636
|
+
defaultTimeout = 10000;
|
|
2515
2637
|
constructor(page){
|
|
2516
2638
|
super(page);
|
|
2517
2639
|
this.createPage = new (0, $3d3f3946c54f5897$export$34addcca3f0ae43f)(page);
|
|
@@ -2520,7 +2642,7 @@ class $9b9a8c3da392d020$export$f43492e8ac3c566 extends (0, $f8721861c660dd88$exp
|
|
|
2520
2642
|
this.teamsPermissions = new (0, $d330a7d6f7926d53$export$3bc3e140e0dcb075)(page);
|
|
2521
2643
|
this.phaseTitle = this.page.locator(".phase .phase-title");
|
|
2522
2644
|
this.properties = new (0, $8681d8a3f46f87b7$export$d1077068a9cc9f17)(page);
|
|
2523
|
-
this.variables = new (0, $
|
|
2645
|
+
this.variables = new (0, $59543fc69900e8db$export$f8e64fcf447db2bf)(page);
|
|
2524
2646
|
this.util = new (0, $2c89ba54932fbba8$export$f8f26dd395d7e1bd)(page);
|
|
2525
2647
|
}
|
|
2526
2648
|
async openTriggers() {
|
|
@@ -2559,74 +2681,78 @@ class $9b9a8c3da392d020$export$f43492e8ac3c566 extends (0, $f8721861c660dd88$exp
|
|
|
2559
2681
|
name: "Start"
|
|
2560
2682
|
}).click();
|
|
2561
2683
|
}
|
|
2562
|
-
async waitForCompletion(timeout) {
|
|
2684
|
+
async waitForCompletion(timeout = this.defaultTimeout) {
|
|
2563
2685
|
await this.page.locator("#release.completed").waitFor({
|
|
2564
2686
|
timeout: timeout
|
|
2565
2687
|
});
|
|
2566
2688
|
}
|
|
2567
|
-
async waitForTaskCompleted(taskTitle) {
|
|
2689
|
+
async waitForTaskCompleted(taskTitle, timeout = this.defaultTimeout) {
|
|
2568
2690
|
await (0, $kKeXs$playwrighttest.expect)(this.page.locator(".task.completed").getByText(taskTitle, {
|
|
2569
2691
|
exact: true
|
|
2570
2692
|
})).toBeVisible({
|
|
2571
|
-
timeout:
|
|
2693
|
+
timeout: timeout
|
|
2572
2694
|
});
|
|
2573
2695
|
}
|
|
2574
|
-
async waitForTaskCompletedInAdvance(taskTitle) {
|
|
2696
|
+
async waitForTaskCompletedInAdvance(taskTitle, timeout = this.defaultTimeout) {
|
|
2575
2697
|
await (0, $kKeXs$playwrighttest.expect)(this.page.locator(".task.completed_in_advance").getByText(taskTitle, {
|
|
2576
2698
|
exact: true
|
|
2577
2699
|
})).toBeVisible({
|
|
2578
|
-
timeout:
|
|
2700
|
+
timeout: timeout
|
|
2579
2701
|
});
|
|
2580
2702
|
}
|
|
2581
|
-
async waitForTaskInProgress(taskTitle) {
|
|
2703
|
+
async waitForTaskInProgress(taskTitle, timeout = this.defaultTimeout) {
|
|
2582
2704
|
await (0, $kKeXs$playwrighttest.expect)(this.page.locator(".task.in_progress").getByText(taskTitle, {
|
|
2583
2705
|
exact: true
|
|
2584
|
-
})).toBeVisible(
|
|
2706
|
+
})).toBeVisible({
|
|
2707
|
+
timeout: timeout
|
|
2708
|
+
});
|
|
2585
2709
|
}
|
|
2586
|
-
async waitForTaskFailed(taskTitle) {
|
|
2710
|
+
async waitForTaskFailed(taskTitle, timeout = this.defaultTimeout) {
|
|
2587
2711
|
await (0, $kKeXs$playwrighttest.expect)(this.page.locator(".task.failed").getByText(taskTitle, {
|
|
2588
2712
|
exact: true
|
|
2589
2713
|
})).toBeVisible({
|
|
2590
|
-
timeout:
|
|
2714
|
+
timeout: timeout
|
|
2591
2715
|
});
|
|
2592
2716
|
}
|
|
2593
|
-
async waitForTaskSkipped(taskTitle) {
|
|
2717
|
+
async waitForTaskSkipped(taskTitle, timeout = this.defaultTimeout) {
|
|
2594
2718
|
await (0, $kKeXs$playwrighttest.expect)(this.page.locator(".task.skipped").getByText(taskTitle, {
|
|
2595
2719
|
exact: true
|
|
2596
2720
|
})).toBeVisible({
|
|
2597
|
-
timeout:
|
|
2721
|
+
timeout: timeout
|
|
2598
2722
|
});
|
|
2599
2723
|
}
|
|
2600
|
-
async waitForTaskSkippedInAdvance(taskTitle) {
|
|
2724
|
+
async waitForTaskSkippedInAdvance(taskTitle, timeout = this.defaultTimeout) {
|
|
2601
2725
|
await (0, $kKeXs$playwrighttest.expect)(this.page.locator(".task.skipped_in_advance").getByText(taskTitle, {
|
|
2602
2726
|
exact: true
|
|
2603
2727
|
})).toBeVisible({
|
|
2604
|
-
timeout:
|
|
2728
|
+
timeout: timeout
|
|
2605
2729
|
});
|
|
2606
2730
|
}
|
|
2607
|
-
async waitForTaskAborted(taskTitle) {
|
|
2731
|
+
async waitForTaskAborted(taskTitle, timeout = this.defaultTimeout) {
|
|
2608
2732
|
await (0, $kKeXs$playwrighttest.expect)(this.page.locator(".task.aborted").getByText(taskTitle, {
|
|
2609
2733
|
exact: true
|
|
2610
2734
|
})).toBeVisible({
|
|
2611
|
-
timeout:
|
|
2735
|
+
timeout: timeout
|
|
2612
2736
|
});
|
|
2613
2737
|
}
|
|
2614
|
-
async waitForStatusLine(statusLine) {
|
|
2738
|
+
async waitForStatusLine(statusLine, timeout = this.defaultTimeout) {
|
|
2615
2739
|
await (0, $kKeXs$playwrighttest.expect)(this.page.locator(".task .status-line").getByText(statusLine, {
|
|
2616
2740
|
exact: true
|
|
2617
2741
|
})).toBeVisible({
|
|
2618
|
-
timeout:
|
|
2742
|
+
timeout: timeout
|
|
2619
2743
|
});
|
|
2620
2744
|
}
|
|
2621
|
-
async waitForTaskStarted(taskTitle) {
|
|
2745
|
+
async waitForTaskStarted(taskTitle, timeout = this.defaultTimeout) {
|
|
2622
2746
|
await (0, $kKeXs$playwrighttest.expect)(this.page.locator(".task.in_progress").getByTitle(taskTitle, {
|
|
2623
2747
|
exact: true
|
|
2624
2748
|
})).toBeVisible({
|
|
2625
|
-
timeout:
|
|
2749
|
+
timeout: timeout
|
|
2626
2750
|
});
|
|
2627
2751
|
}
|
|
2628
|
-
async waitForTaskPlanned(title) {
|
|
2629
|
-
await (0, $kKeXs$playwrighttest.expect)(this.page.locator(`.task:has-text('${title}').planned`)).toBeVisible(
|
|
2752
|
+
async waitForTaskPlanned(title, timeout = this.defaultTimeout) {
|
|
2753
|
+
await (0, $kKeXs$playwrighttest.expect)(this.page.locator(`.task:has-text('${title}').planned`)).toBeVisible({
|
|
2754
|
+
timeout: timeout
|
|
2755
|
+
});
|
|
2630
2756
|
}
|
|
2631
2757
|
async expectTaskCompletedInAdvance(taskTitle) {
|
|
2632
2758
|
await (0, $kKeXs$playwrighttest.expect)(this.page.locator("#release-content .completed_in_advance .task-title").filter({
|
|
@@ -2851,6 +2977,10 @@ class $9b9a8c3da392d020$export$f43492e8ac3c566 extends (0, $f8721861c660dd88$exp
|
|
|
2851
2977
|
async expectOnePhaseDisplayed() {
|
|
2852
2978
|
(0, $kKeXs$playwrighttest.expect)(await this.page.locator(".phase-content").count()).toBe(1);
|
|
2853
2979
|
}
|
|
2980
|
+
async restartPhases() {
|
|
2981
|
+
await this.page.getByTestId("restart-btn").click();
|
|
2982
|
+
return new $9b9a8c3da392d020$var$RestartPhaseModel(this.page);
|
|
2983
|
+
}
|
|
2854
2984
|
}
|
|
2855
2985
|
class $9b9a8c3da392d020$var$Phase extends (0, $f8721861c660dd88$export$2b65d1d97338f32b) {
|
|
2856
2986
|
constructor(page, phaseName){
|
|
@@ -3020,6 +3150,35 @@ class $9b9a8c3da392d020$var$Phase extends (0, $f8721861c660dd88$export$2b65d1d97
|
|
|
3020
3150
|
hasText: phaseName
|
|
3021
3151
|
})).not.toBeVisible();
|
|
3022
3152
|
}
|
|
3153
|
+
async expectCompletedPhase() {
|
|
3154
|
+
await (0, $kKeXs$playwrighttest.expect)(this.phaseLocator.locator("a")).toContainText("View all completed phases");
|
|
3155
|
+
}
|
|
3156
|
+
}
|
|
3157
|
+
class $9b9a8c3da392d020$var$RestartPhaseModel extends (0, $f8721861c660dd88$export$2b65d1d97338f32b) {
|
|
3158
|
+
constructor(page){
|
|
3159
|
+
super(page);
|
|
3160
|
+
this.continueBtn = this.page.getByRole("button", {
|
|
3161
|
+
name: "Continue"
|
|
3162
|
+
});
|
|
3163
|
+
}
|
|
3164
|
+
async fromPhase(phase) {
|
|
3165
|
+
await this.page.locator('.modal select[data-test="fromPhase"]').selectOption(phase);
|
|
3166
|
+
}
|
|
3167
|
+
async fromTask(task) {
|
|
3168
|
+
await this.page.locator('.modal select[data-test="fromTask"]').selectOption(task);
|
|
3169
|
+
}
|
|
3170
|
+
async expectNoTaskSelectorVisible() {
|
|
3171
|
+
(0, $kKeXs$playwrighttest.expect)(await this.page.locator('.modal select[data-test="fromTask"]').isVisible()).toHaveLength(0);
|
|
3172
|
+
}
|
|
3173
|
+
async continue() {
|
|
3174
|
+
await this.page.locator(".modal .continue").click();
|
|
3175
|
+
}
|
|
3176
|
+
async resumeNow() {
|
|
3177
|
+
await this.page.locator(".modal .resume-now").click();
|
|
3178
|
+
}
|
|
3179
|
+
async resumeLater() {
|
|
3180
|
+
await this.page.locator(".modal .resume-later").click();
|
|
3181
|
+
}
|
|
3023
3182
|
}
|
|
3024
3183
|
|
|
3025
3184
|
|
|
@@ -3497,6 +3656,7 @@ class $04ff53be95b7a0a4$export$32284f8bcf0bc407 extends (0, $f8721861c660dd88$ex
|
|
|
3497
3656
|
|
|
3498
3657
|
|
|
3499
3658
|
|
|
3659
|
+
|
|
3500
3660
|
class $9058d40a81bdb1f5$export$b453f08936c58edb extends (0, $f8721861c660dd88$export$2b65d1d97338f32b) {
|
|
3501
3661
|
constructor(page){
|
|
3502
3662
|
super(page);
|
|
@@ -3508,6 +3668,7 @@ class $9058d40a81bdb1f5$export$b453f08936c58edb extends (0, $f8721861c660dd88$ex
|
|
|
3508
3668
|
this.notificationPage = new (0, $04ff53be95b7a0a4$export$32284f8bcf0bc407)(page);
|
|
3509
3669
|
this.patternPage = new (0, $ceb2e9e08e1837c2$export$9b9454a7f137e99b)(page);
|
|
3510
3670
|
this.util = new (0, $2c89ba54932fbba8$export$f8f26dd395d7e1bd)(page);
|
|
3671
|
+
this.variables = new (0, $59543fc69900e8db$export$f8e64fcf447db2bf)(page);
|
|
3511
3672
|
}
|
|
3512
3673
|
async openFoldersPage() {
|
|
3513
3674
|
await this.page.goto("./#/folders");
|
|
@@ -3649,6 +3810,22 @@ class $9058d40a81bdb1f5$export$b453f08936c58edb extends (0, $f8721861c660dd88$ex
|
|
|
3649
3810
|
await this.util.openSideNavMenu("Templates");
|
|
3650
3811
|
await (0, $kKeXs$playwrighttest.expect)(this.page.getByLabel("breadcrumb").getByText("Templates")).toBeVisible();
|
|
3651
3812
|
}
|
|
3813
|
+
async openRelease() {
|
|
3814
|
+
await this.util.openSideNavMenu("Releases");
|
|
3815
|
+
await (0, $kKeXs$playwrighttest.expect)(this.page.getByLabel("breadcrumb").getByText("Releases")).toBeVisible();
|
|
3816
|
+
}
|
|
3817
|
+
async expectReleaseStarted(releaseName) {
|
|
3818
|
+
await (0, $kKeXs$playwrighttest.expect)(this.page.locator(".release").filter({
|
|
3819
|
+
hasText: releaseName
|
|
3820
|
+
}).locator(".release-status").filter({
|
|
3821
|
+
hasText: "In progress"
|
|
3822
|
+
})).toBeVisible();
|
|
3823
|
+
}
|
|
3824
|
+
async openVariables() {
|
|
3825
|
+
await this.util.openSideNavMenu("Variables");
|
|
3826
|
+
await (0, $kKeXs$playwrighttest.expect)(this.page.getByLabel("breadcrumb").getByText("Variables")).toBeVisible();
|
|
3827
|
+
return this.variables;
|
|
3828
|
+
}
|
|
3652
3829
|
}
|
|
3653
3830
|
|
|
3654
3831
|
|
|
@@ -4793,6 +4970,327 @@ class $3fad6a9449b6416f$export$1a0994e9c202d529 extends (0, $f8721861c660dd88$ex
|
|
|
4793
4970
|
|
|
4794
4971
|
|
|
4795
4972
|
|
|
4973
|
+
class $fd4eef3ad2b2e612$export$a87f0ae8695e74be extends (0, $f8721861c660dd88$export$2b65d1d97338f32b) {
|
|
4974
|
+
constructor(page){
|
|
4975
|
+
super(page);
|
|
4976
|
+
this.addListValue = this.page.locator(".variable-selector .xl-components-input-full input");
|
|
4977
|
+
this.addVariableValue = this.page.locator(".variable-value .xl-components-input-full input");
|
|
4978
|
+
this.dateUtil = new (0, $880df57ffbf6e614$export$9b575f14aa5e09a1)(page);
|
|
4979
|
+
this.listAddButton = this.page.getByRole("button", {
|
|
4980
|
+
name: "Add"
|
|
4981
|
+
});
|
|
4982
|
+
}
|
|
4983
|
+
async openVariable(variableKey) {
|
|
4984
|
+
await this.page.locator(`.variables-list .variable`).getByText(variableKey).click();
|
|
4985
|
+
return new $fd4eef3ad2b2e612$var$ReleaseVariableModal(this.page);
|
|
4986
|
+
}
|
|
4987
|
+
async addNewVariable(variableName, labelname, description) {
|
|
4988
|
+
await this.page.locator("#action-toolbar").getByTestId("dot-button").click();
|
|
4989
|
+
await this.page.fill(`[name="fieldKey"]`, variableName);
|
|
4990
|
+
await this.page.locator(".variable-label input").fill(labelname);
|
|
4991
|
+
if (description) await this.page.locator(".variable-description input").fill(description);
|
|
4992
|
+
}
|
|
4993
|
+
async selectVariableTextType(valuename) {
|
|
4994
|
+
await this.page.getByRole("combobox").selectOption("StringVariable");
|
|
4995
|
+
await this.page.locator(".variable-value").type(valuename);
|
|
4996
|
+
}
|
|
4997
|
+
async selectVariableListboxType(possiblevalue, defaultValue, required) {
|
|
4998
|
+
await this.page.getByRole("combobox").selectOption("DropDownListBox");
|
|
4999
|
+
if (possiblevalue instanceof Array) for (const value of possiblevalue){
|
|
5000
|
+
await this.addListValue.fill(value);
|
|
5001
|
+
await this.listAddButton.click();
|
|
5002
|
+
}
|
|
5003
|
+
else {
|
|
5004
|
+
await this.addListValue.fill(possiblevalue);
|
|
5005
|
+
await this.listAddButton.click();
|
|
5006
|
+
}
|
|
5007
|
+
await this.page.locator(".variable-value select").type(defaultValue);
|
|
5008
|
+
if (required) await this.page.getByRole("checkbox").check();
|
|
5009
|
+
else await this.page.getByRole("checkbox").uncheck();
|
|
5010
|
+
}
|
|
5011
|
+
async selectVariablePasswordType(possiblevalue) {
|
|
5012
|
+
await this.page.getByRole("combobox").selectOption("PasswordStringVariable");
|
|
5013
|
+
await this.page.locator('input[type="password"]').type(possiblevalue);
|
|
5014
|
+
}
|
|
5015
|
+
async selectVariableCheckboxType() {
|
|
5016
|
+
await this.page.getByRole("combobox").selectOption("BooleanVariable");
|
|
5017
|
+
await this.page.getByRole("checkbox").check();
|
|
5018
|
+
}
|
|
5019
|
+
async selectVariableNumberType(possiblevalue) {
|
|
5020
|
+
await this.page.getByRole("combobox").selectOption("IntegerVariable");
|
|
5021
|
+
await this.page.locator('input[ng-model="var.value"]').fill(possiblevalue);
|
|
5022
|
+
}
|
|
5023
|
+
async selectVariableMultiListType(possiblevalue1, possiblevalue2) {
|
|
5024
|
+
await this.page.getByRole("combobox").selectOption("MultiSelectListBox");
|
|
5025
|
+
await this.addListValue.fill(possiblevalue1);
|
|
5026
|
+
await this.listAddButton.click();
|
|
5027
|
+
await this.addListValue.fill(possiblevalue2);
|
|
5028
|
+
await this.listAddButton.click();
|
|
5029
|
+
await this.page.locator(".react-tagsinput").click();
|
|
5030
|
+
await this.page.getByText("Select all", {
|
|
5031
|
+
exact: true
|
|
5032
|
+
}).click();
|
|
5033
|
+
}
|
|
5034
|
+
async addVariableDate() {
|
|
5035
|
+
await this.page.getByRole("combobox").selectOption("DateVariable");
|
|
5036
|
+
await this.page.getByText("Select date").click();
|
|
5037
|
+
}
|
|
5038
|
+
async setDate(date, monthYear) {
|
|
5039
|
+
await this.dateUtil.setDate(date, monthYear);
|
|
5040
|
+
}
|
|
5041
|
+
async addVariableKeyValueMap(keys1, values1) {
|
|
5042
|
+
await this.page.getByRole("combobox").selectOption("MapStringStringVariable");
|
|
5043
|
+
await this.page.getByPlaceholder("key").fill(keys1);
|
|
5044
|
+
await this.page.getByPlaceholder("Value").fill(values1);
|
|
5045
|
+
await this.listAddButton.click();
|
|
5046
|
+
await this.page.locator(".xl-map-string-string-div-buttons .search-icon").click();
|
|
5047
|
+
await this.page.getByRole("row", {
|
|
5048
|
+
name: "Search"
|
|
5049
|
+
}).getByRole("textbox").fill(keys1);
|
|
5050
|
+
const detail = await this.page.locator("table.table-condensed span").allInnerTexts();
|
|
5051
|
+
(0, $kKeXs$playwrighttest.expect)(detail[0]).toEqual(keys1);
|
|
5052
|
+
(0, $kKeXs$playwrighttest.expect)(detail[1]).toEqual(values1);
|
|
5053
|
+
}
|
|
5054
|
+
async addVariableSet(possiblevalue1) {
|
|
5055
|
+
await this.page.getByRole("combobox").selectOption("SetStringVariable");
|
|
5056
|
+
await this.page.locator(".dip-input input").fill(possiblevalue1);
|
|
5057
|
+
await this.listAddButton.click();
|
|
5058
|
+
}
|
|
5059
|
+
async submitTheVariable() {
|
|
5060
|
+
const createButton = this.page.locator(".modal-footer .save");
|
|
5061
|
+
await (0, $kKeXs$playwrighttest.expect)(createButton).toBeEnabled();
|
|
5062
|
+
await createButton.scrollIntoViewIfNeeded();
|
|
5063
|
+
await createButton.click();
|
|
5064
|
+
// Expect is needed here to avoid flackiness on clicking create button
|
|
5065
|
+
await (0, $kKeXs$playwrighttest.expect)(createButton).not.toBeVisible();
|
|
5066
|
+
}
|
|
5067
|
+
async expectVariableWithNameValueAndType(name, value, type) {
|
|
5068
|
+
const rowLocator = await this.page.locator(".variable .data-row").allTextContents();
|
|
5069
|
+
(0, $kKeXs$playwrighttest.expect)(rowLocator.toString()).toContain(name);
|
|
5070
|
+
(0, $kKeXs$playwrighttest.expect)(rowLocator.toString()).toContain(value);
|
|
5071
|
+
(0, $kKeXs$playwrighttest.expect)(rowLocator.toString()).toContain(type);
|
|
5072
|
+
}
|
|
5073
|
+
async clickEditVariable(variableName) {
|
|
5074
|
+
await this.page.locator("[id='variables-filter']").fill(variableName);
|
|
5075
|
+
await this.page.getByText("Edit").first().click();
|
|
5076
|
+
return new $fd4eef3ad2b2e612$var$ReleaseVariableModal(this.page);
|
|
5077
|
+
}
|
|
5078
|
+
async clickDeleteVariable(variableName) {
|
|
5079
|
+
await this.page.locator("[id='variables-filter']").fill(variableName);
|
|
5080
|
+
await this.page.locator(".action .delete-icon").first().click();
|
|
5081
|
+
return new $fd4eef3ad2b2e612$var$DeleteVariableModel(this.page);
|
|
5082
|
+
}
|
|
5083
|
+
async expectVariablesCountToBe(count) {
|
|
5084
|
+
await (0, $kKeXs$playwrighttest.expect)(this.page.locator(".variable .data-row")).toHaveCount(count);
|
|
5085
|
+
}
|
|
5086
|
+
async expectVariableNotPresent(variableName) {
|
|
5087
|
+
await (0, $kKeXs$playwrighttest.expect)(this.page.locator(".variable").filter({
|
|
5088
|
+
hasText: variableName
|
|
5089
|
+
})).not.toBeVisible();
|
|
5090
|
+
}
|
|
5091
|
+
async clearSearch() {
|
|
5092
|
+
await this.page.locator("[id='variables-filter']").clear();
|
|
5093
|
+
}
|
|
5094
|
+
async switchPossibleValuesToVariable(variableName) {
|
|
5095
|
+
await this.page.locator(".variable-toggle button").click();
|
|
5096
|
+
await this.page.locator(".ui-autocomplete-input").fill(variableName);
|
|
5097
|
+
await this.page.locator(".ui-menu-item-wrapper").filter({
|
|
5098
|
+
hasText: `${variableName}`
|
|
5099
|
+
}).click();
|
|
5100
|
+
}
|
|
5101
|
+
async selectVariableListboxTypeWithVariable(variableName, defaultValue, required) {
|
|
5102
|
+
await this.page.getByRole("combobox").selectOption("DropDownListBox");
|
|
5103
|
+
await this.page.locator(".variable-toggle button").click();
|
|
5104
|
+
await this.page.locator(".ui-autocomplete-input").fill(variableName);
|
|
5105
|
+
await this.page.locator(".ui-menu-item-wrapper").filter({
|
|
5106
|
+
hasText: `${variableName}`
|
|
5107
|
+
}).click();
|
|
5108
|
+
await this.page.locator(".variable-value select").type(defaultValue);
|
|
5109
|
+
if (required) await this.page.getByRole("checkbox").check();
|
|
5110
|
+
else await this.page.getByRole("checkbox").uncheck();
|
|
5111
|
+
}
|
|
5112
|
+
}
|
|
5113
|
+
class $fd4eef3ad2b2e612$var$ReleaseVariableModal extends (0, $f8721861c660dd88$export$2b65d1d97338f32b) {
|
|
5114
|
+
constructor(page){
|
|
5115
|
+
super(page);
|
|
5116
|
+
this.dateUtil = new (0, $880df57ffbf6e614$export$9b575f14aa5e09a1)(page);
|
|
5117
|
+
}
|
|
5118
|
+
async expectValue(locators, expectFn) {
|
|
5119
|
+
const [index, locator] = await (0, $ef0df8ad8a777ce6$export$a0f926f04148e5d2)(locators);
|
|
5120
|
+
expectFn[index](locator);
|
|
5121
|
+
}
|
|
5122
|
+
async expectValueToBe(value) {
|
|
5123
|
+
await this.expectValue([
|
|
5124
|
+
this.page.locator("#modal .variable-value input"),
|
|
5125
|
+
this.page.locator("#modal .variable-value .field-readonly"),
|
|
5126
|
+
this.page.locator("#modal .variable-value .xl-map-string-string"),
|
|
5127
|
+
this.page.locator("#modal .variable-value .xl-list-display-mode .text-container")
|
|
5128
|
+
], [
|
|
5129
|
+
(l)=>(0, $kKeXs$playwrighttest.expect)(l).toHaveValue(value),
|
|
5130
|
+
(l)=>(0, $kKeXs$playwrighttest.expect)(l).toHaveText(value),
|
|
5131
|
+
(l)=>(0, $kKeXs$playwrighttest.expect)(l).toHaveText(value),
|
|
5132
|
+
(l)=>(0, $kKeXs$playwrighttest.expect)(l).toHaveText(value)
|
|
5133
|
+
]);
|
|
5134
|
+
}
|
|
5135
|
+
async expectValueToContain(value) {
|
|
5136
|
+
await this.expectValue([
|
|
5137
|
+
this.page.locator("#modal .variable-value input"),
|
|
5138
|
+
this.page.locator("#modal .variable-value .field-readonly"),
|
|
5139
|
+
this.page.locator("#modal .variable-value .xl-map-string-string"),
|
|
5140
|
+
this.page.locator("#modal .variable-value .xl-list-display-mode")
|
|
5141
|
+
], [
|
|
5142
|
+
(l)=>(0, $kKeXs$playwrighttest.expect)(l.inputValue()).toContain(value),
|
|
5143
|
+
(l)=>(0, $kKeXs$playwrighttest.expect)(l).toContainText(value),
|
|
5144
|
+
(l)=>(0, $kKeXs$playwrighttest.expect)(l).toContainText(value),
|
|
5145
|
+
(l)=>(0, $kKeXs$playwrighttest.expect)(l).toContainText(value)
|
|
5146
|
+
]);
|
|
5147
|
+
}
|
|
5148
|
+
async close() {
|
|
5149
|
+
await this.page.locator("#modal .modal-header button.close").click();
|
|
5150
|
+
}
|
|
5151
|
+
async expectPossibleValues(possiblevalue) {
|
|
5152
|
+
const listLocator = await this.page.locator(".editor .xl-list-row").allInnerTexts();
|
|
5153
|
+
if (possiblevalue instanceof Array) for (const value of possiblevalue)(0, $kKeXs$playwrighttest.expect)(listLocator).toContain(value);
|
|
5154
|
+
else (0, $kKeXs$playwrighttest.expect)(listLocator).toContain(possiblevalue);
|
|
5155
|
+
}
|
|
5156
|
+
async expectPossibleVariableValues(possiblevariablevalue) {
|
|
5157
|
+
await (0, $kKeXs$playwrighttest.expect)(this.page.locator(".variable-dropdown input")).toHaveValue(possiblevariablevalue);
|
|
5158
|
+
}
|
|
5159
|
+
async addPossibleValue(value) {
|
|
5160
|
+
if (value instanceof Array) for (const li of value){
|
|
5161
|
+
await this.page.locator(".xl-components-input-full input").fill(li);
|
|
5162
|
+
await this.page.getByRole("button", {
|
|
5163
|
+
name: "Add"
|
|
5164
|
+
}).click();
|
|
5165
|
+
}
|
|
5166
|
+
else {
|
|
5167
|
+
await this.page.locator(".xl-components-input-full input").fill(value);
|
|
5168
|
+
await this.page.getByRole("button", {
|
|
5169
|
+
name: "Add"
|
|
5170
|
+
}).click();
|
|
5171
|
+
}
|
|
5172
|
+
}
|
|
5173
|
+
async selectVariableValue(defaultValue) {
|
|
5174
|
+
await this.page.locator(".variable-value select").selectOption(defaultValue);
|
|
5175
|
+
}
|
|
5176
|
+
async save() {
|
|
5177
|
+
const saveButton = this.page.locator("#modal .modal-footer .save");
|
|
5178
|
+
await saveButton.scrollIntoViewIfNeeded();
|
|
5179
|
+
await saveButton.click({
|
|
5180
|
+
delay: 2000
|
|
5181
|
+
});
|
|
5182
|
+
// Expect is needed here to avoid flackiness on clicking save button on modal window
|
|
5183
|
+
await (0, $kKeXs$playwrighttest.expect)(saveButton).not.toBeVisible();
|
|
5184
|
+
}
|
|
5185
|
+
async createPossibleValuesVariable(variableName) {
|
|
5186
|
+
await this.page.locator(".variable-toggle button").click();
|
|
5187
|
+
await this.page.locator(".ui-autocomplete-input").fill(variableName);
|
|
5188
|
+
await this.page.locator(".ui-menu-item-wrapper").filter({
|
|
5189
|
+
hasText: `${variableName}`
|
|
5190
|
+
}).click();
|
|
5191
|
+
}
|
|
5192
|
+
async expectVariableValueToBe(value) {
|
|
5193
|
+
(0, $kKeXs$playwrighttest.expect)(await this.page.locator('.variable-value select option[selected="selected"]').textContent()).toBe(value);
|
|
5194
|
+
}
|
|
5195
|
+
async expectNoVariablesInList() {
|
|
5196
|
+
await (0, $kKeXs$playwrighttest.expect)(this.page.getByText("No variables defined.")).toBeVisible();
|
|
5197
|
+
}
|
|
5198
|
+
async expectNameInput(value) {
|
|
5199
|
+
await (0, $kKeXs$playwrighttest.expect)(this.page.locator(`#modal .variable-name input`)).toHaveValue(value);
|
|
5200
|
+
}
|
|
5201
|
+
async expectLabel(value) {
|
|
5202
|
+
await (0, $kKeXs$playwrighttest.expect)(this.page.locator("#modal .variable-label input")).toHaveValue(value);
|
|
5203
|
+
}
|
|
5204
|
+
async expectRequired(value) {
|
|
5205
|
+
if (value == true) await (0, $kKeXs$playwrighttest.expect)(this.page.locator('.form-group input[ng-model="var.requiresValue"]')).toBeChecked();
|
|
5206
|
+
else await (0, $kKeXs$playwrighttest.expect)(this.page.locator('.form-group input[ng-model="var.requiresValue"]')).not.toBeChecked();
|
|
5207
|
+
}
|
|
5208
|
+
async setDescription(description) {
|
|
5209
|
+
await this.page.locator(".variable-description input").click();
|
|
5210
|
+
await this.page.locator(".variable-description input").clear();
|
|
5211
|
+
await this.page.locator(".variable-description input").fill(description);
|
|
5212
|
+
}
|
|
5213
|
+
async setLabel(labelValue) {
|
|
5214
|
+
await this.page.locator(".variable-label input").fill(labelValue);
|
|
5215
|
+
}
|
|
5216
|
+
async setDate(date, monthYear) {
|
|
5217
|
+
await this.page.locator("#modal .date").click();
|
|
5218
|
+
await this.dateUtil.setDate(date, monthYear);
|
|
5219
|
+
}
|
|
5220
|
+
async setValue(value) {
|
|
5221
|
+
await this.page.locator(".variable-value input").fill(value);
|
|
5222
|
+
}
|
|
5223
|
+
}
|
|
5224
|
+
class $fd4eef3ad2b2e612$var$DeleteVariableModel extends (0, $f8721861c660dd88$export$2b65d1d97338f32b) {
|
|
5225
|
+
constructor(page){
|
|
5226
|
+
super(page);
|
|
5227
|
+
this.model = new $fd4eef3ad2b2e612$var$ReleaseVariableModal(page);
|
|
5228
|
+
this.dateUtil = new (0, $880df57ffbf6e614$export$9b575f14aa5e09a1)(page);
|
|
5229
|
+
}
|
|
5230
|
+
async deleteVariable() {
|
|
5231
|
+
await (0, $kKeXs$playwrighttest.expect)(this.page.getByRole("heading", {
|
|
5232
|
+
name: "Replace and delete"
|
|
5233
|
+
})).toBeVisible();
|
|
5234
|
+
await this.page.getByRole("button", {
|
|
5235
|
+
name: "Delete"
|
|
5236
|
+
}).click();
|
|
5237
|
+
}
|
|
5238
|
+
async replaceItWithVariable(variable) {
|
|
5239
|
+
await this.model.createPossibleValuesVariable(variable);
|
|
5240
|
+
}
|
|
5241
|
+
async replaceItwithValue(value) {
|
|
5242
|
+
await this.page.locator(".display").click();
|
|
5243
|
+
await this.page.getByLabel("*").fill(value);
|
|
5244
|
+
}
|
|
5245
|
+
async clickReplaceAndDelete() {
|
|
5246
|
+
await this.page.getByRole("button", {
|
|
5247
|
+
name: "Replace and delete"
|
|
5248
|
+
}).click();
|
|
5249
|
+
}
|
|
5250
|
+
async addValue(value) {
|
|
5251
|
+
await this.page.locator(".xl-components-input-full input").fill(value);
|
|
5252
|
+
await this.page.getByRole("button", {
|
|
5253
|
+
name: "Add"
|
|
5254
|
+
}).click();
|
|
5255
|
+
}
|
|
5256
|
+
async remove(value) {
|
|
5257
|
+
await this.page.locator("li").filter({
|
|
5258
|
+
hasText: value
|
|
5259
|
+
}).locator("i.close-icon").click();
|
|
5260
|
+
}
|
|
5261
|
+
async expectReplacementPromptDisplayed() {
|
|
5262
|
+
await (0, $kKeXs$playwrighttest.expect)(this.page.getByRole("heading", {
|
|
5263
|
+
name: "Replace and delete"
|
|
5264
|
+
})).toBeVisible();
|
|
5265
|
+
}
|
|
5266
|
+
async close() {
|
|
5267
|
+
await this.page.locator("#modal .modal-header button.close").click();
|
|
5268
|
+
}
|
|
5269
|
+
async removeItemOnSet(value) {
|
|
5270
|
+
await this.page.locator("tr").filter({
|
|
5271
|
+
hasText: value
|
|
5272
|
+
}).locator("i.close-icon").click();
|
|
5273
|
+
}
|
|
5274
|
+
async addValueForSet(key, value) {
|
|
5275
|
+
await this.page.locator(".input-key").fill(key);
|
|
5276
|
+
await this.page.locator(".input-value").fill(value);
|
|
5277
|
+
}
|
|
5278
|
+
async replaceWithIntegerValue(value) {
|
|
5279
|
+
await this.page.locator(".editable").fill(value);
|
|
5280
|
+
}
|
|
5281
|
+
async replaceForBooleanValue() {
|
|
5282
|
+
await this.page.locator(".editor input").click();
|
|
5283
|
+
}
|
|
5284
|
+
async deleteBySettingDate(date, monthYear) {
|
|
5285
|
+
await this.page.locator("#modal .date").click();
|
|
5286
|
+
await this.dateUtil.setDate(date, monthYear);
|
|
5287
|
+
}
|
|
5288
|
+
}
|
|
5289
|
+
|
|
5290
|
+
|
|
5291
|
+
|
|
5292
|
+
|
|
5293
|
+
|
|
4796
5294
|
class $ed2d4739e27d43c1$export$60c3bfa6385e2a10 extends (0, $f8721861c660dd88$export$2b65d1d97338f32b) {
|
|
4797
5295
|
constructor(page){
|
|
4798
5296
|
super(page);
|
|
@@ -4803,6 +5301,17 @@ class $ed2d4739e27d43c1$export$60c3bfa6385e2a10 extends (0, $f8721861c660dd88$ex
|
|
|
4803
5301
|
await this.filterTaskByTitle(taskName);
|
|
4804
5302
|
await this.page.getByText(taskName).first().click();
|
|
4805
5303
|
}
|
|
5304
|
+
async complete(taskName, comment) {
|
|
5305
|
+
await this.page.locator(`.row.task-inner`, {
|
|
5306
|
+
hasText: taskName
|
|
5307
|
+
}).locator("span.complete").click();
|
|
5308
|
+
await this.commentBox.click();
|
|
5309
|
+
await this.commentBox.fill(comment);
|
|
5310
|
+
await this.page.getByRole("button", {
|
|
5311
|
+
name: "Complete",
|
|
5312
|
+
exact: true
|
|
5313
|
+
}).click();
|
|
5314
|
+
}
|
|
4806
5315
|
async skip(taskName, comment) {
|
|
4807
5316
|
await this.page.locator(`.row.task-inner`, {
|
|
4808
5317
|
hasText: taskName
|
|
@@ -5362,7 +5871,10 @@ class $959d38250779aa22$var$Phase extends (0, $f8721861c660dd88$export$2b65d1d97
|
|
|
5362
5871
|
await this.page.locator(".icon-close").click();
|
|
5363
5872
|
await this.page.locator("#task-title").fill(taskTitle);
|
|
5364
5873
|
await this.page.getByTestId("save-select-task-btn").click();
|
|
5365
|
-
await
|
|
5874
|
+
await this.page.locator("#release-header").click();
|
|
5875
|
+
await (0, $kKeXs$playwrighttest.expect)(this.phaseLocator.locator(".task-title").filter({
|
|
5876
|
+
hasText: taskTitle
|
|
5877
|
+
})).toBeVisible();
|
|
5366
5878
|
}
|
|
5367
5879
|
async getNumberOfTasks() {
|
|
5368
5880
|
return await this.phaseLocator.locator(".task").count();
|
|
@@ -6835,7 +7347,7 @@ const $8977f8672c5de0fa$export$45f0aca2596a2bb3 = function() {
|
|
|
6835
7347
|
processTasks(subTask, task, idx);
|
|
6836
7348
|
});
|
|
6837
7349
|
(0, (/*@__PURE__*/$parcel$interopDefault($952a2b8d8056b381$exports)))(task.templateVariables, function(variable, idx) {
|
|
6838
|
-
(0, (/*@__PURE__*/$parcel$interopDefault($732eba8dca8b5420$exports)))(variable, getVariableEntity(variable.value, variable.key, task.id, idx));
|
|
7350
|
+
if (variable.value !== undefined) (0, (/*@__PURE__*/$parcel$interopDefault($732eba8dca8b5420$exports)))(variable, getVariableEntity(variable.value, variable.key, task.id, idx));
|
|
6839
7351
|
});
|
|
6840
7352
|
(0, (/*@__PURE__*/$parcel$interopDefault($952a2b8d8056b381$exports)))(task.attachments, function(attachment, idx) {
|
|
6841
7353
|
attachment.type = ATTACHMENT_TYPE;
|
|
@@ -6906,7 +7418,7 @@ const $8977f8672c5de0fa$export$45f0aca2596a2bb3 = function() {
|
|
|
6906
7418
|
attachment.id = `${release.id}/Attachment${index}`;
|
|
6907
7419
|
});
|
|
6908
7420
|
(0, (/*@__PURE__*/$parcel$interopDefault($ae8Uz)))(release.variables, function(variable, index) {
|
|
6909
|
-
(0, (/*@__PURE__*/$parcel$interopDefault($732eba8dca8b5420$exports)))(variable, getVariableEntity(variable.value, variable.key, release.id, index));
|
|
7421
|
+
if (variable.value !== undefined) (0, (/*@__PURE__*/$parcel$interopDefault($732eba8dca8b5420$exports)))(variable, getVariableEntity(variable.value, variable.key, release.id, index));
|
|
6910
7422
|
if (variable.valueProvider) (0, (/*@__PURE__*/$parcel$interopDefault($732eba8dca8b5420$exports)))(variable.valueProvider, getValueProviderConfigurationEntity(variable.id));
|
|
6911
7423
|
});
|
|
6912
7424
|
(0, (/*@__PURE__*/$parcel$interopDefault($ae8Uz)))((0, (/*@__PURE__*/$parcel$interopDefault($f51969c4a7467fa0$exports)))(release.variableValues), function(keyValue, index) {
|
|
@@ -6956,6 +7468,7 @@ const $6998c6a53a9eb4fa$export$e0969da9b8fb378d = (0, $kKeXs$playwrighttest.test
|
|
|
6956
7468
|
class $6998c6a53a9eb4fa$var$Fixtures {
|
|
6957
7469
|
archivedReleaseIds = [];
|
|
6958
7470
|
releaseIds = [];
|
|
7471
|
+
riskProfiles = [];
|
|
6959
7472
|
triggerIds = [];
|
|
6960
7473
|
configurationIds = [];
|
|
6961
7474
|
globalVariableIds = [];
|
|
@@ -7099,6 +7612,29 @@ class $6998c6a53a9eb4fa$var$Fixtures {
|
|
|
7099
7612
|
variable.showOnReleaseStart = false;
|
|
7100
7613
|
return this.doPost("api/v1/config/Configuration/variables/global", variable);
|
|
7101
7614
|
}
|
|
7615
|
+
addDefaultSmtpServer() {
|
|
7616
|
+
const defaultSmtpServer = [
|
|
7617
|
+
{
|
|
7618
|
+
type: "xlrelease.SmtpServer",
|
|
7619
|
+
id: "Configuration/mail/SmtpServer",
|
|
7620
|
+
host: "localhost",
|
|
7621
|
+
port: "25",
|
|
7622
|
+
fromAddress: "foo@bar.com",
|
|
7623
|
+
authentication: {
|
|
7624
|
+
id: "Configuration/mail/SmtpServer/authentication",
|
|
7625
|
+
type: "xlrelease.NoSmtpAuthentication"
|
|
7626
|
+
}
|
|
7627
|
+
}
|
|
7628
|
+
];
|
|
7629
|
+
return this.doPost("fixtures/", defaultSmtpServer);
|
|
7630
|
+
}
|
|
7631
|
+
riskProfile(riskProfile) {
|
|
7632
|
+
this.riskProfiles.push(riskProfile.id);
|
|
7633
|
+
return this.doPost("fixtures/riskProfiles", riskProfile);
|
|
7634
|
+
}
|
|
7635
|
+
deleteRiskProfile(riskProfileId) {
|
|
7636
|
+
return this.doDelete(`fixtures/riskProfiles/${riskProfileId}`);
|
|
7637
|
+
}
|
|
7102
7638
|
async cleanAll() {
|
|
7103
7639
|
for (const username of this.usernames)await this.deleteUser(username);
|
|
7104
7640
|
for (const userProfile of this.userProfiles)await this.deleteUserProfile(userProfile);
|