mirror of
https://github.com/Alfresco/alfresco-content-app.git
synced 2025-07-24 17:31:52 +00:00
add more e2e tests (#851)
This commit is contained in:
committed by
Denys Vuika
parent
e020dc4b77
commit
d0ff69c5dc
@@ -46,6 +46,7 @@ export class DataTable extends Component {
|
||||
cell: '.adf-data-table-cell',
|
||||
locationLink: '.aca-location-link',
|
||||
nameLink: '.dl-link',
|
||||
libraryRole: 'app-library-role-column',
|
||||
|
||||
selectedIcon: '.mat-icon',
|
||||
|
||||
@@ -199,7 +200,6 @@ export class DataTable extends Component {
|
||||
async selectItem(name: string) {
|
||||
try{
|
||||
const item = this.getRowFirstCell(name);
|
||||
// await Utils.waitUntilElementClickable(item);
|
||||
await item.click();
|
||||
|
||||
} catch (e) {
|
||||
@@ -315,4 +315,8 @@ export class DataTable extends Component {
|
||||
const count = await this.menu.getItemsCount();
|
||||
return count > 0;
|
||||
}
|
||||
|
||||
async getLibraryRole(name: string) {
|
||||
return await this.getRowByName(name).element(by.css(DataTable.selectors.libraryRole)).getText();
|
||||
}
|
||||
}
|
||||
|
@@ -58,11 +58,6 @@ export class Menu extends Component {
|
||||
}
|
||||
|
||||
async closeMenu() {
|
||||
// if (await this.backdrop.isPresent()) {
|
||||
// return await this.backdrop.click();
|
||||
// } else {
|
||||
// return await browser.actions().mouseMove(browser.$('body'), { x: 0, y: 0 }).click().perform();
|
||||
// }
|
||||
return Utils.pressEscape();
|
||||
}
|
||||
|
||||
@@ -148,7 +143,7 @@ export class Menu extends Component {
|
||||
}
|
||||
|
||||
async isMenuItemPresent(title: string) {
|
||||
return await this.component.element(by.cssContainingText(Menu.selectors.item, title)).isPresent();
|
||||
return await browser.element(by.cssContainingText(Menu.selectors.item, title)).isPresent();
|
||||
}
|
||||
|
||||
async isSubMenuItemPresent(title: string) {
|
||||
|
@@ -30,7 +30,8 @@ import { Component } from '../component';
|
||||
export class Toolbar extends Component {
|
||||
private static selectors = {
|
||||
root: '.adf-toolbar',
|
||||
button: '.mat-icon-button'
|
||||
// button: '.mat-icon-button'
|
||||
button: 'button'
|
||||
};
|
||||
|
||||
menu: Menu = new Menu();
|
||||
|
Reference in New Issue
Block a user