@bigbinary/neeto-playwright-commons 3.2.1 → 3.2.2

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/index.cjs.js CHANGED
@@ -6071,7 +6071,7 @@ class CustomCommands {
6071
6071
  const startTime = Date.now();
6072
6072
  return await this.recursiveMethod(callback, condition, timeout, startTime, 1);
6073
6073
  };
6074
- verifyToast = async ({ message = "", toastType = "success", closeAfterVerification = true, timeout = 10_000, customPageContext = this.page, } = {}) => {
6074
+ verifyToast = async ({ message = "", toastType = "success", closeAfterVerification = true, timeout = 10_000, toastCloseTimeout = 10_000, customPageContext = this.page, } = {}) => {
6075
6075
  // React-toastify does not support adding data-* attributes to toast DOM elements: https://github.com/fkhadra/react-toastify/issues/1106
6076
6076
  const toastrLocator = customPageContext
6077
6077
  .locator(COMMON_SELECTORS.neetoUiToastr)
@@ -6092,7 +6092,9 @@ class CustomCommands {
6092
6092
  await customPageContext.evaluate(button => {
6093
6093
  button.dispatchEvent(new Event("click", { bubbles: true }));
6094
6094
  }, buttonHandle);
6095
- await test.expect(toastrCloseButton).toBeHidden({ timeout: 10_000 });
6095
+ await test.expect(toastrCloseButton).toBeHidden({
6096
+ timeout: toastCloseTimeout,
6097
+ });
6096
6098
  }
6097
6099
  };
6098
6100
  waitForPageLoad = async ({ visibilityTimeout = 35_000, customPageContext = this.page, waitForOption = "serial", } = {}) => {