mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2025-07-31 17:38:48 +00:00
[ADF-3556] Create an automated test to cover sidebar position (#3788)
This commit is contained in:
@@ -148,4 +148,11 @@ describe('Header Component', () => {
|
|||||||
|
|
||||||
navigationBarPage.checkLogoTooltip(names.logo_tooltip);
|
navigationBarPage.checkLogoTooltip(names.logo_tooltip);
|
||||||
});
|
});
|
||||||
|
|
||||||
|
it('[C286297] Should be able to change the position of the sidebar menu', () => {
|
||||||
|
headerPage.sideBarPositionEnd();
|
||||||
|
headerPage.checkSidebarPositionEnd();
|
||||||
|
headerPage.sideBarPositionStart();
|
||||||
|
headerPage.checkSidebarPositionStart();
|
||||||
|
});
|
||||||
});
|
});
|
||||||
|
@@ -28,6 +28,10 @@ export class HeaderPage {
|
|||||||
hexColorInput = element(by.css('input[placeholder="hex color code"]'));
|
hexColorInput = element(by.css('input[placeholder="hex color code"]'));
|
||||||
logoHyperlinkInput = element(by.css('input[placeholder="Redirect URL"]'));
|
logoHyperlinkInput = element(by.css('input[placeholder="Redirect URL"]'));
|
||||||
logoTooltipInput = element(by.css('input[placeholder="Tooltip text"]'));
|
logoTooltipInput = element(by.css('input[placeholder="Tooltip text"]'));
|
||||||
|
positionStart = element(by.css('mat-radio-button[value="start"]'));
|
||||||
|
positionEnd = element(by.css('mat-radio-button[value="end"]'));
|
||||||
|
sideBarPositionRight = element(by.css('mat-sidenav.mat-drawer.mat-sidenav.mat-drawer-end'));
|
||||||
|
sideBarPositionLeft = element(by.css('mat-sidenav.mat-drawer.mat-sidenav'));
|
||||||
|
|
||||||
checkShowMenuCheckBoxIsDisplayed() {
|
checkShowMenuCheckBoxIsDisplayed() {
|
||||||
return Util.waitUntilElementIsVisible(this.checkBox);
|
return Util.waitUntilElementIsVisible(this.checkBox);
|
||||||
@@ -106,4 +110,24 @@ export class HeaderPage {
|
|||||||
Util.waitUntilElementIsVisible(this.logoTooltipInput);
|
Util.waitUntilElementIsVisible(this.logoTooltipInput);
|
||||||
return this.logoTooltipInput.click().sendKeys(tooltip).sendKeys(protractor.Key.ENTER);
|
return this.logoTooltipInput.click().sendKeys(tooltip).sendKeys(protractor.Key.ENTER);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
sideBarPositionStart() {
|
||||||
|
Util.waitUntilElementIsVisible(this.positionStart);
|
||||||
|
return this.positionStart.click();
|
||||||
|
}
|
||||||
|
|
||||||
|
sideBarPositionEnd() {
|
||||||
|
Util.waitUntilElementIsVisible(this.positionEnd);
|
||||||
|
return this.positionEnd.click();
|
||||||
|
}
|
||||||
|
|
||||||
|
checkSidebarPositionStart() {
|
||||||
|
return Util.waitUntilElementIsVisible(this.sideBarPositionLeft);
|
||||||
|
}
|
||||||
|
|
||||||
|
checkSidebarPositionEnd() {
|
||||||
|
return Util.waitUntilElementIsVisible(this.sideBarPositionRight);
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user