Rebase went little bit wrong -II

This commit is contained in:
Vito Albano
2023-12-07 00:47:27 +00:00
parent bcf016fe8b
commit 162ddf34ce
6 changed files with 8 additions and 45 deletions

View File

@@ -225,7 +225,7 @@ describe('SearchDateRangeComponent', () => {
betweenStartDate: undefined, betweenStartDate: undefined,
betweenEndDate: undefined betweenEndDate: undefined
}; };
let dateRangeTypeRadioButton = getElementBySelector('[data-automation-id="date-range-advanced-in-last"] .mdc-radio__native-control'); let dateRangeTypeRadioButton = getElementBySelector('[data-automation-id="date-range-in-last"] .mdc-radio__native-control');
dateRangeTypeRadioButton.click(); dateRangeTypeRadioButton.click();
selectDropdownOption('date-range-in-last-option-weeks'); selectDropdownOption('date-range-in-last-option-weeks');
enterValueInInputFieldAndTriggerEvent('date-range-in-last-input', ''); enterValueInInputFieldAndTriggerEvent('date-range-in-last-input', '');
@@ -246,7 +246,7 @@ describe('SearchDateRangeComponent', () => {
betweenStartDate: '', betweenStartDate: '',
betweenEndDate: '' betweenEndDate: ''
}; };
dateRangeTypeRadioButton = getElementBySelector('[data-automation-id="date-range-advanced-between"] .mdc-radio__native-control'); dateRangeTypeRadioButton = getElementBySelector('[data-automation-id="date-range-between"] .mdc-radio__native-control');
dateRangeTypeRadioButton.click(); dateRangeTypeRadioButton.click();
fixture.detectChanges(); fixture.detectChanges();
expect(component.changed.emit).not.toHaveBeenCalledWith(value); expect(component.changed.emit).not.toHaveBeenCalledWith(value);
@@ -261,7 +261,7 @@ describe('SearchDateRangeComponent', () => {
betweenStartDate: null, betweenStartDate: null,
betweenEndDate: null betweenEndDate: null
}; };
let dateRangeTypeRadioButton = getElementBySelector('[data-automation-id="date-range-advanced-in-last"] .mdc-radio__native-control'); let dateRangeTypeRadioButton = getElementBySelector('[data-automation-id="date-range-in-last"] .mdc-radio__native-control');
dateRangeTypeRadioButton.click(); dateRangeTypeRadioButton.click();
selectDropdownOption('date-range-in-last-option-weeks'); selectDropdownOption('date-range-in-last-option-weeks');
enterValueInInputFieldAndTriggerEvent('date-range-in-last-input', '5'); enterValueInInputFieldAndTriggerEvent('date-range-in-last-input', '5');
@@ -283,7 +283,7 @@ describe('SearchDateRangeComponent', () => {
betweenStartDate: startDateSampleValue, betweenStartDate: startDateSampleValue,
betweenEndDate: endDateSampleValue betweenEndDate: endDateSampleValue
}; };
dateRangeTypeRadioButton = getElementBySelector('[data-automation-id="date-range-advanced-between"] .mdc-radio__native-control'); dateRangeTypeRadioButton = getElementBySelector('[data-automation-id="date-range-between"] .mdc-radio__native-control');
dateRangeTypeRadioButton.click(); dateRangeTypeRadioButton.click();
component.betweenStartDateFormControl.setValue(startDateSampleValue); component.betweenStartDateFormControl.setValue(startDateSampleValue);
component.betweenEndDateFormControl.setValue(endDateSampleValue); component.betweenEndDateFormControl.setValue(endDateSampleValue);

View File

@@ -104,11 +104,7 @@ export class SearchPropertiesComponent implements OnInit, AfterViewChecked, Sear
const extraFreeSpace = 20; const extraFreeSpace = 20;
this._fileSizeOperatorsMaxWidth = Math.max(...this._fileSizeOperators.map((operator) => this._fileSizeOperatorsMaxWidth = Math.max(...this._fileSizeOperators.map((operator) =>
this.getOperatorNameWidth(operator, this.getCanvasFont(this.fileSizeOperatorSelectElement.nativeElement)))) + this.getOperatorNameWidth(operator, this.getCanvasFont(this.fileSizeOperatorSelectElement.nativeElement)))) +
<<<<<<< Updated upstream
this.fileSizeOperatorSelectElement.nativeElement.querySelector('.mat-mdc-select-arrow').clientWidth +
=======
this.fileSizeOperatorSelectElement.nativeElement.querySelector('.mat-mdc-select-arrow-wrapper').clientWidth + this.fileSizeOperatorSelectElement.nativeElement.querySelector('.mat-mdc-select-arrow-wrapper').clientWidth +
>>>>>>> Stashed changes
extraFreeSpace; extraFreeSpace;
}); });
} }

View File

