added functionality to view a previous version (#5913)

This commit is contained in:
Urse Daniel
2020-07-27 11:29:29 +03:00
committed by GitHub
parent 8d43155c14
commit 7c09fb1fb9
26 changed files with 337 additions and 111 deletions

View File

@@ -17,7 +17,7 @@
import * as path from 'path';
import { BrowserActions, BrowserVisibility, TogglePage } from '@alfresco/adf-testing';
import { browser, by, element } from 'protractor';
import { browser, by, element, ElementFinder } from 'protractor';
export class VersionManagePage {
@@ -173,6 +173,12 @@ export class VersionManagePage {
await BrowserActions.click(restoreButton);
}
async viewFileVersion(version): Promise<void> {
await this.clickActionButton(version);
const viewButton: ElementFinder = element(by.id(`adf-version-list-action-view-${version}`));
await BrowserActions.click(viewButton);
}
async checkActionsArePresent(version: string): Promise<void> {
await BrowserVisibility.waitUntilElementIsVisible(element(by.id(`adf-version-list-action-download-${version}`)));
await BrowserVisibility.waitUntilElementIsVisible(element(by.id(`adf-version-list-action-delete-${version}`)));