gns3-web-ui/e2e/helpers/common.po.ts

23 lines
495 B
TypeScript
Raw Normal View History

2020-02-07 15:52:12 +00:00
import { browser, by, element } from 'protractor';
2020-02-26 12:43:30 +00:00
import { ServersPage } from './server.po';
2020-02-07 15:52:12 +00:00
export class TestHelper {
sleep(value: number) {
browser.sleep(value);
}
2020-02-26 12:43:30 +00:00
waitForLoading() {
browser.waitForAngular();
}
async asyncForEach(array, callback) {
for (let index = 0; index < array.length; index++) {
await callback(array[index], index, array);
}
}
getCurrentUrl() {
return browser.getCurrentUrl();
}
2020-02-07 15:52:12 +00:00
}