@umbraco/playwright-testhelpers 17.0.9 → 17.0.10
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/lib/helpers/UiBaseLocators.d.ts +8 -0
- package/dist/lib/helpers/UiBaseLocators.js +24 -1
- package/dist/lib/helpers/UiBaseLocators.js.map +1 -1
- package/dist/lib/helpers/UserGroupApiHelper.js +2 -0
- package/dist/lib/helpers/UserGroupApiHelper.js.map +1 -1
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/package.json +1 -1
|
@@ -151,8 +151,12 @@ export declare class UiBaseLocators {
|
|
|
151
151
|
readonly openedModal: Locator;
|
|
152
152
|
readonly uiLoader: Locator;
|
|
153
153
|
readonly createDocumentBlueprintModal: Locator;
|
|
154
|
+
readonly inputDropzone: Locator;
|
|
155
|
+
readonly imageCropperField: Locator;
|
|
156
|
+
readonly inputUploadField: Locator;
|
|
154
157
|
readonly entityItem: Locator;
|
|
155
158
|
readonly sectionLinks: Locator;
|
|
159
|
+
readonly backOfficeMain: Locator;
|
|
156
160
|
constructor(page: Page);
|
|
157
161
|
clickActionsMenuForNameInSectionSidebar(name: string): Promise<void>;
|
|
158
162
|
clickActionsMenuForName(name: string): Promise<void>;
|
|
@@ -357,4 +361,8 @@ export declare class UiBaseLocators {
|
|
|
357
361
|
enterMonacoEditorValue(value: string): Promise<void>;
|
|
358
362
|
waitUntilUiLoaderIsNoLongerVisible(): Promise<void>;
|
|
359
363
|
isWorkspaceViewTabWithAliasVisible(alias: string, isVisible?: boolean): Promise<void>;
|
|
364
|
+
isInputDropzoneVisible(isVisible?: boolean): Promise<void>;
|
|
365
|
+
isImageCropperFieldVisible(isVisible?: boolean): Promise<void>;
|
|
366
|
+
isInputUploadFieldVisible(isVisible?: boolean): Promise<void>;
|
|
367
|
+
isBackOfficeMainVisible(isVisible?: boolean): Promise<void>;
|
|
360
368
|
}
|
|
@@ -155,8 +155,12 @@ class UiBaseLocators {
|
|
|
155
155
|
openedModal;
|
|
156
156
|
uiLoader;
|
|
157
157
|
createDocumentBlueprintModal;
|
|
158
|
+
inputDropzone;
|
|
159
|
+
imageCropperField;
|
|
160
|
+
inputUploadField;
|
|
158
161
|
entityItem;
|
|
159
162
|
sectionLinks;
|
|
163
|
+
backOfficeMain;
|
|
160
164
|
constructor(page) {
|
|
161
165
|
this.page = page;
|
|
162
166
|
this.saveBtn = page.getByLabel('Save', { exact: true });
|
|
@@ -313,7 +317,11 @@ class UiBaseLocators {
|
|
|
313
317
|
this.monacoEditor = page.locator('.monaco-editor');
|
|
314
318
|
this.openedModal = page.locator('uui-modal-container[backdrop]');
|
|
315
319
|
this.uiLoader = page.locator('uui-loader');
|
|
320
|
+
this.inputDropzone = page.locator('umb-input-dropzone');
|
|
321
|
+
this.imageCropperField = page.locator('umb-image-cropper-field');
|
|
322
|
+
this.inputUploadField = page.locator('umb-input-upload-field').locator('#wrapperInner');
|
|
316
323
|
this.entityItem = page.locator('umb-entity-item-ref');
|
|
324
|
+
this.backOfficeMain = page.locator('umb-backoffice-main');
|
|
317
325
|
}
|
|
318
326
|
async clickActionsMenuForNameInSectionSidebar(name) {
|
|
319
327
|
await this.sectionSidebar.locator('[label="' + name + '"]').hover();
|
|
@@ -727,7 +735,10 @@ class UiBaseLocators {
|
|
|
727
735
|
await this.page.waitForTimeout(400);
|
|
728
736
|
await this.unnamedTabTxt.clear();
|
|
729
737
|
await this.unnamedTabTxt.fill(tabName);
|
|
730
|
-
|
|
738
|
+
// We use this to make sure the test id is updated
|
|
739
|
+
await this.page.getByRole('tab', { name: 'Design' }).click();
|
|
740
|
+
// We click again to make sure the tab is focused
|
|
741
|
+
await this.page.getByTestId('tab:' + tabName).click();
|
|
731
742
|
}
|
|
732
743
|
async searchForTypeToFilterValue(searchValue) {
|
|
733
744
|
await (0, test_1.expect)(this.typeToFilterSearchTxt).toBeVisible();
|
|
@@ -1244,6 +1255,18 @@ class UiBaseLocators {
|
|
|
1244
1255
|
async isWorkspaceViewTabWithAliasVisible(alias, isVisible = true) {
|
|
1245
1256
|
await (0, test_1.expect)(this.page.getByTestId('workspace:view-link:' + alias)).toBeVisible({ visible: isVisible });
|
|
1246
1257
|
}
|
|
1258
|
+
async isInputDropzoneVisible(isVisible = true) {
|
|
1259
|
+
await (0, test_1.expect)(this.inputDropzone).toBeVisible({ visible: isVisible });
|
|
1260
|
+
}
|
|
1261
|
+
async isImageCropperFieldVisible(isVisible = true) {
|
|
1262
|
+
await (0, test_1.expect)(this.imageCropperField).toBeVisible({ visible: isVisible });
|
|
1263
|
+
}
|
|
1264
|
+
async isInputUploadFieldVisible(isVisible = true) {
|
|
1265
|
+
await (0, test_1.expect)(this.inputUploadField).toBeVisible({ visible: isVisible });
|
|
1266
|
+
}
|
|
1267
|
+
async isBackOfficeMainVisible(isVisible = true) {
|
|
1268
|
+
await (0, test_1.expect)(this.backOfficeMain).toBeVisible({ visible: isVisible });
|
|
1269
|
+
}
|
|
1247
1270
|
}
|
|
1248
1271
|
exports.UiBaseLocators = UiBaseLocators;
|
|
1249
1272
|
//# sourceMappingURL=UiBaseLocators.js.map
|