E2E: Updated the failing Default Config tests (#20818)
* Updated block list tests as the “Add Block” button is hidden after reaching the maximum limit. * Updated validation option due to UI changes * Updated tests for current user profile as waitForNetworkToBeIdle() is removed * Fixed flaky tests * Bumped version * Updated tests for current user profile * Bumped version
This commit is contained in:
@@ -8,7 +8,7 @@
|
||||
"hasInstallScript": true,
|
||||
"dependencies": {
|
||||
"@umbraco/json-models-builders": "^2.0.42",
|
||||
"@umbraco/playwright-testhelpers": "^17.0.10",
|
||||
"@umbraco/playwright-testhelpers": "^17.0.11",
|
||||
"camelize": "^1.0.0",
|
||||
"dotenv": "^16.3.1",
|
||||
"node-fetch": "^2.6.7"
|
||||
@@ -67,9 +67,9 @@
|
||||
}
|
||||
},
|
||||
"node_modules/@umbraco/playwright-testhelpers": {
|
||||
"version": "17.0.10",
|
||||
"resolved": "https://registry.npmjs.org/@umbraco/playwright-testhelpers/-/playwright-testhelpers-17.0.10.tgz",
|
||||
"integrity": "sha512-5yHUK8GbqPZ+9P2/3PdudeQAA0w0Nzl9nPUy+rBKpE4e41F/kDpAHbSPIjoQ0oNG26ASmYzL+IVuIGE/iJJwaw==",
|
||||
"version": "17.0.11",
|
||||
"resolved": "https://registry.npmjs.org/@umbraco/playwright-testhelpers/-/playwright-testhelpers-17.0.11.tgz",
|
||||
"integrity": "sha512-+2zijm64oppD17NQg0om7ip1iFJsTQy0ugGgQamZvpf2mUPoGV2CpIz7enPY5YmrQerPacS/1riBMWx/eafqHA==",
|
||||
"license": "MIT",
|
||||
"dependencies": {
|
||||
"@umbraco/json-models-builders": "2.0.42",
|
||||
|
||||
@@ -23,7 +23,7 @@
|
||||
},
|
||||
"dependencies": {
|
||||
"@umbraco/json-models-builders": "^2.0.42",
|
||||
"@umbraco/playwright-testhelpers": "^17.0.10",
|
||||
"@umbraco/playwright-testhelpers": "^17.0.11",
|
||||
"camelize": "^1.0.0",
|
||||
"dotenv": "^16.3.1",
|
||||
"node-fetch": "^2.6.7"
|
||||
|
||||
@@ -147,13 +147,9 @@ test('cannot add number of block element greater than the maximum amount', async
|
||||
await umbracoUi.content.clickBlockElementWithName(elementTypeName);
|
||||
await umbracoUi.content.enterTextstring(inputText);
|
||||
await umbracoUi.content.clickCreateModalButton();
|
||||
await umbracoUi.content.clickAddBlockElementButton();
|
||||
await umbracoUi.content.clickTextButtonWithName(elementTypeName);
|
||||
await umbracoUi.content.enterTextstring(inputText);
|
||||
await umbracoUi.content.clickCreateModalButton();
|
||||
|
||||
// Assert
|
||||
await umbracoUi.content.doesFormValidationMessageContainText('Maximum 1 entries, you have entered 1 too many.');
|
||||
await umbracoUi.content.isAddBlockElementButtonVisible(false);
|
||||
});
|
||||
|
||||
test('can set the label of block element in the content', async ({umbracoApi, umbracoUi}) => {
|
||||
|
||||
@@ -46,12 +46,12 @@ test('can delete a dictionary item', async ({umbracoApi, umbracoUi}) => {
|
||||
// Assert
|
||||
await umbracoUi.dictionary.waitForDictionaryToBeDeleted();
|
||||
await umbracoUi.dictionary.isErrorNotificationVisible(false);
|
||||
expect(await umbracoApi.dictionary.doesNameExist(dictionaryName)).toBeFalsy();
|
||||
// Verify the dictionary item does not display in the tree
|
||||
await umbracoUi.dictionary.isDictionaryTreeItemVisible(dictionaryName, false);
|
||||
// Verify the dictionary item does not display in the list
|
||||
await umbracoUi.reloadPage();
|
||||
await umbracoUi.dictionary.doesDictionaryCollectionContainText('No items');
|
||||
expect(await umbracoApi.dictionary.doesNameExist(dictionaryName)).toBeFalsy();
|
||||
});
|
||||
|
||||
test('can create a dictionary item in a dictionary', {tag: '@smoke'}, async ({umbracoApi, umbracoUi}) => {
|
||||
|
||||
@@ -381,7 +381,7 @@ test('can enable validation for a property in a document type', {tag: '@release'
|
||||
// Act
|
||||
await umbracoUi.documentType.goToDocumentType(documentTypeName);
|
||||
await umbracoUi.documentType.clickEditorSettingsButton();
|
||||
await umbracoUi.documentType.selectValidationOption('');
|
||||
await umbracoUi.documentType.selectValidationOption('.+');
|
||||
await umbracoUi.documentType.enterRegEx(regex);
|
||||
await umbracoUi.documentType.enterRegExMessage(regexMessage);
|
||||
await umbracoUi.documentType.clickSubmitButton();
|
||||
|
||||
@@ -137,7 +137,7 @@ test('can set up validation for a property in a media type', {tag: '@release'},
|
||||
// Act
|
||||
await umbracoUi.mediaType.goToMediaType(mediaTypeName);
|
||||
await umbracoUi.mediaType.clickEditorSettingsButton();
|
||||
await umbracoUi.mediaType.selectValidationOption('');
|
||||
await umbracoUi.mediaType.selectValidationOption('.+');
|
||||
await umbracoUi.mediaType.enterRegEx(regex);
|
||||
await umbracoUi.mediaType.enterRegExMessage(regexMessage);
|
||||
await umbracoUi.mediaType.clickSubmitButton();
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import {NotificationConstantHelper, test} from '@umbraco/playwright-testhelpers';
|
||||
import {ConstantHelper, NotificationConstantHelper, test} from '@umbraco/playwright-testhelpers';
|
||||
|
||||
const userPassword = '0123456789';
|
||||
let testUserCookieAndToken = {cookie: "", accessToken: "", refreshToken: ""};
|
||||
@@ -21,7 +21,7 @@ for (const userGroup of userGroups) {
|
||||
await umbracoApi.user.updatePassword(userId, userPassword);
|
||||
testUserCookieAndToken = await umbracoApi.user.loginToUser(userName, userEmail, userPassword);
|
||||
await umbracoUi.goToBackOffice();
|
||||
await umbracoUi.currentUserProfile.waitForNetworkToBeIdle();
|
||||
await umbracoUi.currentUserProfile.isBackOfficeMainVisible();
|
||||
|
||||
// Act
|
||||
await umbracoUi.currentUserProfile.clickCurrentUserAvatarButton();
|
||||
|
||||
Reference in New Issue
Block a user