@@ -8,12 +8,7 @@
width: 100%; width: 100%;
} }
<<<<<<< Updated upstream
/* TODO(mdc-migration): The following rule targets internal classes of select that may no longer apply for the MDC version. */
.mat-select-value-text {
=======
.mat-mdc-select-value-text { .mat-mdc-select-value-text {
>>>>>>> Stashed changes
font-size: var(--theme-body-1-font-size); font-size: var(--theme-body-1-font-size);
} }

View File

@@ -203,13 +203,8 @@ describe('DropdownCloudWidgetComponent', () => {
await openSelect(); await openSelect();
<<<<<<< Updated upstream
const options = fixture.debugElement.queryAll(By.css('.mat-mdc-option'));
expect(options[0].nativeElement.innerText).toBe('default1_value');
=======
const option = fixture.debugElement.query(By.css('.mdc-list-item__primary-text')); const option = fixture.debugElement.query(By.css('.mdc-list-item__primary-text'));
expect(option.nativeElement.innerText).toBe('default1_value'); expect(option.nativeElement.innerText).toBe('default1_value');
>>>>>>> Stashed changes
}); });
it('should preselect dropdown widget value when String (defined value) passed ', async () => { it('should preselect dropdown widget value when String (defined value) passed ', async () => {
@@ -232,11 +227,7 @@ describe('DropdownCloudWidgetComponent', () => {
fixture.detectChanges(); fixture.detectChanges();
await openSelect(); await openSelect();
<<<<<<< Updated upstream
const options = fixture.debugElement.queryAll(By.css('.mat-mdc-option'));
=======
const options = fixture.debugElement.queryAll(By.css('.mdc-list-item__primary-text')); const options = fixture.debugElement.queryAll(By.css('.mdc-list-item__primary-text'));
>>>>>>> Stashed changes
expect(options[0].nativeElement.innerText).toBe('default1_value'); expect(options[0].nativeElement.innerText).toBe('default1_value');
expect(widget.field.form.values['dropdown-id']).toEqual({ id: 'opt1', name: 'default1_value' }); expect(widget.field.form.values['dropdown-id']).toEqual({ id: 'opt1', name: 'default1_value' });
}); });
@@ -460,12 +451,7 @@ describe('DropdownCloudWidgetComponent', () => {
expect(selectedPlaceHolder.nativeElement.getInnerHTML()).toEqual('option_1, option_2'); expect(selectedPlaceHolder.nativeElement.getInnerHTML()).toEqual('option_1, option_2');
await openSelect('#dropdown-id'); await openSelect('#dropdown-id');
const options = fixture.debugElement.queryAll(By.css('.mdc-list-item--selected span'));
<<<<<<< Updated upstream
const options = fixture.debugElement.queryAll(By.css('mat-option.mdc-list-item--selected span'));
=======
const options = fixture.debugElement.queryAll(By.css('.mat-mdc-selected span'));
>>>>>>> Stashed changes
expect(Array.from(options).map(({ nativeElement }) => nativeElement.getInnerHTML().trim())) expect(Array.from(options).map(({ nativeElement }) => nativeElement.getInnerHTML().trim()))
.toEqual(['option_1', 'option_2']); .toEqual(['option_1', 'option_2']);
}); });
@@ -533,12 +519,8 @@ describe('DropdownCloudWidgetComponent', () => {
expect(selectedPlaceHolder.nativeElement.getInnerHTML()).toEqual('option_3, option_4'); expect(selectedPlaceHolder.nativeElement.getInnerHTML()).toEqual('option_3, option_4');
await openSelect('#dropdown-id'); await openSelect('#dropdown-id');
const options = fixture.debugElement.queryAll(By.css('.mdc-list-item--selected span'));
<<<<<<< Updated upstream
const options = fixture.debugElement.queryAll(By.css('mat-option.mdc-list-item--selected span'));
=======
const options = fixture.debugElement.queryAll(By.css('.mat-mdc-selected span'));
>>>>>>> Stashed changes
expect(Array.from(options).map(({ nativeElement }) => nativeElement.getInnerHTML().trim())) expect(Array.from(options).map(({ nativeElement }) => nativeElement.getInnerHTML().trim()))
.toEqual(['option_3', 'option_4']); .toEqual(['option_3', 'option_4']);
}); });

View File

@@ -6,13 +6,8 @@
padding-top: 0 !important; padding-top: 0 !important;
width: 100%; width: 100%;
} }
<<<<<<< Updated upstream
/* TODO(mdc-migration): The following rule targets internal classes of select that may no longer apply for the MDC version. */
.mat-select-value-text {
=======
.mat-mdc-select-value-text { .mat-mdc-select-value-text {
>>>>>>> Stashed changes
font-size: var(--theme-body-1-font-size); font-size: var(--theme-body-1-font-size);
} }

View File

@@ -339,16 +339,11 @@ describe('StartProcessComponent', () => {
selectElement.click(); selectElement.click();
fixture.detectChanges(); fixture.detectChanges();
<<<<<<< Updated upstream
fixture.componentInstance.inputAutocomplete.openPanel(); fixture.componentInstance.inputAutocomplete.openPanel();
fixture.detectChanges(); fixture.detectChanges();
// await fixture.whenStable();
const options: any = fixture.debugElement.queryAll(By.css('.mdc-list-item__primary-textk'));
=======
await fixture.whenStable(); await fixture.whenStable();
const options: any = fixture.debugElement.queryAll(By.css('.mdc-list-item__primary-text')); const options: any = fixture.debugElement.queryAll(By.css('.mdc-list-item__primary-textk'));
>>>>>>> Stashed changes
expect(options.length).toBe(2); expect(options.length).toBe(2);
expect(options[0].nativeElement.innerText).toBe('My Process 1'); expect(options[0].nativeElement.innerText).toBe('My Process 1');