fixed unit test problem and some other e2e

This commit is contained in:
Vito Albano
2023-12-20 12:12:39 +00:00
parent 55c3f106ef
commit 2eb17d521b
7 changed files with 14 additions and 8 deletions

View File

@@ -105,7 +105,7 @@ describe('Task cloud visibility', async () => {
await taskFormCloudComponent.formFields().checkWidgetIsHidden('Number2');
});
it('[C315232] Should be able to complete a process with visibility condition for boolean widgets', async () => {
fit('[C315232] Should be able to complete a process with visibility condition for boolean widgets', async () => {
await processCloudDemoPage.openNewProcessForm();
await startProcessPage.clearField(startProcessPage.processNameInput);
await startProcessPage.selectFromProcessDropdown(browser.params.resources.ACTIVITI_CLOUD_APPS.SIMPLE_APP.processes.booleanvisibilityprocess);

View File

@@ -16,7 +16,8 @@
cancel
</mat-icon>
</mat-chip-row>
<input *ngIf="!isReadonly()" matInput
<input [disabled]="isReadonly()" matInput
#chipInput
[formControl]="searchUserCtrl"
[matAutocomplete]="auto"
[matChipInputFor]="userMultipleChipList"

View File

@@ -32,27 +32,32 @@
<div *ngIf="!readOnly">
<button mat-button
data-automation-id="dynamic-table-button-move-up"
[disabled]="!hasSelection()"
(click)="moveSelectionUp()">
<mat-icon>arrow_upward</mat-icon>
</button>
<button mat-button
data-automation-id="dynamic-table-button-move-down"
[disabled]="!hasSelection()"
(click)="moveSelectionDown()">
<mat-icon>arrow_downward</mat-icon>
</button>
<button mat-button
data-automation-id="dynamic-table-button-add-row"
[disabled]="field.readOnly"
id="{{content.id}}-add-row"
(click)="addNewRow()">
<mat-icon>add_circle_outline</mat-icon>
</button>
<button mat-button
data-automation-id="dynamic-table-button-remove"
[disabled]="!hasSelection()"
(click)="deleteSelection()">
<mat-icon>remove_circle_outline</mat-icon>
</button>
<button mat-button
data-automation-id="dynamic-table-button-edit"
[disabled]="!hasSelection()"
(click)="editSelection()">
<mat-icon>edit</mat-icon>

View File

@@ -22,7 +22,7 @@ import { $$, $ } from 'protractor';
export class CheckboxWidgetPage {
formFields = new FormFields();
checkboxLabel = $('span[class*="mat-checkbox-label"]');
checkboxLabel = $('mat-checkbox label');
checkboxLocator = ('mat-checkbox');
getCheckboxLabel(): Promise<string> {
@@ -30,7 +30,7 @@ export class CheckboxWidgetPage {
}
async clickCheckboxInput(fieldId: string): Promise<void> {
const checkboxInput = $$(`mat-checkbox[id="${fieldId}"] span`).first();
const checkboxInput = $$(`mat-checkbox[id="${fieldId}"] input`).first();
await BrowserActions.click(checkboxInput);
}
@@ -45,6 +45,6 @@ export class CheckboxWidgetPage {
async isCheckboxChecked(fieldId: string): Promise<boolean> {
const checkboxWidget = await (await this.formFields.getWidget(fieldId)).$(this.checkboxLocator);
const attributeValue = await BrowserActions.getAttribute(checkboxWidget, 'class');
return attributeValue.includes('mat-checkbox-checked');
return attributeValue.includes('mat-mdc-checkbox-checked');
}
}

View File

@@ -25,7 +25,7 @@ export class DynamicTableWidgetPage {
labelLocator: Locator = by.css('dynamic-table-widget div div');
columnNameLocator: Locator = by.css('table[id*="dynamic-table"] th');
cancelButton = element(by.cssContainingText('button span', 'Cancel'));
editButton = element(by.cssContainingText('button span', 'edit'));
editButton = element(by.css('[data-automation-id="dynamic-table-button-edit"]'));
columnDateTime = $('#columnDateTime');
columnDate = $('#columnDate');
calendarHeader = $('.mat-datetimepicker-calendar-header-date-time');

View File

@@ -24,7 +24,7 @@ export class GroupWidgetPage {
groupField = $('input[data-automation-id="adf-group-search-input"]');
firstResult = $('#adf-group-widget-user-0');
formFields = new FormFields();
groupDropDownList: Locator = by.css('.mat-autocomplete-panel');
groupDropDownList: Locator = by.css('.mat-mdc-autocomplete-panel');
getFieldLabel(fieldId: string): Promise<string> {
return this.formFields.getFieldLabel(fieldId);

View File

@@ -23,7 +23,7 @@ export class TypeaheadWidgetPage {
field = $('input[data-automation-id="adf-typeahed-search-input"]');
firstResult = $('#adf-typeahed-widget-user-0');
groupDropDownList = $('.mat-autocomplete-panel');
groupDropDownList = $('.mat-mdc-autocomplete-panel');
formFields = new FormFields();
getFieldLabel(fieldId: string): Promise<string> {