mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2025-05-12 17:04:57 +00:00
Stabilize tests (#3626)
* Stabilize tests * Added more test fixing to metadata test
This commit is contained in:
parent
803838c276
commit
61dff96e8b
@ -32,10 +32,6 @@ import dateFormat = require('dateformat');
|
||||
import AlfrescoApi = require('alfresco-js-api-node');
|
||||
import { UploadActions } from '../../actions/ACS/upload.actions';
|
||||
|
||||
import fs = require('fs');
|
||||
import path = require('path');
|
||||
import Util = require('../../util/util');
|
||||
|
||||
describe('Metadata component', () => {
|
||||
|
||||
const METADATA = {
|
||||
@ -91,13 +87,14 @@ describe('Metadata component', () => {
|
||||
|
||||
pngFileModel.update(pngUploadedFile.entry);
|
||||
|
||||
loginPage.loginToContentServicesUsingUserModel(acsUser);
|
||||
|
||||
contentServicesPage.navigateToDocumentList();
|
||||
|
||||
done();
|
||||
});
|
||||
|
||||
beforeEach(() => {
|
||||
loginPage.loginToContentServicesUsingUserModel(acsUser);
|
||||
contentServicesPage.navigateToDocumentList();
|
||||
});
|
||||
|
||||
it('[C245652] Properties', () => {
|
||||
viewerPage.viewFile(pngFileModel.name);
|
||||
|
||||
@ -218,20 +215,16 @@ describe('Metadata component', () => {
|
||||
viewerPage.clickCloseButton();
|
||||
});
|
||||
|
||||
it('[C279960] Should show the last username modifier when modify a File', () => {
|
||||
it('[C279960] Should show the last username modifier when modify a File', async (done) => {
|
||||
let fileUrl;
|
||||
|
||||
viewerPage.viewFile(pngFileModel.name);
|
||||
|
||||
browser.getCurrentUrl().then((currentUrl) => {
|
||||
fileUrl = currentUrl;
|
||||
});
|
||||
fileUrl = await browser.getCurrentUrl();
|
||||
|
||||
loginPage.loginToContentServices(TestConfig.adf.adminEmail, TestConfig.adf.adminPassword);
|
||||
|
||||
browser.controlFlow().execute(() => {
|
||||
browser.get(fileUrl);
|
||||
});
|
||||
browser.get(fileUrl);
|
||||
|
||||
viewerPage.clickInfoButton();
|
||||
viewerPage.checkInfoSideBarIsDisplayed();
|
||||
@ -247,21 +240,14 @@ describe('Metadata component', () => {
|
||||
metadataViewPage.clickUpdatePropertyIcon('properties.cm:description');
|
||||
expect(metadataViewPage.getPropertyText('properties.cm:description')).toEqual('check author example description');
|
||||
|
||||
loginPage.loginToContentServicesUsingUserModel(acsUser);
|
||||
|
||||
browser.controlFlow().execute(() => {
|
||||
browser.get(fileUrl);
|
||||
});
|
||||
browser.get(fileUrl);
|
||||
|
||||
viewerPage.clickInfoButton();
|
||||
viewerPage.checkInfoSideBarIsDisplayed();
|
||||
metadataViewPage.clickOnPropertiesTab();
|
||||
|
||||
expect(metadataViewPage.getPropertyText('modifiedByUser.displayName')).toEqual('Administrator');
|
||||
|
||||
loginPage.loginToContentServicesUsingUserModel(acsUser);
|
||||
|
||||
contentServicesPage.navigateToDocumentList();
|
||||
done();
|
||||
});
|
||||
|
||||
it('[C261157] Should be possible use the metadata component When the node is a Folder', () => {
|
||||
@ -272,7 +258,6 @@ describe('Metadata component', () => {
|
||||
});
|
||||
|
||||
it('[C261158] Should be possible edit the metadata When the node is a Folder', () => {
|
||||
contentServicesPage.navigateToDocumentList();
|
||||
contentListPage.metadataContent(folderName);
|
||||
|
||||
metadataViewPage.editIconClick();
|
||||
@ -294,7 +279,6 @@ describe('Metadata component', () => {
|
||||
});
|
||||
|
||||
it('[C260181] Should be possible edit all the metadata aspect', () => {
|
||||
contentServicesPage.navigateToDocumentList();
|
||||
viewerPage.viewFile(pngFileModel.name);
|
||||
viewerPage.clickInfoButton();
|
||||
viewerPage.checkInfoSideBarIsDisplayed();
|
||||
|
@ -25,6 +25,7 @@ var ProcessServicesPage = function(){
|
||||
var taskApp = element(by.css("mat-card[title='Task App']"));
|
||||
var iconTypeLocator = by.css("mat-icon[class*='card-logo-icon']");
|
||||
var descriptionLocator = by.css("mat-card-subtitle[class*='subtitle']");
|
||||
var processInstanceList = element(by.css("adf-process-instance-list"));
|
||||
|
||||
/**
|
||||
* Check Process Page Container is displayed
|
||||
@ -98,6 +99,10 @@ var ProcessServicesPage = function(){
|
||||
return Util.waitUntilElementIsVisible(app);
|
||||
};
|
||||
|
||||
this.checkProcessListIsDisplayed = function() {
|
||||
Util.waitUntilElementIsVisible(processInstanceList);
|
||||
}
|
||||
|
||||
};
|
||||
|
||||
module.exports = ProcessServicesPage;
|
||||
|
@ -29,6 +29,7 @@ import AlfrescoApi = require('alfresco-js-api-node');
|
||||
|
||||
import { AppsActions } from '../actions/APS/apps.actions';
|
||||
import { UsersActions } from '../actions/users.actions';
|
||||
import { browser } from 'protractor';
|
||||
|
||||
describe('Process Filters Test', () => {
|
||||
|
||||
@ -79,10 +80,10 @@ describe('Process Filters Test', () => {
|
||||
processServicesPage.checkApsContainer();
|
||||
processServicesPage.goToApp(app.title);
|
||||
appNavigationBarPage.clickProcessButton();
|
||||
processServicesPage.checkProcessListIsDisplayed();
|
||||
});
|
||||
|
||||
it('Navigate to Running filter', () => {
|
||||
|
||||
processFiltersPage.clickCreateProcessButton();
|
||||
processFiltersPage.clickNewProcessDropdown();
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user