@bigbinary/neeto-playwright-commons 4.6.3 → 4.6.5

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 (3) hide show
  1. package/index.d.ts +4 -4
  2. package/index.js +6 -6
  3. package/package.json +1 -1
package/index.d.ts CHANGED
@@ -4431,7 +4431,7 @@ declare const OTP_EMAIL_PATTERN = "Your login code is";
4431
4431
  *
4432
4432
  */
4433
4433
  declare const SLACK_DEFAULT_CHANNEL = "general";
4434
- declare const CUSTOM_DOMAIN_SUFFIX = "aceinvoice.com";
4434
+ declare const CUSTOM_DOMAIN_SUFFIX = "neetoautomation.com";
4435
4435
  /**
4436
4436
  *
4437
4437
  * Function to generate Zapier test email address based on the product. It takes the following parameters:
@@ -4447,7 +4447,7 @@ declare const CUSTOM_DOMAIN_SUFFIX = "aceinvoice.com";
4447
4447
  */
4448
4448
  declare const ZAPIER_TEST_EMAIL: (product: string) => string;
4449
4449
  declare const MAILPIT_BASE_URL = "https://mailpit.neetodeployapp.com";
4450
- declare const MAILPIT_DOMAIN_NAME = "mail.aceinvoice.com";
4450
+ declare const MAILPIT_DOMAIN_NAME = "mail.neetoautomation.com";
4451
4451
  declare const IS_MAILPIT_ENABLED: boolean;
4452
4452
  declare const IS_SHADCN_UI: boolean;
4453
4453
  declare const mailpitDomainName: () => string;
@@ -4522,7 +4522,7 @@ declare const DATE_RANGES: {
4522
4522
  readonly lastYear: "Last year";
4523
4523
  readonly lastQuarter: "Last quarter";
4524
4524
  };
4525
- declare const CERTIFICATE_LIMIT_EXCEEDED_REGEXP = "too many certificates \\(\\d+\\) already issued for \"aceinvoice.com\"";
4525
+ declare const CERTIFICATE_LIMIT_EXCEEDED_REGEXP = "too many certificates \\(\\d+\\) already issued for \"neetoautomation.com\"";
4526
4526
  declare const CERTIFICATE_LIMIT_EXCEEDED_MESSAGE = "Certificate limit exceeded for custom domain";
4527
4527
  declare const EXPORT_FILE_TYPES: {
4528
4528
  readonly pdf: "pdf";
@@ -5889,7 +5889,7 @@ declare class CustomDomainPage {
5889
5889
  *
5890
5890
  * @example
5891
5891
  *
5892
- * await customDomainPage.validateCustomDomain("custom.aceinvoice.com");
5892
+ * await customDomainPage.validateCustomDomain("custom.neetoautomation.com");
5893
5893
  * @endexample
5894
5894
  */
5895
5895
  validateCustomDomain: (domain: string) => Promise<void>;
package/index.js CHANGED
@@ -323,10 +323,10 @@ const CREDENTIALS = {
323
323
  };
324
324
  const OTP_EMAIL_PATTERN = "Your login code is";
325
325
  const SLACK_DEFAULT_CHANNEL = "general";
326
- const CUSTOM_DOMAIN_SUFFIX = "aceinvoice.com";
326
+ const CUSTOM_DOMAIN_SUFFIX = "neetoautomation.com";
327
327
  const ZAPIER_TEST_EMAIL = (product) => `neeto-${product}-zapier-test@${process.env.FASTMAIL_DOMAIN_NAME}`;
328
328
  const MAILPIT_BASE_URL = "https://mailpit.neetodeployapp.com";
329
- const MAILPIT_DOMAIN_NAME = "mail.aceinvoice.com";
329
+ const MAILPIT_DOMAIN_NAME = "mail.neetoautomation.com";
330
330
  const IS_MAILPIT_ENABLED = isPresent(process.env.MAILPIT_DOMAIN_NAME);
331
331
  const IS_SHADCN_UI = isPresent(process.env.IS_SHADCN_UI);
332
332
  const mailpitDomainName = () => process.env.MAILPIT_DOMAIN_NAME || MAILPIT_DOMAIN_NAME;
@@ -1178,7 +1178,7 @@ const THANK_YOU_SELECTORS = {
1178
1178
 
1179
1179
  const generateStagingData = (product = "invoice") => {
1180
1180
  const jobCompletionIndex = process.env.JOB_COMPLETION_INDEX;
1181
- const dateTimeString = dayjs().format("DDMM-HHmm-ssSSS");
1181
+ const dateTimeString = `${dayjs().format("DDMM-HHmm")}-${faker.string.alphanumeric({ length: 5, casing: "lower" })}`;
1182
1182
  const timestamp = jobCompletionIndex
1183
1183
  ? `${dateTimeString}-${jobCompletionIndex}`
1184
1184
  : dateTimeString;
@@ -1214,14 +1214,14 @@ const getStagingOrganizationTtlInDays = () => {
1214
1214
  const isStagingOrganizationExpired = (subdomainName) => {
1215
1215
  if (!subdomainName?.startsWith("cpt"))
1216
1216
  return false;
1217
- const match = subdomainName.match(/-(\d{2})(\d{2})-(\d{2})(\d{2})-(\d{2})(\d{3})(?:-\d+)?$/);
1217
+ const match = subdomainName.match(/-(\d{2})(\d{2})-(\d{2})(\d{2})-[a-z\d]{5}(?:-\d+)?$/);
1218
1218
  if (!match)
1219
1219
  return false;
1220
- const [, day, month, hour, minute, second, millisecond] = match;
1220
+ const [, day, month, hour, minute] = match;
1221
1221
  const now = dayjs();
1222
1222
  // The subdomain timestamp does not include a year, so assume the current year.
1223
1223
  // If that places the creation date in the future, it was created last year.
1224
- let createdAt = dayjs(`${now.year()}-${month}-${day}T${hour}:${minute}:${second}.${millisecond}`);
1224
+ let createdAt = dayjs(`${now.year()}-${month}-${day}T${hour}:${minute}`);
1225
1225
  if (!createdAt.isValid())
1226
1226
  return false;
1227
1227
  if (createdAt.isAfter(now))
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bigbinary/neeto-playwright-commons",
3
- "version": "4.6.3",
3
+ "version": "4.6.5",
4
4
  "description": "A package encapsulating common playwright code across neeto projects.",
5
5
  "repository": "git@github.com:bigbinary/neeto-playwright-commons.git",
6
6
  "license": "apache-2.0",