mirror of
https://github.com/Alfresco/alfresco-content-app.git
synced 2025-07-24 17:31:52 +00:00
[ACA-1797] add tests for viewer actions extension (#666)
This commit is contained in:
committed by
Denys Vuika
parent
8f0ae1a917
commit
b2b0da4c86
@@ -69,6 +69,10 @@ export class Menu extends Component {
|
||||
return this.component.element(by.cssContainingText(Menu.selectors.item, menuItem));
|
||||
}
|
||||
|
||||
getItemById(id: string) {
|
||||
return this.component.element(by.id(id));
|
||||
}
|
||||
|
||||
getItemTooltip(menuItem: string): promise.Promise<string> {
|
||||
return this.getItemByLabel(menuItem).getAttribute('title');
|
||||
}
|
||||
@@ -78,6 +82,10 @@ export class Menu extends Component {
|
||||
|
||||
}
|
||||
|
||||
getItemIdAttribute(menuItem: string) {
|
||||
return this.getItemByLabel(menuItem).getAttribute('id');
|
||||
}
|
||||
|
||||
getItemsCount(): promise.Promise<number> {
|
||||
return this.items.count();
|
||||
}
|
||||
|
@@ -56,6 +56,10 @@ export class Toolbar extends Component {
|
||||
return this.component.element(by.css(`${Toolbar.selectors.button}[title="${title}"]`));
|
||||
}
|
||||
|
||||
getButtonById(id: string) {
|
||||
return this.component.element(by.id(id));
|
||||
}
|
||||
|
||||
async openMoreMenu() {
|
||||
await this.getButtonByTitleAttribute('More actions').click();
|
||||
await this.menu.waitForMenuToOpen();
|
||||
|
Reference in New Issue
Block a user