@digital-ai/devops-page-object-release 0.0.33 → 0.0.34

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/dist/module.js CHANGED
@@ -396,6 +396,14 @@ class $dfc4ce40cbd0eb71$export$f8e64fcf447db2bf extends (0, $9626bc9256ce31f7$ex
396
396
  await this.page.locator(".variable-label input").fill(labelname);
397
397
  if (description) await this.page.locator(".variable-description input").fill(description);
398
398
  }
399
+ async addNewVariableInFolder(variableName, labelname, description) {
400
+ await this.page.locator("button", {
401
+ hasText: "New folder variable"
402
+ }).click();
403
+ await this.page.fill(`[name="fieldKey"]`, variableName);
404
+ await this.page.locator(".variable-label input").fill(labelname);
405
+ if (description) await this.page.locator(".variable-description input").fill(description);
406
+ }
399
407
  async selectVariableTextType(valueName, multiline) {
400
408
  await this.page.getByRole("combobox").selectOption("StringVariable");
401
409
  if (multiline) {
@@ -733,11 +741,29 @@ class $dfc4ce40cbd0eb71$var$DeleteVariableModel extends (0, $9626bc9256ce31f7$ex
733
741
 
734
742
  class $69e86f559cdf2bd0$export$15d3f9b095bb5188 extends (0, $9626bc9256ce31f7$export$2b65d1d97338f32b) {
735
743
  async expectCommentToContain(comment) {
736
- (0, $hOLA6$expect)(await this.page.locator(".markdown-wrapper").textContent()).toContain(comment);
744
+ await (0, $hOLA6$expect)(this.page.locator(".markdown-wrapper").getByText(comment)).toBeVisible();
737
745
  }
738
746
  async expectTaskIsCommentable(isCommentable) {
739
747
  return (0, $hOLA6$expect)(await this.page.locator("#task-comment").count()).toBe(isCommentable ? 1 : 0);
740
748
  }
749
+ async addComment(comment) {
750
+ await this.page.locator("#task-comment").fill(comment);
751
+ await this.page.locator(".icon-send-airplane").click();
752
+ return this;
753
+ }
754
+ async expectAuthorCommentsToBe(author) {
755
+ await (0, $hOLA6$expect)(this.page.locator(".task-comment-user h6")).toHaveText(author);
756
+ return this;
757
+ }
758
+ async expectCommentsDateTimeToBe(comment, date) {
759
+ const commentLocator = this.page.locator(".task-comment-body").filter({
760
+ has: this.page.locator(".markdown-switcher").getByText(comment)
761
+ }).locator(".task-comment-user span").getByRole("tooltip", {
762
+ name: "Edited"
763
+ });
764
+ await (0, $hOLA6$expect)(commentLocator).toHaveAttribute("aria-label", date);
765
+ return this;
766
+ }
741
767
  }
742
768
 
743
769
 
@@ -954,7 +980,7 @@ class $90bb70a7e909e500$export$519356f6c50361f7 extends (0, $9626bc9256ce31f7$ex
954
980
  return new $90bb70a7e909e500$export$62811a109bb4377d(propertyName, this.page);
955
981
  }
956
982
  async setValueFromString(propertyName, value) {
957
- await this.railLocator.locator(`input[name=${propertyName}]`).focus();
983
+ await this.railLocator.locator(`input[id="${propertyName}"]`).focus();
958
984
  await this.railLocator.locator(`input[id="${propertyName}"]`).fill(value);
959
985
  }
960
986
  async setValueFromLargeString(propertyName, value) {
@@ -1712,12 +1738,20 @@ class $8e39246218b802fc$export$e946776eae644790 extends (0, $9626bc9256ce31f7$ex
1712
1738
  async expectCompleteButtonEnabled() {
1713
1739
  await (0, $hOLA6$expect)(this.completeButton).toBeEnabled();
1714
1740
  }
1741
+ async expectCompleteButtonNotEnabled() {
1742
+ await (0, $hOLA6$expect)(this.completeButton).not.toBeEnabled();
1743
+ }
1715
1744
  async setTitle(title) {
1716
1745
  await this.page.getByTestId("task-title-input-view-mode-typography").click();
1717
1746
  await this.page.getByTestId("task-title-input-input").clear();
1718
1747
  await this.page.getByTestId("task-title-input-input").fill(title);
1719
1748
  await this.page.getByTestId("task-title-input-input").press("Enter");
1720
1749
  }
1750
+ async expectTaskTitleEditable() {
1751
+ await this.page.getByTestId("task-title-input-view-mode-typography").click();
1752
+ await (0, $hOLA6$expect)(this.page.getByTestId("task-title-input-input")).toBeEditable();
1753
+ return this;
1754
+ }
1721
1755
  async expectTypeToContain(taskType) {
1722
1756
  await (0, $hOLA6$expect)(this.page.locator(".task-drawer .task-type")).toContainText(taskType);
1723
1757
  }
@@ -1769,10 +1803,34 @@ class $8e39246218b802fc$export$e946776eae644790 extends (0, $9626bc9256ce31f7$ex
1769
1803
  }).click();
1770
1804
  }
1771
1805
  async assignToMe(userName, existingUsername) {
1806
+ await this.page.locator(".user-task-assigned-wrapper .editable").getByText(existingUsername).click();
1807
+ await this.page.getByTestId(`render-option-${userName}`).click();
1808
+ }
1809
+ async removeAssignToUser(userName) {
1772
1810
  await this.page.getByRole("button", {
1773
- name: existingUsername
1811
+ name: userName
1774
1812
  }).click();
1775
- await this.page.getByTestId(`render-option-${userName}`).click();
1813
+ await this.page.getByRole("button", {
1814
+ name: "Clear"
1815
+ }).click();
1816
+ return this;
1817
+ }
1818
+ async assignToTeam(existingTeamName, teamName) {
1819
+ await this.page.locator(".team-task-assigned-wrapper .editable").getByText(existingTeamName).click();
1820
+ await this.page.getByTestId(`render-option-${teamName}`).click();
1821
+ return this;
1822
+ }
1823
+ async expectAssignedToTeam(teamName) {
1824
+ await (0, $hOLA6$expect)(this.page.getByRole("button", {
1825
+ name: teamName
1826
+ })).toBeVisible();
1827
+ }
1828
+ async removeAssignedTeam(teamName) {
1829
+ await this.page.locator(".team-task-assigned-wrapper .editable").getByText(teamName).click();
1830
+ await this.page.getByRole("button", {
1831
+ name: "Clear"
1832
+ }).click();
1833
+ return this;
1776
1834
  }
1777
1835
  async setFlag(flagName, flagComment) {
1778
1836
  await this.page.getByTestId("flag-btn").click();