@bigbinary/neeto-playwright-commons 1.22.12 → 1.22.14
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 +110 -86
- package/index.cjs.js.map +1 -1
- package/index.d.ts +13 -6
- package/index.js +110 -87
- package/index.js.map +1 -1
- package/package.json +1 -1
package/index.cjs.js
CHANGED
|
@@ -49,6 +49,103 @@ function _interopNamespaceDefault(e) {
|
|
|
49
49
|
var fs__namespace = /*#__PURE__*/_interopNamespaceDefault(fs$d);
|
|
50
50
|
var Path__namespace = /*#__PURE__*/_interopNamespaceDefault(Path);
|
|
51
51
|
|
|
52
|
+
const BASE_URL = "/api/v1";
|
|
53
|
+
const NEETO_AUTH_BASE_URL = (subdomain = "app") => `https://${subdomain}.neetoauth.net`;
|
|
54
|
+
const ROUTES = {
|
|
55
|
+
neetoAuthSignup: `${NEETO_AUTH_BASE_URL()}/signups/new`,
|
|
56
|
+
neetoAuth: NEETO_AUTH_BASE_URL(),
|
|
57
|
+
loginLink: "/login",
|
|
58
|
+
profile: "/profile",
|
|
59
|
+
admin: "/admin",
|
|
60
|
+
myProfile: "/my/profile",
|
|
61
|
+
authSettings: "/settings",
|
|
62
|
+
webhooks: "/webhooks",
|
|
63
|
+
login: `${BASE_URL}/login`,
|
|
64
|
+
signup: `${BASE_URL}/signups`,
|
|
65
|
+
subdomainAvailability: `${BASE_URL}/subdomain_availability`,
|
|
66
|
+
countries: `${BASE_URL}/countries`,
|
|
67
|
+
neetoApps: `${BASE_URL}/neeto_apps`,
|
|
68
|
+
directUploads: "/direct_uploads",
|
|
69
|
+
teamMembers: {
|
|
70
|
+
all: "/team_members*/**",
|
|
71
|
+
bulkUpdate: "/team_members/teams/bulk_update",
|
|
72
|
+
index: "/team_members/teams",
|
|
73
|
+
show: (id) => `/team_members/teams/${id}`,
|
|
74
|
+
},
|
|
75
|
+
attachment: `/neeto_editor${BASE_URL}/direct_uploads/attach`,
|
|
76
|
+
dashboard: "/dashboard",
|
|
77
|
+
neetoThankYou: "/neeto_thank_you_engine",
|
|
78
|
+
adminPanel: {
|
|
79
|
+
roles: "/admin/general/admin-panel/roles",
|
|
80
|
+
index: "/admin/general/admin-panel",
|
|
81
|
+
auditLogs: "/admin/admin-panel/general/audit-logs",
|
|
82
|
+
apiKeys: "/admin/admin-panel/general/apiKeys",
|
|
83
|
+
customDomain: "/admin/admin-panel/general/custom-domain",
|
|
84
|
+
ipRestriction: "/admin/admin-panel/general/ip-restriction",
|
|
85
|
+
},
|
|
86
|
+
auth: {
|
|
87
|
+
adminPanel: "/admin/admin-panel",
|
|
88
|
+
},
|
|
89
|
+
};
|
|
90
|
+
const API_ROUTES = {
|
|
91
|
+
teamMembers: {
|
|
92
|
+
all: "/team_members*/**",
|
|
93
|
+
bulkUpdate: "/team_members/teams/bulk_update",
|
|
94
|
+
index: "/team_members/teams",
|
|
95
|
+
show: (id) => `/team_members/teams/${id}`,
|
|
96
|
+
creationStatus: (id) => `/team_members/teams/creation_status/${id}`,
|
|
97
|
+
},
|
|
98
|
+
integrations: {
|
|
99
|
+
zapier: {
|
|
100
|
+
api_keys: "/neeto_integrations/zapier/api_keys",
|
|
101
|
+
},
|
|
102
|
+
},
|
|
103
|
+
};
|
|
104
|
+
const THIRD_PARTY_ROUTES = {
|
|
105
|
+
webhooks: { site: "https://webhook.site/" },
|
|
106
|
+
slack: {
|
|
107
|
+
loginWithPassword: (workspace) => `https://${workspace}.slack.com/sign_in_with_password`,
|
|
108
|
+
},
|
|
109
|
+
zapier: {
|
|
110
|
+
login: "https://zapier.com/",
|
|
111
|
+
logOut: "https://zapier.com/logout",
|
|
112
|
+
zapEditor: (zapId) => `https://zapier.com/editor/${zapId}`,
|
|
113
|
+
},
|
|
114
|
+
google: {
|
|
115
|
+
signin: "https://accounts.google.com/v3/signin/identifier?hl=en-gb&ifkv=ASKXGp0nW770RS7xin2puSwbGDpGCeaVKDtCgfpEU73fYmhMKbqUjukBQ5x8kdvEVxQ7OvcrnUo8sg&flowName=GlifWebSignIn&flowEntry=ServiceLogin&dsh=S688843923%3A1704795906762870&theme=glif",
|
|
116
|
+
password: "https://accounts.google.com/v3/signin/challenge/pwd",
|
|
117
|
+
totpChallenge: "https://accounts.google.com/v3/signin/challenge/totp",
|
|
118
|
+
challengeSelection: "https://accounts.google.com/v3/signin/challenge/selection",
|
|
119
|
+
myAccount: "https://myaccount.google.com/",
|
|
120
|
+
chooseAccount: "accounts.google.com/o/oauth2/auth/oauthchooseaccount",
|
|
121
|
+
consentScreen: "accounts.google.com/signin/oauth/consent",
|
|
122
|
+
warningScreen: "accounts.google.com/signin/oauth/warning",
|
|
123
|
+
additionalInfoScreen: "accounts.google.com/signin/oauth/id",
|
|
124
|
+
consentSummary: "accounts.google.com/signin/oauth/v2/consentsummary",
|
|
125
|
+
},
|
|
126
|
+
};
|
|
127
|
+
const NEETO_ROUTES = {
|
|
128
|
+
imageUploader: "/neeto_image_uploader_engine",
|
|
129
|
+
};
|
|
130
|
+
const PROFILE_LINKS = {
|
|
131
|
+
neetoStatus: "https://neetostatus.com/",
|
|
132
|
+
neetoCommunity: "https://www.launchpass.com/neetohq",
|
|
133
|
+
};
|
|
134
|
+
|
|
135
|
+
class ApiKeysApi {
|
|
136
|
+
constructor(neetoPlaywrightUtilities) {
|
|
137
|
+
this.neetoPlaywrightUtilities = neetoPlaywrightUtilities;
|
|
138
|
+
this.API_KEYS_BASE_URL = `neeto_api_keys_engine${BASE_URL}`;
|
|
139
|
+
this.create = (label, type = "general") => this.neetoPlaywrightUtilities.apiRequest({
|
|
140
|
+
url: `${this.API_KEYS_BASE_URL}/api_keys`,
|
|
141
|
+
method: "post",
|
|
142
|
+
body: {
|
|
143
|
+
api_key: { has_no_expiry: true, expires_at: null, label, type },
|
|
144
|
+
},
|
|
145
|
+
});
|
|
146
|
+
}
|
|
147
|
+
}
|
|
148
|
+
|
|
52
149
|
let MemberApis$1 = class MemberApis {
|
|
53
150
|
constructor(neetoPlaywrightUtilities) {
|
|
54
151
|
this.neetoPlaywrightUtilities = neetoPlaywrightUtilities;
|
|
@@ -3533,6 +3630,10 @@ const globalShortcuts = (t) => [
|
|
|
3533
3630
|
description: t("neetoMolecules.keyboardShortcuts.global.submitForm"),
|
|
3534
3631
|
sequence: "ctrl+enter",
|
|
3535
3632
|
},
|
|
3633
|
+
{
|
|
3634
|
+
description: t("neetoMolecules.keyboardShortcuts.global.openProductSwitcher"),
|
|
3635
|
+
sequence: "ctrl+e",
|
|
3636
|
+
},
|
|
3536
3637
|
];
|
|
3537
3638
|
const generatePhoneNumber = () => `${"+91"} 9${faker.faker.string.numeric(4)} ${faker.faker.string.numeric(5)}`;
|
|
3538
3639
|
|
|
@@ -189070,89 +189171,6 @@ class EmbedBase {
|
|
|
189070
189171
|
}
|
|
189071
189172
|
}
|
|
189072
189173
|
|
|
189073
|
-
const BASE_URL = "/api/v1";
|
|
189074
|
-
const NEETO_AUTH_BASE_URL = (subdomain = "app") => `https://${subdomain}.neetoauth.net`;
|
|
189075
|
-
const ROUTES = {
|
|
189076
|
-
neetoAuthSignup: `${NEETO_AUTH_BASE_URL()}/signups/new`,
|
|
189077
|
-
neetoAuth: NEETO_AUTH_BASE_URL(),
|
|
189078
|
-
loginLink: "/login",
|
|
189079
|
-
profile: "/profile",
|
|
189080
|
-
admin: "/admin",
|
|
189081
|
-
myProfile: "/my/profile",
|
|
189082
|
-
authSettings: "/settings",
|
|
189083
|
-
webhooks: "/webhooks",
|
|
189084
|
-
login: `${BASE_URL}/login`,
|
|
189085
|
-
signup: `${BASE_URL}/signups`,
|
|
189086
|
-
subdomainAvailability: `${BASE_URL}/subdomain_availability`,
|
|
189087
|
-
countries: `${BASE_URL}/countries`,
|
|
189088
|
-
neetoApps: `${BASE_URL}/neeto_apps`,
|
|
189089
|
-
directUploads: "/direct_uploads",
|
|
189090
|
-
teamMembers: {
|
|
189091
|
-
all: "/team_members*/**",
|
|
189092
|
-
bulkUpdate: "/team_members/teams/bulk_update",
|
|
189093
|
-
index: "/team_members/teams",
|
|
189094
|
-
show: (id) => `/team_members/teams/${id}`,
|
|
189095
|
-
},
|
|
189096
|
-
attachment: `/neeto_editor${BASE_URL}/direct_uploads/attach`,
|
|
189097
|
-
dashboard: "/dashboard",
|
|
189098
|
-
neetoThankYou: "/neeto_thank_you_engine",
|
|
189099
|
-
adminPanel: {
|
|
189100
|
-
roles: "/admin/general/admin-panel/roles",
|
|
189101
|
-
index: "/admin/general/admin-panel",
|
|
189102
|
-
auditLogs: "/admin/admin-panel/general/audit-logs",
|
|
189103
|
-
apiKeys: "/admin/admin-panel/general/apiKeys",
|
|
189104
|
-
customDomain: "/admin/admin-panel/general/custom-domain",
|
|
189105
|
-
ipRestriction: "/admin/admin-panel/general/ip-restriction",
|
|
189106
|
-
},
|
|
189107
|
-
auth: {
|
|
189108
|
-
adminPanel: "/admin/admin-panel",
|
|
189109
|
-
},
|
|
189110
|
-
};
|
|
189111
|
-
const API_ROUTES = {
|
|
189112
|
-
teamMembers: {
|
|
189113
|
-
all: "/team_members*/**",
|
|
189114
|
-
bulkUpdate: "/team_members/teams/bulk_update",
|
|
189115
|
-
index: "/team_members/teams",
|
|
189116
|
-
show: (id) => `/team_members/teams/${id}`,
|
|
189117
|
-
creationStatus: (id) => `/team_members/teams/creation_status/${id}`,
|
|
189118
|
-
},
|
|
189119
|
-
integrations: {
|
|
189120
|
-
zapier: {
|
|
189121
|
-
api_keys: "/neeto_integrations/zapier/api_keys",
|
|
189122
|
-
},
|
|
189123
|
-
},
|
|
189124
|
-
};
|
|
189125
|
-
const THIRD_PARTY_ROUTES = {
|
|
189126
|
-
webhooks: { site: "https://webhook.site/" },
|
|
189127
|
-
slack: {
|
|
189128
|
-
loginWithPassword: (workspace) => `https://${workspace}.slack.com/sign_in_with_password`,
|
|
189129
|
-
},
|
|
189130
|
-
zapier: {
|
|
189131
|
-
login: "https://zapier.com/",
|
|
189132
|
-
logOut: "https://zapier.com/logout",
|
|
189133
|
-
zapEditor: (zapId) => `https://zapier.com/editor/${zapId}`,
|
|
189134
|
-
},
|
|
189135
|
-
google: {
|
|
189136
|
-
signin: "https://accounts.google.com/v3/signin/identifier?hl=en-gb&ifkv=ASKXGp0nW770RS7xin2puSwbGDpGCeaVKDtCgfpEU73fYmhMKbqUjukBQ5x8kdvEVxQ7OvcrnUo8sg&flowName=GlifWebSignIn&flowEntry=ServiceLogin&dsh=S688843923%3A1704795906762870&theme=glif",
|
|
189137
|
-
password: "https://accounts.google.com/v3/signin/challenge/pwd",
|
|
189138
|
-
totpChallenge: "https://accounts.google.com/v3/signin/challenge/totp",
|
|
189139
|
-
challengeSelection: "https://accounts.google.com/v3/signin/challenge/selection",
|
|
189140
|
-
myAccount: "https://myaccount.google.com/",
|
|
189141
|
-
chooseAccount: "accounts.google.com/o/oauth2/auth/oauthchooseaccount",
|
|
189142
|
-
consentScreen: "accounts.google.com/signin/oauth/consent",
|
|
189143
|
-
warningScreen: "accounts.google.com/signin/oauth/warning",
|
|
189144
|
-
additionalInfoScreen: "accounts.google.com/signin/oauth/id",
|
|
189145
|
-
consentSummary: "accounts.google.com/signin/oauth/v2/consentsummary",
|
|
189146
|
-
},
|
|
189147
|
-
};
|
|
189148
|
-
const NEETO_ROUTES = {
|
|
189149
|
-
imageUploader: "/neeto_image_uploader_engine",
|
|
189150
|
-
};
|
|
189151
|
-
const PROFILE_LINKS = {
|
|
189152
|
-
neetoStatus: "https://neetostatus.com/",
|
|
189153
|
-
neetoCommunity: "https://www.launchpass.com/neetohq",
|
|
189154
|
-
};
|
|
189155
|
-
|
|
189156
189174
|
const CHAT_WIDGET_TEXTS = {
|
|
189157
189175
|
newConversation: "Ask a question",
|
|
189158
189176
|
welcomeChatBubble: "Hi! I'm here to assist you with any questions you may have. What can I do for you?",
|
|
@@ -189426,6 +189444,10 @@ class HelpAndProfilePage {
|
|
|
189426
189444
|
description: this.t("neetoMolecules.keyboardShortcuts.global.submitForm"),
|
|
189427
189445
|
sequence: "ctrl+enter",
|
|
189428
189446
|
},
|
|
189447
|
+
{
|
|
189448
|
+
description: this.t("neetoMolecules.keyboardShortcuts.global.openProductSwitcher"),
|
|
189449
|
+
sequence: "ctrl+e",
|
|
189450
|
+
},
|
|
189429
189451
|
];
|
|
189430
189452
|
const shortcuts = [...globalShortcuts, ...productShortcuts];
|
|
189431
189453
|
await test$1.test.step("1: Open Help Center", this.openHelpCenterV2);
|
|
@@ -193350,13 +193372,13 @@ class ApiKeysPage {
|
|
|
193350
193372
|
await this.page.getByTestId(COMMON_SELECTORS.saveChangesButton).click();
|
|
193351
193373
|
await this.neetoPlaywrightUtilities.verifyToast();
|
|
193352
193374
|
};
|
|
193353
|
-
this.verifyApiKey = ({ targetRow, label, date
|
|
193375
|
+
this.verifyApiKey = ({ targetRow, label, date }) => Promise.all([
|
|
193354
193376
|
test$1.expect(targetRow.getByRole("cell", { name: label })).toBeVisible(),
|
|
193355
|
-
test$1.expect(targetRow.getByTestId(TAGS_SELECTORS.tagContainer)).toHaveText(this.t("common.active")),
|
|
193356
193377
|
test$1.expect(targetRow.getByRole("cell", { name: date })).toBeVisible(),
|
|
193357
193378
|
test$1.expect(targetRow.getByRole("cell", {
|
|
193358
193379
|
name: this.t("neetoApiKeys.common.never"),
|
|
193359
193380
|
})).toBeVisible(),
|
|
193381
|
+
test$1.expect(targetRow.getByTestId(TAGS_SELECTORS.tagContainer)).toHaveText(this.t("neetoApiKeys.tags.active")),
|
|
193360
193382
|
]);
|
|
193361
193383
|
this.editApiKey = async ({ label, expiryDate }) => {
|
|
193362
193384
|
await this.page
|
|
@@ -193441,8 +193463,9 @@ class CustomDomainPage {
|
|
|
193441
193463
|
const validateButton = this.page.getByTestId(CUSTOM_DOMAIN_SELECTORS.customDomainValidateButton);
|
|
193442
193464
|
await Promise.all([
|
|
193443
193465
|
test$1.expect(validateButton).toBeVisible(),
|
|
193444
|
-
test$1.expect(this.page.getByTestId(COMMON_SELECTORS.
|
|
193466
|
+
test$1.expect(this.page.getByTestId(COMMON_SELECTORS.paneHeader).getByText(domain)).toBeVisible(),
|
|
193445
193467
|
]);
|
|
193468
|
+
await this.neetoPlaywrightUtilities.waitForPageLoad();
|
|
193446
193469
|
await test$1.expect(async () => {
|
|
193447
193470
|
await validateButton.click();
|
|
193448
193471
|
await this.neetoPlaywrightUtilities.verifyToast({
|
|
@@ -195748,6 +195771,7 @@ exports.API_KEYS_SELECTORS = API_KEYS_SELECTORS;
|
|
|
195748
195771
|
exports.API_ROUTES = API_ROUTES;
|
|
195749
195772
|
exports.AUDIT_LOGS_TEXTS = AUDIT_LOGS_TEXTS;
|
|
195750
195773
|
exports.AdminPanelPage = AdminPanelPage;
|
|
195774
|
+
exports.ApiKeysApi = ApiKeysApi;
|
|
195751
195775
|
exports.ApiKeysPage = ApiKeysPage;
|
|
195752
195776
|
exports.AuditLogsPage = AuditLogsPage;
|
|
195753
195777
|
exports.BASE_URL = BASE_URL;
|