mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2025-05-26 17:24:56 +00:00
[ADF-4166] move app-list-cloud.page to adf-testing (#4404)
* in progress * moved UserInfoDialogPage, AppListCloudPage, LoginSSOPage and TabsPage. ADF-4166 * moved UserInfoDialogPage, AppListCloudPage, LoginSSOPage and TabsPage. ADF-4166 * linting fixes * crc's * crc's * added adf-testing to package.json file * fix for failing unit tests * fixes * test failure fixes * test failure fixes * reverted ot old location pages/adf/navigationBarPage * added the testing variable to affected-libs file and changed the version to 3.1.0-beta5 and added the missing adf-content-services dependency. * Fix the material export * Remove the reference to the tse2econfig not allowed * fix failing test * Update user-info.page.ts
This commit is contained in:
parent
4feb8c3f95
commit
285e56e9fb
@ -22,7 +22,7 @@ import { ContentServicesPage } from '../../pages/adf/contentServicesPage';
|
||||
import { ProcessServicesPage } from '../../pages/adf/process-services/processServicesPage';
|
||||
import { NavigationBarPage } from '../../pages/adf/navigationBarPage';
|
||||
|
||||
import { UserInfoDialog } from '../../pages/adf/dialog/userInfoDialog';
|
||||
import { UserInfoPage } from '@alfresco/adf-testing';
|
||||
|
||||
import TestConfig = require('../../test.config');
|
||||
import { AcsUserModel } from '../../models/ACS/acsUserModel';
|
||||
@ -37,7 +37,7 @@ describe('Login component', () => {
|
||||
let settingsPage = new SettingsPage();
|
||||
let processServicesPage = new ProcessServicesPage();
|
||||
let navigationBarPage = new NavigationBarPage();
|
||||
let userInfoDialog = new UserInfoDialog();
|
||||
let userInfoPage = new UserInfoPage();
|
||||
let contentServicesPage = new ContentServicesPage();
|
||||
let loginPage = new LoginPage();
|
||||
let adminUserModel = new AcsUserModel({
|
||||
@ -74,14 +74,14 @@ describe('Login component', () => {
|
||||
|
||||
it('[C276746] Should display the right information in user-info when a different users logs in', () => {
|
||||
loginPage.loginToContentServicesUsingUserModel(userA);
|
||||
navigationBarPage.clickUserProfile();
|
||||
expect(userInfoDialog.getContentHeaderTitle()).toEqual(userA.firstName + ' ' + userA.lastName);
|
||||
expect(userInfoDialog.getContentEmail()).toEqual(userA.email);
|
||||
userInfoPage.clickUserProfile();
|
||||
expect(userInfoPage.getContentHeaderTitle()).toEqual(userA.firstName + ' ' + userA.lastName);
|
||||
expect(userInfoPage.getContentEmail()).toEqual(userA.email);
|
||||
|
||||
loginPage.loginToContentServicesUsingUserModel(userB);
|
||||
navigationBarPage.clickUserProfile();
|
||||
expect(userInfoDialog.getContentHeaderTitle()).toEqual(userB.firstName + ' ' + userB.lastName);
|
||||
expect(userInfoDialog.getContentEmail()).toEqual(userB.email);
|
||||
userInfoPage.clickUserProfile();
|
||||
expect(userInfoPage.getContentHeaderTitle()).toEqual(userB.firstName + ' ' + userB.lastName);
|
||||
expect(userInfoPage.getContentEmail()).toEqual(userB.email);
|
||||
});
|
||||
|
||||
it('[C260036] Should require username', () => {
|
||||
|
@ -15,12 +15,12 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import { LoginSSOPage } from '../pages/adf/loginSSOPage';
|
||||
import { LoginSSOPage } from '@alfresco/adf-testing';
|
||||
import { SettingsPage } from '../pages/adf/settingsPage';
|
||||
import TestConfig = require('../test.config');
|
||||
import { browser } from 'protractor';
|
||||
import { NavigationBarPage } from '../pages/adf/navigationBarPage';
|
||||
import { UserInfoDialog } from '../pages/adf/dialog/userInfoDialog';
|
||||
import { UserInfoPage } from '@alfresco/adf-testing';
|
||||
import { Identity } from '../actions/APS-cloud/identity';
|
||||
|
||||
describe('User Info - SSO', () => {
|
||||
@ -28,7 +28,7 @@ describe('User Info - SSO', () => {
|
||||
const settingsPage = new SettingsPage();
|
||||
const loginSSOPage = new LoginSSOPage();
|
||||
const navigationBarPage = new NavigationBarPage();
|
||||
const userInfoDialog = new UserInfoDialog();
|
||||
const userInfoPage = new UserInfoPage();
|
||||
const identityService: Identity = new Identity();
|
||||
let silentLogin, identityUser;
|
||||
|
||||
@ -49,11 +49,11 @@ describe('User Info - SSO', () => {
|
||||
it('[C290066] Should display UserInfo when login using SSO', () => {
|
||||
|
||||
navigationBarPage.navigateToProcessServicesCloudPage();
|
||||
navigationBarPage.clickUserProfile();
|
||||
expect(userInfoDialog.getSsoHeaderTitle()).toEqual(identityUser.firstName + ' ' + identityUser.lastName);
|
||||
expect(userInfoDialog.getSsoTitle()).toEqual(identityUser.firstName + ' ' + identityUser.lastName);
|
||||
expect(userInfoDialog.getSsoEmail()).toEqual(identityUser.email);
|
||||
userInfoDialog.closeUserProfile();
|
||||
userInfoPage.clickUserProfile();
|
||||
expect(userInfoPage.getSsoHeaderTitle()).toEqual(identityUser.firstName + ' ' + identityUser.lastName);
|
||||
expect(userInfoPage.getSsoTitle()).toEqual(identityUser.firstName + ' ' + identityUser.lastName);
|
||||
expect(userInfoPage.getSsoEmail()).toEqual(identityUser.email);
|
||||
userInfoPage.closeUserProfile();
|
||||
|
||||
});
|
||||
|
||||
|
@ -17,8 +17,7 @@
|
||||
|
||||
import { SettingsPage } from '../pages/adf/settingsPage';
|
||||
import { LoginPage } from '../pages/adf/loginPage';
|
||||
import { UserInfoDialog } from '../pages/adf/dialog/userInfoDialog';
|
||||
import { NavigationBarPage } from '../pages/adf/navigationBarPage';
|
||||
import { UserInfoPage } from '@alfresco/adf-testing';
|
||||
|
||||
import { AcsUserModel } from '../models/ACS/acsUserModel';
|
||||
import { FileModel } from '../models/ACS/fileModel';
|
||||
@ -36,8 +35,7 @@ describe('User Info component', () => {
|
||||
|
||||
let settingsPage = new SettingsPage();
|
||||
let loginPage = new LoginPage();
|
||||
let navigationBarPage = new NavigationBarPage();
|
||||
let userInfoDialog = new UserInfoDialog();
|
||||
let userInfoPage = new UserInfoPage();
|
||||
let processUserModel, contentUserModel;
|
||||
let acsAvatarFileModel = new FileModel({
|
||||
'name': resources.Files.PROFILE_IMAGES.ECM.file_name,
|
||||
@ -78,37 +76,37 @@ describe('User Info component', () => {
|
||||
loginPage.goToLoginPage();
|
||||
settingsPage.setProviderEcmBpm();
|
||||
loginPage.login(contentUserModel.id, contentUserModel.password);
|
||||
navigationBarPage.clickUserProfile();
|
||||
userInfoPage.clickUserProfile();
|
||||
|
||||
expect(userInfoDialog.getContentHeaderTitle()).toEqual(contentUserModel.firstName + ' ' + contentUserModel.lastName);
|
||||
expect(userInfoDialog.getContentTitle()).toEqual(contentUserModel.firstName + ' ' + contentUserModel.lastName);
|
||||
expect(userInfoDialog.getContentEmail()).toEqual(contentUserModel.email);
|
||||
expect(userInfoDialog.getContentJobTitle()).toEqual(contentUserModel.jobTitle);
|
||||
expect(userInfoPage.getContentHeaderTitle()).toEqual(contentUserModel.firstName + ' ' + contentUserModel.lastName);
|
||||
expect(userInfoPage.getContentTitle()).toEqual(contentUserModel.firstName + ' ' + contentUserModel.lastName);
|
||||
expect(userInfoPage.getContentEmail()).toEqual(contentUserModel.email);
|
||||
expect(userInfoPage.getContentJobTitle()).toEqual(contentUserModel.jobTitle);
|
||||
|
||||
userInfoDialog.checkInitialImage();
|
||||
userInfoDialog.APSProfileImageNotDisplayed();
|
||||
userInfoDialog.ACSProfileImageNotDisplayed();
|
||||
userInfoDialog.clickOnContentServicesTab();
|
||||
userInfoPage.checkInitialImage();
|
||||
userInfoPage.APSProfileImageNotDisplayed();
|
||||
userInfoPage.ACSProfileImageNotDisplayed();
|
||||
userInfoPage.clickOnContentServicesTab();
|
||||
|
||||
expect(userInfoDialog.getContentHeaderTitle()).toEqual(contentUserModel.firstName + ' ' + contentUserModel.lastName);
|
||||
expect(userInfoDialog.getContentTitle()).toEqual(contentUserModel.firstName + ' ' + contentUserModel.lastName);
|
||||
expect(userInfoDialog.getContentEmail()).toEqual(contentUserModel.email);
|
||||
expect(userInfoDialog.getContentJobTitle()).toEqual(contentUserModel.jobTitle);
|
||||
expect(userInfoPage.getContentHeaderTitle()).toEqual(contentUserModel.firstName + ' ' + contentUserModel.lastName);
|
||||
expect(userInfoPage.getContentTitle()).toEqual(contentUserModel.firstName + ' ' + contentUserModel.lastName);
|
||||
expect(userInfoPage.getContentEmail()).toEqual(contentUserModel.email);
|
||||
expect(userInfoPage.getContentJobTitle()).toEqual(contentUserModel.jobTitle);
|
||||
|
||||
userInfoDialog.checkInitialImage();
|
||||
userInfoDialog.APSProfileImageNotDisplayed();
|
||||
userInfoDialog.ACSProfileImageNotDisplayed();
|
||||
userInfoDialog.clickOnProcessServicesTab();
|
||||
userInfoDialog.checkProcessServicesTabIsSelected();
|
||||
userInfoPage.checkInitialImage();
|
||||
userInfoPage.APSProfileImageNotDisplayed();
|
||||
userInfoPage.ACSProfileImageNotDisplayed();
|
||||
userInfoPage.clickOnProcessServicesTab();
|
||||
userInfoPage.checkProcessServicesTabIsSelected();
|
||||
|
||||
expect(userInfoDialog.getProcessHeaderTitle()).toEqual(processUserModel.firstName + ' ' + processUserModel.lastName);
|
||||
expect(userInfoDialog.getProcessTitle()).toEqual(processUserModel.firstName + ' ' + processUserModel.lastName);
|
||||
expect(userInfoDialog.getProcessEmail()).toEqual(processUserModel.email);
|
||||
expect(userInfoPage.getProcessHeaderTitle()).toEqual(processUserModel.firstName + ' ' + processUserModel.lastName);
|
||||
expect(userInfoPage.getProcessTitle()).toEqual(processUserModel.firstName + ' ' + processUserModel.lastName);
|
||||
expect(userInfoPage.getProcessEmail()).toEqual(processUserModel.email);
|
||||
|
||||
userInfoDialog.checkInitialImage();
|
||||
userInfoDialog.APSProfileImageNotDisplayed();
|
||||
userInfoDialog.ACSProfileImageNotDisplayed();
|
||||
userInfoDialog.closeUserProfile();
|
||||
userInfoPage.checkInitialImage();
|
||||
userInfoPage.APSProfileImageNotDisplayed();
|
||||
userInfoPage.ACSProfileImageNotDisplayed();
|
||||
userInfoPage.closeUserProfile();
|
||||
});
|
||||
|
||||
it('[C260113] Should display UserInfo when Content Services is enabled and Process Services is disabled', () => {
|
||||
@ -116,18 +114,18 @@ describe('User Info component', () => {
|
||||
settingsPage.setProviderEcm();
|
||||
loginPage.login(contentUserModel.id, contentUserModel.password);
|
||||
|
||||
navigationBarPage.clickUserProfile();
|
||||
userInfoDialog.dialogIsDisplayed();
|
||||
userInfoPage.clickUserProfile();
|
||||
userInfoPage.dialogIsDisplayed();
|
||||
|
||||
expect(userInfoDialog.getContentHeaderTitle()).toEqual(contentUserModel.firstName + ' ' + contentUserModel.lastName);
|
||||
expect(userInfoDialog.getContentTitle()).toEqual(contentUserModel.firstName + ' ' + contentUserModel.lastName);
|
||||
expect(userInfoDialog.getContentEmail()).toEqual(contentUserModel.email);
|
||||
expect(userInfoDialog.getContentJobTitle()).toEqual(contentUserModel.jobTitle);
|
||||
expect(userInfoPage.getContentHeaderTitle()).toEqual(contentUserModel.firstName + ' ' + contentUserModel.lastName);
|
||||
expect(userInfoPage.getContentTitle()).toEqual(contentUserModel.firstName + ' ' + contentUserModel.lastName);
|
||||
expect(userInfoPage.getContentEmail()).toEqual(contentUserModel.email);
|
||||
expect(userInfoPage.getContentJobTitle()).toEqual(contentUserModel.jobTitle);
|
||||
|
||||
userInfoDialog.checkInitialImage();
|
||||
userInfoDialog.APSProfileImageNotDisplayed();
|
||||
userInfoDialog.ACSProfileImageNotDisplayed();
|
||||
userInfoDialog.closeUserProfile();
|
||||
userInfoPage.checkInitialImage();
|
||||
userInfoPage.APSProfileImageNotDisplayed();
|
||||
userInfoPage.ACSProfileImageNotDisplayed();
|
||||
userInfoPage.closeUserProfile();
|
||||
});
|
||||
|
||||
it('[C260115] Should display UserInfo when Process Services is enabled and Content Services is disabled', () => {
|
||||
@ -135,18 +133,18 @@ describe('User Info component', () => {
|
||||
settingsPage.setProviderBpm();
|
||||
loginPage.login(processUserModel.email, processUserModel.password);
|
||||
|
||||
navigationBarPage.clickUserProfile();
|
||||
userInfoPage.clickUserProfile();
|
||||
|
||||
userInfoDialog.dialogIsDisplayed();
|
||||
userInfoPage.dialogIsDisplayed();
|
||||
|
||||
expect(userInfoDialog.getProcessHeaderTitle()).toEqual(processUserModel.firstName + ' ' + processUserModel.lastName);
|
||||
expect(userInfoDialog.getProcessTitle()).toEqual(processUserModel.firstName + ' ' + processUserModel.lastName);
|
||||
expect(userInfoDialog.getProcessEmail()).toEqual(processUserModel.email);
|
||||
expect(userInfoPage.getProcessHeaderTitle()).toEqual(processUserModel.firstName + ' ' + processUserModel.lastName);
|
||||
expect(userInfoPage.getProcessTitle()).toEqual(processUserModel.firstName + ' ' + processUserModel.lastName);
|
||||
expect(userInfoPage.getProcessEmail()).toEqual(processUserModel.email);
|
||||
|
||||
userInfoDialog.checkInitialImage();
|
||||
userInfoDialog.APSProfileImageNotDisplayed();
|
||||
userInfoDialog.ACSProfileImageNotDisplayed();
|
||||
userInfoDialog.closeUserProfile();
|
||||
userInfoPage.checkInitialImage();
|
||||
userInfoPage.APSProfileImageNotDisplayed();
|
||||
userInfoPage.ACSProfileImageNotDisplayed();
|
||||
userInfoPage.closeUserProfile();
|
||||
});
|
||||
|
||||
it('[C260117] Should display UserInfo with profile image uploaded in ACS', async(done) => {
|
||||
@ -158,11 +156,11 @@ describe('User Info component', () => {
|
||||
loginPage.goToLoginPage();
|
||||
settingsPage.setProviderEcm();
|
||||
loginPage.login(contentUserModel.id, contentUserModel.password);
|
||||
navigationBarPage.clickUserProfile();
|
||||
userInfoPage.clickUserProfile();
|
||||
|
||||
userInfoDialog.checkACSProfileImage();
|
||||
userInfoDialog.APSProfileImageNotDisplayed();
|
||||
userInfoDialog.closeUserProfile();
|
||||
userInfoPage.checkACSProfileImage();
|
||||
userInfoPage.APSProfileImageNotDisplayed();
|
||||
userInfoPage.closeUserProfile();
|
||||
|
||||
done();
|
||||
});
|
||||
@ -175,12 +173,12 @@ describe('User Info component', () => {
|
||||
loginPage.goToLoginPage();
|
||||
settingsPage.setProviderBpm();
|
||||
loginPage.login(processUserModel.email, processUserModel.password);
|
||||
navigationBarPage.clickUserProfile();
|
||||
userInfoPage.clickUserProfile();
|
||||
|
||||
userInfoDialog.checkAPSProfileImage();
|
||||
userInfoDialog.ACSProfileImageNotDisplayed();
|
||||
userInfoDialog.initialImageNotDisplayed();
|
||||
userInfoDialog.closeUserProfile();
|
||||
userInfoPage.checkAPSProfileImage();
|
||||
userInfoPage.ACSProfileImageNotDisplayed();
|
||||
userInfoPage.initialImageNotDisplayed();
|
||||
userInfoPage.closeUserProfile();
|
||||
});
|
||||
|
||||
it('[C260120] Should not display profile image in UserInfo when deleted in ACS', () => {
|
||||
@ -190,11 +188,11 @@ describe('User Info component', () => {
|
||||
|
||||
settingsPage.setProviderEcm();
|
||||
loginPage.login(contentUserModel.id, contentUserModel.password);
|
||||
navigationBarPage.clickUserProfile();
|
||||
userInfoPage.clickUserProfile();
|
||||
|
||||
userInfoDialog.checkInitialImage();
|
||||
userInfoDialog.APSProfileImageNotDisplayed();
|
||||
userInfoDialog.ACSProfileImageNotDisplayed();
|
||||
userInfoDialog.closeUserProfile();
|
||||
userInfoPage.checkInitialImage();
|
||||
userInfoPage.APSProfileImageNotDisplayed();
|
||||
userInfoPage.ACSProfileImageNotDisplayed();
|
||||
userInfoPage.closeUserProfile();
|
||||
});
|
||||
});
|
||||
|
@ -18,7 +18,7 @@
|
||||
import { element, by } from 'protractor';
|
||||
|
||||
import { Util } from '../../util/util';
|
||||
import { TabsPage } from './material/tabsPage';
|
||||
import { TabsPage } from '@alfresco/adf-testing';
|
||||
|
||||
export class CommentsPage {
|
||||
|
||||
|
@ -1,59 +0,0 @@
|
||||
/*!
|
||||
* @license
|
||||
* Copyright 2019 Alfresco Software, Ltd.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import { Util } from '../../util/util';
|
||||
import { element, by, browser, protractor } from 'protractor';
|
||||
export class LoginSSOPage {
|
||||
|
||||
ssoButton = element(by.css(`[data-automation-id="login-button-sso"]`));
|
||||
usernameField = element(by.id('username'));
|
||||
passwordField = element(by.id('password'));
|
||||
loginButton = element(by.css('input[class="submit"]'));
|
||||
header = element(by.id('adf-header'));
|
||||
|
||||
loginAPS(username, password) {
|
||||
browser.ignoreSynchronization = true;
|
||||
this.enterUsername(username);
|
||||
this.enterPassword(password);
|
||||
this.clickLoginButton();
|
||||
browser.actions().sendKeys(protractor.Key.ENTER).perform();
|
||||
return Util.waitUntilElementIsVisible(this.header);
|
||||
}
|
||||
|
||||
clickOnSSOButton() {
|
||||
Util.waitUntilElementIsVisible(this.ssoButton);
|
||||
this.ssoButton.click();
|
||||
}
|
||||
|
||||
enterUsername(username) {
|
||||
Util.waitUntilElementIsVisible(this.usernameField);
|
||||
this.usernameField.clear();
|
||||
this.usernameField.sendKeys(username);
|
||||
}
|
||||
|
||||
enterPassword(password) {
|
||||
Util.waitUntilElementIsVisible(this.passwordField);
|
||||
this.passwordField.clear();
|
||||
this.passwordField.sendKeys(password);
|
||||
}
|
||||
|
||||
clickLoginButton() {
|
||||
Util.waitUntilElementIsVisible(this.loginButton);
|
||||
return this.loginButton.click();
|
||||
}
|
||||
|
||||
}
|
@ -18,7 +18,7 @@
|
||||
import { Util } from '../../util/util';
|
||||
import { browser, by, element } from 'protractor';
|
||||
import { ProcessServicesPage } from './process-services/processServicesPage';
|
||||
import { AppListCloudComponent } from './process-cloud/appListCloudComponent';
|
||||
import { AppListCloudPage } from '@alfresco/adf-testing';
|
||||
import TestConfig = require('../../test.config');
|
||||
import { PeopleGroupCloudComponentPage } from './demo-shell/process-services/peopleGroupCloudComponentPage';
|
||||
|
||||
@ -33,7 +33,8 @@ export class NavigationBarPage {
|
||||
loginButton = element(by.css('a[data-automation-id="Login"]'));
|
||||
trashcanButton = element(by.css('a[data-automation-id="Trashcan"]'));
|
||||
overlayViewerButton = element(by.css('a[data-automation-id="Overlay Viewer"]'));
|
||||
userProfileButton = element(by.css('button[data-automation-id="adf-user-profile"]'));
|
||||
themeButton = element(by.css('button[data-automation-id="theme menu"]'));
|
||||
themeMenuContent = element(by.css('div[class*="mat-menu-panel"]'));
|
||||
logoutButton = element(by.css('a[adf-logout]'));
|
||||
cardViewButton = element(by.cssContainingText('.adf-sidenav-menu-label', 'CardView'));
|
||||
languageMenuButton = element(by.css('button[data-automation-id="language-menu-button"]'));
|
||||
@ -77,7 +78,7 @@ export class NavigationBarPage {
|
||||
navigateToProcessServicesCloudPage() {
|
||||
Util.waitUntilElementIsVisible(this.processServicesCloudButton);
|
||||
this.processServicesCloudButton.click();
|
||||
return new AppListCloudComponent();
|
||||
return new AppListCloudPage();
|
||||
}
|
||||
|
||||
navigateToPeopleGroupCloudPage() {
|
||||
@ -89,7 +90,7 @@ export class NavigationBarPage {
|
||||
navigateToSettingsPage() {
|
||||
Util.waitUntilElementIsVisible(this.settingsButton);
|
||||
this.settingsButton.click();
|
||||
return new AppListCloudComponent();
|
||||
return new AppListCloudPage();
|
||||
}
|
||||
|
||||
clickLoginButton() {
|
||||
@ -108,9 +109,17 @@ export class NavigationBarPage {
|
||||
return this;
|
||||
}
|
||||
|
||||
clickUserProfile() {
|
||||
Util.waitUntilElementIsVisible(this.userProfileButton);
|
||||
this.userProfileButton.click();
|
||||
clickThemeButton() {
|
||||
Util.waitUntilElementIsVisible(this.themeButton);
|
||||
this.themeButton.click();
|
||||
Util.waitUntilElementIsVisible(this.themeMenuContent);
|
||||
}
|
||||
|
||||
clickOnSpecificThemeButton(themeName) {
|
||||
let themeElement = element(by.css(`button[data-automation-id="${themeName}"]`));
|
||||
Util.waitUntilElementIsVisible(themeElement);
|
||||
Util.waitUntilElementIsClickable(themeElement);
|
||||
themeElement.click();
|
||||
}
|
||||
|
||||
clickLogoutButton() {
|
||||
@ -188,6 +197,11 @@ export class NavigationBarPage {
|
||||
Util.waitUntilElementIsVisible(logoTooltip);
|
||||
}
|
||||
|
||||
openViewer(nodeId) {
|
||||
browser.get(TestConfig.adf.url + `/files(overlay:files/${nodeId}/view`);
|
||||
return this;
|
||||
}
|
||||
|
||||
goToSite(site) {
|
||||
browser.get(TestConfig.adf.url + `/files/${site.entry.guid}/display/list`);
|
||||
}
|
||||
|
@ -1,46 +0,0 @@
|
||||
/*!
|
||||
* @license
|
||||
* Copyright 2019 Alfresco Software, Ltd.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import { Util } from '../../../util/util';
|
||||
|
||||
import { element, by } from 'protractor';
|
||||
|
||||
export class AppListCloudComponent {
|
||||
|
||||
apsAppsContainer = element(by.css('adf-cloud-app-list'));
|
||||
|
||||
checkApsContainer() {
|
||||
Util.waitUntilElementIsVisible(this.apsAppsContainer);
|
||||
}
|
||||
|
||||
goToApp(applicationName) {
|
||||
let app = element(by.css('mat-card[title="' + applicationName + '"]'));
|
||||
Util.waitUntilElementIsVisible(app);
|
||||
app.click();
|
||||
}
|
||||
|
||||
checkAppIsNotDisplayed(applicationName) {
|
||||
let app = element(by.css('mat-card[title="' + applicationName + '"]'));
|
||||
return Util.waitUntilElementIsNotOnPage(app);
|
||||
}
|
||||
|
||||
checkAppIsDisplayed(applicationName) {
|
||||
let app = element(by.css('mat-card[title="' + applicationName + '"]'));
|
||||
return Util.waitUntilElementIsVisible(app);
|
||||
}
|
||||
|
||||
}
|
@ -18,7 +18,7 @@
|
||||
import { AppSettingsToggles } from './dialog/appSettingsToggles';
|
||||
import { Util } from '../../../util/util';
|
||||
import { element, by, protractor, browser } from 'protractor';
|
||||
import { TabsPage } from '../material/tabsPage';
|
||||
import { TabsPage } from '@alfresco/adf-testing';
|
||||
|
||||
export class TaskDetailsPage {
|
||||
|
||||
|
@ -17,7 +17,7 @@
|
||||
|
||||
import { Util } from '../../util/util';
|
||||
|
||||
import { TabsPage } from './material/tabsPage';
|
||||
import { TabsPage } from '@alfresco/adf-testing';
|
||||
import { FormControllersPage } from './material/formControllersPage';
|
||||
import { element, by, browser, protractor } from 'protractor';
|
||||
|
||||
|
@ -15,27 +15,29 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import { LoginSSOPage } from '../pages/adf/loginSSOPage';
|
||||
import { LoginSSOPage } from '@alfresco/adf-testing';
|
||||
import { SettingsPage } from '../pages/adf/settingsPage';
|
||||
import { AppListCloudComponent } from '../pages/adf/process-cloud/appListCloudComponent';
|
||||
import { AppListCloudPage } from '@alfresco/adf-testing';
|
||||
import TestConfig = require('../test.config');
|
||||
import { NavigationBarPage } from '../pages/adf/navigationBarPage';
|
||||
import { browser } from 'protractor';
|
||||
|
||||
describe('Applications list', () => {
|
||||
|
||||
const settingsPage = new SettingsPage();
|
||||
const loginSSOPage = new LoginSSOPage();
|
||||
const navigationBarPage = new NavigationBarPage();
|
||||
const appListCloudComponent = new AppListCloudComponent();
|
||||
const appListCloudPage = new AppListCloudPage();
|
||||
const appName = 'simple-app';
|
||||
|
||||
it('[C289910] Should the app be displayed on dashboard when is deployed on APS', () => {
|
||||
settingsPage.setProviderBpmSso(TestConfig.adf.hostBPM, TestConfig.adf.hostSso, TestConfig.adf.hostIdentity);
|
||||
browser.ignoreSynchronization = true;
|
||||
loginSSOPage.loginAPS(TestConfig.adf.adminEmail, TestConfig.adf.adminPassword);
|
||||
navigationBarPage.navigateToProcessServicesCloudPage();
|
||||
appListCloudComponent.checkApsContainer();
|
||||
appListCloudComponent.checkAppIsDisplayed(appName);
|
||||
appListCloudComponent.goToApp(appName);
|
||||
appListCloudPage.checkApsContainer();
|
||||
appListCloudPage.checkAppIsDisplayed(appName);
|
||||
appListCloudPage.goToApp(appName);
|
||||
|
||||
});
|
||||
|
||||
|
@ -17,12 +17,13 @@
|
||||
|
||||
import TestConfig = require('../test.config');
|
||||
|
||||
import { LoginSSOPage } from '../pages/adf/loginSSOPage';
|
||||
import { LoginSSOPage } from '@alfresco/adf-testing';
|
||||
import { SettingsPage } from '../pages/adf/settingsPage';
|
||||
import { NavigationBarPage } from '../pages/adf/navigationBarPage';
|
||||
import { TasksCloudDemoPage } from '../pages/adf/demo-shell/process-services/tasksCloudDemoPage';
|
||||
import { ProcessCloudDemoPage } from '../pages/adf/demo-shell/process-services/processCloudDemoPage';
|
||||
import { AppListCloudComponent } from '../pages/adf/process-cloud/appListCloudComponent';
|
||||
import { AppListCloudPage } from '@alfresco/adf-testing';
|
||||
import { browser } from 'protractor';
|
||||
|
||||
describe('Edit process filters cloud', () => {
|
||||
|
||||
@ -30,7 +31,7 @@ describe('Edit process filters cloud', () => {
|
||||
const settingsPage = new SettingsPage();
|
||||
const loginSSOPage = new LoginSSOPage();
|
||||
const navigationBarPage = new NavigationBarPage();
|
||||
let appListCloudComponent = new AppListCloudComponent();
|
||||
let appListCloudComponent = new AppListCloudPage();
|
||||
let tasksCloudDemoPage = new TasksCloudDemoPage();
|
||||
let processCloudDemoPage = new ProcessCloudDemoPage();
|
||||
|
||||
@ -41,6 +42,7 @@ describe('Edit process filters cloud', () => {
|
||||
silentLogin = false;
|
||||
settingsPage.setProviderBpmSso(TestConfig.adf.hostBPM, TestConfig.adf.hostSso, TestConfig.adf.hostIdentity, silentLogin);
|
||||
loginSSOPage.clickOnSSOButton();
|
||||
browser.ignoreSynchronization = true;
|
||||
loginSSOPage.loginAPS(TestConfig.adf.adminEmail, TestConfig.adf.adminPassword);
|
||||
});
|
||||
|
||||
|
@ -17,14 +17,15 @@
|
||||
|
||||
import TestConfig = require('../test.config');
|
||||
|
||||
import { LoginSSOPage } from '../pages/adf/loginSSOPage';
|
||||
import { LoginSSOPage } from '@alfresco/adf-testing';
|
||||
import { SettingsPage } from '../pages/adf/settingsPage';
|
||||
import { NavigationBarPage } from '../pages/adf/navigationBarPage';
|
||||
import { TasksCloudDemoPage } from '../pages/adf/demo-shell/process-services/tasksCloudDemoPage';
|
||||
import { AppListCloudComponent } from '../pages/adf/process-cloud/appListCloudComponent';
|
||||
import { AppListCloudPage } from '@alfresco/adf-testing';
|
||||
import { Util } from '../util/util';
|
||||
|
||||
import { Tasks } from '../actions/APS-cloud/tasks';
|
||||
import { browser } from 'protractor';
|
||||
|
||||
describe('Edit task filters cloud', () => {
|
||||
|
||||
@ -32,7 +33,7 @@ describe('Edit task filters cloud', () => {
|
||||
const settingsPage = new SettingsPage();
|
||||
const loginSSOPage = new LoginSSOPage();
|
||||
const navigationBarPage = new NavigationBarPage();
|
||||
let appListCloudComponent = new AppListCloudComponent();
|
||||
let appListCloudComponent = new AppListCloudPage();
|
||||
let tasksCloudDemoPage = new TasksCloudDemoPage();
|
||||
const tasksService: Tasks = new Tasks();
|
||||
|
||||
@ -45,6 +46,7 @@ describe('Edit task filters cloud', () => {
|
||||
silentLogin = false;
|
||||
settingsPage.setProviderBpmSso(TestConfig.adf.hostBPM, TestConfig.adf.hostSso, TestConfig.adf.hostIdentity, silentLogin);
|
||||
loginSSOPage.clickOnSSOButton();
|
||||
browser.ignoreSynchronization = true;
|
||||
loginSSOPage.loginAPS(TestConfig.adf.adminEmail, TestConfig.adf.adminPassword);
|
||||
|
||||
await tasksService.init(TestConfig.adf.adminEmail, TestConfig.adf.adminPassword);
|
||||
|
@ -17,7 +17,7 @@
|
||||
|
||||
import TestConfig = require('../test.config');
|
||||
|
||||
import { LoginSSOPage } from '../pages/adf/loginSSOPage';
|
||||
import { LoginSSOPage } from '@alfresco/adf-testing';
|
||||
import { SettingsPage } from '../pages/adf/settingsPage';
|
||||
import { NavigationBarPage } from '../pages/adf/navigationBarPage';
|
||||
import { PeopleGroupCloudComponentPage } from '../pages/adf/demo-shell/process-services/peopleGroupCloudComponentPage';
|
||||
@ -79,6 +79,7 @@ describe('People Groups Cloud Component', () => {
|
||||
silentLogin = false;
|
||||
settingsPage.setProviderBpmSso(TestConfig.adf.hostBPM, TestConfig.adf.hostSso, TestConfig.adf.hostIdentity, silentLogin);
|
||||
loginSSOPage.clickOnSSOButton();
|
||||
browser.ignoreSynchronization = true;
|
||||
loginSSOPage.loginAPS(TestConfig.adf.adminEmail, TestConfig.adf.adminPassword);
|
||||
navigationBarPage.navigateToPeopleGroupCloudPage();
|
||||
});
|
||||
|
@ -17,12 +17,12 @@
|
||||
|
||||
import TestConfig = require('../test.config');
|
||||
|
||||
import { LoginSSOPage } from '../pages/adf/loginSSOPage';
|
||||
import { LoginSSOPage } from '@alfresco/adf-testing';
|
||||
import { SettingsPage } from '../pages/adf/settingsPage';
|
||||
import { NavigationBarPage } from '../pages/adf/navigationBarPage';
|
||||
import { ProcessCloudDemoPage } from '../pages/adf/demo-shell/process-services/processCloudDemoPage';
|
||||
import { TasksCloudDemoPage } from '../pages/adf/demo-shell/process-services/tasksCloudDemoPage';
|
||||
import { AppListCloudComponent } from '../pages/adf/process-cloud/appListCloudComponent';
|
||||
import { AppListCloudPage } from '@alfresco/adf-testing';
|
||||
import { ConfigEditorPage } from '../pages/adf/configEditorPage';
|
||||
|
||||
import { ProcessDefinitions } from '../actions/APS-cloud/process-definitions';
|
||||
@ -38,7 +38,7 @@ describe('Process list cloud', () => {
|
||||
const settingsPage = new SettingsPage();
|
||||
const loginSSOPage = new LoginSSOPage();
|
||||
const navigationBarPage = new NavigationBarPage();
|
||||
let appListCloudComponent = new AppListCloudComponent();
|
||||
let appListCloudComponent = new AppListCloudPage();
|
||||
let processCloudDemoPage = new ProcessCloudDemoPage();
|
||||
let tasksCloudDemoPage = new TasksCloudDemoPage();
|
||||
|
||||
@ -56,6 +56,7 @@ describe('Process list cloud', () => {
|
||||
silentLogin = false;
|
||||
settingsPage.setProviderBpmSso(TestConfig.adf.hostBPM, TestConfig.adf.hostSso, TestConfig.adf.hostIdentity, silentLogin);
|
||||
loginSSOPage.clickOnSSOButton();
|
||||
browser.ignoreSynchronization = true;
|
||||
loginSSOPage.loginAPS(user, password);
|
||||
|
||||
navigationBarPage.clickConfigEditorButton();
|
||||
|
@ -17,17 +17,18 @@
|
||||
|
||||
import TestConfig = require('../test.config');
|
||||
|
||||
import { LoginSSOPage } from '../pages/adf/loginSSOPage';
|
||||
import { LoginSSOPage } from '@alfresco/adf-testing';
|
||||
import { SettingsPage } from '../pages/adf/settingsPage';
|
||||
import { NavigationBarPage } from '../pages/adf/navigationBarPage';
|
||||
import { ProcessCloudDemoPage } from '../pages/adf/demo-shell/process-services/processCloudDemoPage';
|
||||
import { TasksCloudDemoPage } from '../pages/adf/demo-shell/process-services/tasksCloudDemoPage';
|
||||
import { AppListCloudComponent } from '../pages/adf/process-cloud/appListCloudComponent';
|
||||
import { AppListCloudPage } from '@alfresco/adf-testing';
|
||||
|
||||
import { ProcessDefinitions } from '../actions/APS-cloud/process-definitions';
|
||||
import { ProcessInstances } from '../actions/APS-cloud/process-instances';
|
||||
import { Tasks } from '../actions/APS-cloud/tasks';
|
||||
import { Query } from '../actions/APS-cloud/query';
|
||||
import { browser } from 'protractor';
|
||||
|
||||
describe('Process filters cloud', () => {
|
||||
|
||||
@ -35,7 +36,7 @@ describe('Process filters cloud', () => {
|
||||
const settingsPage = new SettingsPage();
|
||||
const loginSSOPage = new LoginSSOPage();
|
||||
const navigationBarPage = new NavigationBarPage();
|
||||
let appListCloudComponent = new AppListCloudComponent();
|
||||
let appListCloudComponent = new AppListCloudPage();
|
||||
let processCloudDemoPage = new ProcessCloudDemoPage();
|
||||
let tasksCloudDemoPage = new TasksCloudDemoPage();
|
||||
|
||||
@ -53,6 +54,7 @@ describe('Process filters cloud', () => {
|
||||
silentLogin = false;
|
||||
settingsPage.setProviderBpmSso(TestConfig.adf.hostBPM, TestConfig.adf.hostSso, TestConfig.adf.hostIdentity, silentLogin);
|
||||
loginSSOPage.clickOnSSOButton();
|
||||
browser.ignoreSynchronization = true;
|
||||
loginSSOPage.loginAPS(user, password);
|
||||
|
||||
await processDefinitionService.init(user, password);
|
||||
|
@ -16,16 +16,17 @@
|
||||
*/
|
||||
|
||||
import TestConfig = require('../test.config');
|
||||
import { LoginSSOPage } from '../pages/adf/loginSSOPage';
|
||||
import { LoginSSOPage } from '@alfresco/adf-testing';
|
||||
import { SettingsPage } from '../pages/adf/settingsPage';
|
||||
import { ProcessCloudDemoPage } from '../pages/adf/demo-shell/process-services/processCloudDemoPage';
|
||||
import { AppListCloudComponent } from '../pages/adf/process-cloud/appListCloudComponent';
|
||||
import { AppListCloudPage } from '@alfresco/adf-testing';
|
||||
|
||||
import { ProcessDefinitions } from '../actions/APS-cloud/process-definitions';
|
||||
import { ProcessInstances } from '../actions/APS-cloud/process-instances';
|
||||
import { NavigationBarPage } from '../pages/adf/navigationBarPage';
|
||||
import { ConfigEditorPage } from '../pages/adf/configEditorPage';
|
||||
import { ProcessListCloudConfiguration } from './processListCloud.config';
|
||||
import { browser } from 'protractor';
|
||||
|
||||
describe('Process list cloud', () => {
|
||||
|
||||
@ -34,7 +35,7 @@ describe('Process list cloud', () => {
|
||||
const loginSSOPage = new LoginSSOPage();
|
||||
const navigationBarPage = new NavigationBarPage();
|
||||
const configEditor = new ConfigEditorPage();
|
||||
let appListCloudComponent = new AppListCloudComponent();
|
||||
let appListCloudComponent = new AppListCloudPage();
|
||||
let processCloudDemoPage = new ProcessCloudDemoPage();
|
||||
|
||||
const processDefinitionService: ProcessDefinitions = new ProcessDefinitions();
|
||||
@ -50,6 +51,7 @@ describe('Process list cloud', () => {
|
||||
silentLogin = false;
|
||||
settingsPage.setProviderBpmSso(TestConfig.adf.hostBPM, TestConfig.adf.hostSso, TestConfig.adf.hostIdentity, silentLogin);
|
||||
loginSSOPage.clickOnSSOButton();
|
||||
browser.ignoreSynchronization = true;
|
||||
loginSSOPage.loginAPS(user, password);
|
||||
|
||||
await processDefinitionService.init(user, password);
|
||||
|
@ -15,20 +15,22 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import { LoginSSOPage } from '../pages/adf/loginSSOPage';
|
||||
import { LoginSSOPage } from '@alfresco/adf-testing';
|
||||
import { SettingsPage } from '../pages/adf/settingsPage';
|
||||
import { AppListCloudComponent } from '../pages/adf/process-cloud/appListCloudComponent';
|
||||
import { AppListCloudPage } from '@alfresco/adf-testing';
|
||||
import TestConfig = require('../test.config');
|
||||
import { NavigationBarPage } from '../pages/adf/navigationBarPage';
|
||||
import { ProcessCloudDemoPage } from '../pages/adf/demo-shell/process-services/processCloudDemoPage';
|
||||
import { StartProcessPage } from '../pages/adf/process-services/startProcessPage';
|
||||
import { Util } from '../util/util';
|
||||
import { browser } from 'protractor';
|
||||
|
||||
describe('Start Process', () => {
|
||||
|
||||
const settingsPage = new SettingsPage();
|
||||
const loginSSOPage = new LoginSSOPage();
|
||||
const navigationBarPage = new NavigationBarPage();
|
||||
const appListCloudComponent = new AppListCloudComponent();
|
||||
const appListCloudComponent = new AppListCloudPage();
|
||||
const processCloudDemoPage = new ProcessCloudDemoPage();
|
||||
const startProcessPage = new StartProcessPage();
|
||||
const processName = Util.generateRandomString(10);
|
||||
@ -45,6 +47,7 @@ describe('Start Process', () => {
|
||||
silentLogin = false;
|
||||
settingsPage.setProviderBpmSso(TestConfig.adf.hostBPM, TestConfig.adf.hostSso, TestConfig.adf.hostIdentity, silentLogin);
|
||||
loginSSOPage.clickOnSSOButton();
|
||||
browser.ignoreSynchronization = true;
|
||||
loginSSOPage.loginAPS(user, password);
|
||||
navigationBarPage.navigateToProcessServicesCloudPage();
|
||||
appListCloudComponent.checkApsContainer();
|
||||
|
@ -15,9 +15,9 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import { LoginSSOPage } from '../pages/adf/loginSSOPage';
|
||||
import { LoginSSOPage } from '@alfresco/adf-testing';
|
||||
import { SettingsPage } from '../pages/adf/settingsPage';
|
||||
import { AppListCloudComponent } from '../pages/adf/process-cloud/appListCloudComponent';
|
||||
import { AppListCloudPage } from '@alfresco/adf-testing';
|
||||
import TestConfig = require('../test.config');
|
||||
import { NavigationBarPage } from '../pages/adf/navigationBarPage';
|
||||
import { TasksCloudDemoPage } from '../pages/adf/demo-shell/process-services/tasksCloudDemoPage';
|
||||
@ -25,6 +25,7 @@ import { StartTasksCloudComponent } from '../pages/adf/process-cloud/startTasksC
|
||||
import { Util } from '../util/util';
|
||||
import { PeopleCloudComponent } from '../pages/adf/process-cloud/peopleCloudComponent';
|
||||
import { TaskDetailsPage } from '../pages/adf/demo-shell/process-services/taskDetailsPage';
|
||||
import { browser } from 'protractor';
|
||||
|
||||
describe('Start Task', () => {
|
||||
|
||||
@ -32,7 +33,7 @@ describe('Start Task', () => {
|
||||
const loginSSOPage = new LoginSSOPage();
|
||||
const taskDetailsPage = new TaskDetailsPage();
|
||||
const navigationBarPage = new NavigationBarPage();
|
||||
const appListCloudComponent = new AppListCloudComponent();
|
||||
const appListCloudComponent = new AppListCloudPage();
|
||||
const tasksCloudDemoPage = new TasksCloudDemoPage();
|
||||
const startTask = new StartTasksCloudComponent();
|
||||
const peopleCloudComponent = new PeopleCloudComponent();
|
||||
@ -51,6 +52,7 @@ describe('Start Task', () => {
|
||||
silentLogin = false;
|
||||
settingsPage.setProviderBpmSso(TestConfig.adf.hostBPM, TestConfig.adf.hostSso, TestConfig.adf.hostIdentity, silentLogin);
|
||||
loginSSOPage.clickOnSSOButton();
|
||||
browser.ignoreSynchronization = true;
|
||||
loginSSOPage.loginAPS(user, password);
|
||||
navigationBarPage.navigateToProcessServicesCloudPage();
|
||||
appListCloudComponent.checkApsContainer();
|
||||
|
@ -23,11 +23,12 @@ import moment = require('moment');
|
||||
import { Tasks } from '../actions/APS-cloud/tasks';
|
||||
|
||||
import { NavigationBarPage } from '../pages/adf/navigationBarPage';
|
||||
import { LoginSSOPage } from '../pages/adf/loginSSOPage';
|
||||
import { LoginSSOPage } from '@alfresco/adf-testing';
|
||||
import { SettingsPage } from '../pages/adf/settingsPage';
|
||||
import { AppListCloudComponent } from '../pages/adf/process-cloud/appListCloudComponent';
|
||||
import { AppListCloudPage } from '@alfresco/adf-testing';
|
||||
import { TasksCloudDemoPage } from '../pages/adf/demo-shell/process-services/tasksCloudDemoPage';
|
||||
import { TaskDetailsCloudComponent } from '../pages/adf/process-cloud/TaskDetailsCloudComponent';
|
||||
import { browser } from 'protractor';
|
||||
|
||||
describe('Task Header cloud component', () => {
|
||||
|
||||
@ -42,7 +43,7 @@ describe('Task Header cloud component', () => {
|
||||
const settingsPage = new SettingsPage();
|
||||
const loginSSOPage = new LoginSSOPage();
|
||||
const navigationBarPage = new NavigationBarPage();
|
||||
const appListCloudComponent = new AppListCloudComponent();
|
||||
const appListCloudComponent = new AppListCloudPage();
|
||||
const tasksCloudDemoPage = new TasksCloudDemoPage();
|
||||
const tasksService: Tasks = new Tasks();
|
||||
|
||||
@ -52,6 +53,7 @@ describe('Task Header cloud component', () => {
|
||||
silentLogin = false;
|
||||
settingsPage.setProviderBpmSso(TestConfig.adf.hostBPM, TestConfig.adf.hostSso, TestConfig.adf.hostIdentity, silentLogin);
|
||||
loginSSOPage.clickOnSSOButton();
|
||||
browser.ignoreSynchronization = true;
|
||||
loginSSOPage.loginAPS(user, password);
|
||||
|
||||
await tasksService.init(user, password);
|
||||
|
@ -17,13 +17,14 @@
|
||||
|
||||
import TestConfig = require('../test.config');
|
||||
|
||||
import { LoginSSOPage } from '../pages/adf/loginSSOPage';
|
||||
import { LoginSSOPage } from '@alfresco/adf-testing';
|
||||
import { SettingsPage } from '../pages/adf/settingsPage';
|
||||
import { NavigationBarPage } from '../pages/adf/navigationBarPage';
|
||||
import { TasksCloudDemoPage } from '../pages/adf/demo-shell/process-services/tasksCloudDemoPage';
|
||||
import { AppListCloudComponent } from '../pages/adf/process-cloud/appListCloudComponent';
|
||||
import { AppListCloudPage } from '@alfresco/adf-testing';
|
||||
import { Util } from '../util/util';
|
||||
import { Tasks } from '../actions/APS-cloud/tasks';
|
||||
import { browser } from 'protractor';
|
||||
|
||||
describe('Task filters cloud', () => {
|
||||
|
||||
@ -31,7 +32,7 @@ describe('Task filters cloud', () => {
|
||||
const settingsPage = new SettingsPage();
|
||||
const loginSSOPage = new LoginSSOPage();
|
||||
const navigationBarPage = new NavigationBarPage();
|
||||
let appListCloudComponent = new AppListCloudComponent();
|
||||
let appListCloudComponent = new AppListCloudPage();
|
||||
let tasksCloudDemoPage = new TasksCloudDemoPage();
|
||||
const tasksService: Tasks = new Tasks();
|
||||
const user = TestConfig.adf.adminEmail, password = TestConfig.adf.adminPassword;
|
||||
@ -44,6 +45,7 @@ describe('Task filters cloud', () => {
|
||||
silentLogin = false;
|
||||
settingsPage.setProviderBpmSso(TestConfig.adf.hostBPM, TestConfig.adf.hostSso, TestConfig.adf.hostIdentity, silentLogin);
|
||||
loginSSOPage.clickOnSSOButton();
|
||||
browser.ignoreSynchronization = true;
|
||||
loginSSOPage.loginAPS(user, password);
|
||||
});
|
||||
|
||||
|
@ -17,11 +17,11 @@
|
||||
|
||||
import TestConfig = require('../test.config');
|
||||
|
||||
import { LoginSSOPage } from '../pages/adf/loginSSOPage';
|
||||
import { LoginSSOPage } from '@alfresco/adf-testing';
|
||||
import { SettingsPage } from '../pages/adf/settingsPage';
|
||||
import { NavigationBarPage } from '../pages/adf/navigationBarPage';
|
||||
import { TasksCloudDemoPage } from '../pages/adf/demo-shell/process-services/tasksCloudDemoPage';
|
||||
import { AppListCloudComponent } from '../pages/adf/process-cloud/appListCloudComponent';
|
||||
import { AppListCloudPage } from '@alfresco/adf-testing';
|
||||
import { ConfigEditorPage } from '../pages/adf/configEditorPage';
|
||||
import { TaskListCloudConfiguration } from './taskListCloud.config';
|
||||
|
||||
@ -42,7 +42,7 @@ describe('Edit task filters and task list properties', () => {
|
||||
const settingsPage = new SettingsPage();
|
||||
const loginSSOPage = new LoginSSOPage();
|
||||
const navigationBarPage = new NavigationBarPage();
|
||||
let appListCloudComponent = new AppListCloudComponent();
|
||||
let appListCloudComponent = new AppListCloudPage();
|
||||
let tasksCloudDemoPage = new TasksCloudDemoPage();
|
||||
|
||||
const tasksService: Tasks = new Tasks();
|
||||
@ -67,6 +67,7 @@ describe('Edit task filters and task list properties', () => {
|
||||
let jsonFile = new TaskListCloudConfiguration().getConfiguration();
|
||||
settingsPage.setProviderBpmSso(TestConfig.adf.hostBPM, TestConfig.adf.hostSso, TestConfig.adf.hostIdentity, silentLogin);
|
||||
loginSSOPage.clickOnSSOButton();
|
||||
browser.ignoreSynchronization = true;
|
||||
loginSSOPage.loginAPS(user, password);
|
||||
|
||||
navigationBarPage.clickConfigEditorButton();
|
||||
|
@ -17,14 +17,12 @@
|
||||
|
||||
import TestConfig = require('../test.config');
|
||||
|
||||
import { LoginSSOPage } from '../pages/adf/loginSSOPage';
|
||||
import { LoginSSOPage } from '@alfresco/adf-testing';
|
||||
import { SettingsPage } from '../pages/adf/settingsPage';
|
||||
import { NavigationBarPage } from '../pages/adf/navigationBarPage';
|
||||
import { TasksCloudDemoPage } from '../pages/adf/demo-shell/process-services/tasksCloudDemoPage';
|
||||
import { AppListCloudComponent } from '../pages/adf/process-cloud/appListCloudComponent';
|
||||
|
||||
import { AppListCloudPage } from '@alfresco/adf-testing';
|
||||
import { Util } from '../util/util';
|
||||
|
||||
import { Tasks } from '../actions/APS-cloud/tasks';
|
||||
import { browser } from 'protractor';
|
||||
|
||||
@ -34,7 +32,7 @@ describe('Task list cloud - selection', () => {
|
||||
const settingsPage = new SettingsPage();
|
||||
const loginSSOPage = new LoginSSOPage();
|
||||
const navigationBarPage = new NavigationBarPage();
|
||||
let appListCloudComponent = new AppListCloudComponent();
|
||||
let appListCloudComponent = new AppListCloudPage();
|
||||
let tasksCloudDemoPage = new TasksCloudDemoPage();
|
||||
|
||||
const tasksService: Tasks = new Tasks();
|
||||
@ -49,6 +47,7 @@ describe('Task list cloud - selection', () => {
|
||||
silentLogin = false;
|
||||
settingsPage.setProviderBpmSso(TestConfig.adf.hostBPM, TestConfig.adf.hostSso, TestConfig.adf.hostIdentity, silentLogin);
|
||||
loginSSOPage.clickOnSSOButton();
|
||||
browser.ignoreSynchronization = true;
|
||||
loginSSOPage.loginAPS(user, password);
|
||||
|
||||
await tasksService.init(user, password);
|
||||
|
@ -17,17 +17,18 @@
|
||||
|
||||
import TestConfig = require('../test.config');
|
||||
|
||||
import { LoginSSOPage } from '../pages/adf/loginSSOPage';
|
||||
import { LoginSSOPage } from '@alfresco/adf-testing';
|
||||
import { SettingsPage } from '../pages/adf/settingsPage';
|
||||
import { NavigationBarPage } from '../pages/adf/navigationBarPage';
|
||||
import { TasksCloudDemoPage } from '../pages/adf/demo-shell/process-services/tasksCloudDemoPage';
|
||||
import { AppListCloudComponent } from '../pages/adf/process-cloud/appListCloudComponent';
|
||||
import { AppListCloudPage } from '@alfresco/adf-testing';
|
||||
|
||||
import { Tasks } from '../actions/APS-cloud/tasks';
|
||||
import { ProcessDefinitions } from '../actions/APS-cloud/process-definitions';
|
||||
import { ProcessInstances } from '../actions/APS-cloud/process-instances';
|
||||
import { Query } from '../actions/APS-cloud/query';
|
||||
import { Util } from '../util/util';
|
||||
import { browser } from 'protractor';
|
||||
|
||||
describe('Task filters cloud', () => {
|
||||
|
||||
@ -35,7 +36,7 @@ describe('Task filters cloud', () => {
|
||||
const settingsPage = new SettingsPage();
|
||||
const loginSSOPage = new LoginSSOPage();
|
||||
const navigationBarPage = new NavigationBarPage();
|
||||
const appListCloudComponent = new AppListCloudComponent();
|
||||
const appListCloudComponent = new AppListCloudPage();
|
||||
const tasksCloudDemoPage = new TasksCloudDemoPage();
|
||||
const tasksService: Tasks = new Tasks();
|
||||
const processDefinitionService: ProcessDefinitions = new ProcessDefinitions();
|
||||
@ -55,6 +56,7 @@ describe('Task filters cloud', () => {
|
||||
silentLogin = false;
|
||||
settingsPage.setProviderBpmSso(TestConfig.adf.hostBPM, TestConfig.adf.hostSso, TestConfig.adf.hostIdentity, silentLogin);
|
||||
loginSSOPage.clickOnSSOButton();
|
||||
browser.ignoreSynchronization = true;
|
||||
loginSSOPage.loginAPS(user, password);
|
||||
|
||||
await tasksService.init(user, password);
|
||||
|
@ -9,6 +9,29 @@
|
||||
"jasmine",
|
||||
"jasminewd2",
|
||||
"node"
|
||||
]
|
||||
],
|
||||
"paths": {
|
||||
"@alfresco/adf-extensions": [
|
||||
"../lib/extensions"
|
||||
],
|
||||
"@alfresco/adf-core": [
|
||||
"../lib/core"
|
||||
],
|
||||
"@alfresco/adf-content-services": [
|
||||
"../lib/content-services"
|
||||
],
|
||||
"@alfresco/adf-process-services": [
|
||||
"../lib/process-services"
|
||||
],
|
||||
"@alfresco/adf-insights": [
|
||||
"../lib/insights"
|
||||
],
|
||||
"@alfresco/adf-process-services-cloud": [
|
||||
"../lib/process-services-cloud"
|
||||
],
|
||||
"@alfresco/adf-testing": [
|
||||
"../../lib/testing"
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -3,3 +3,5 @@
|
||||
*/
|
||||
|
||||
export * from './header.page';
|
||||
export * from '../../material/tabs.page';
|
||||
export * from './user-info.page';
|
||||
|
@ -15,11 +15,11 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import { Util } from '../../../util/util';
|
||||
import { TabsPage } from '../material/tabsPage';
|
||||
import { element, by, browser, protractor } from 'protractor';
|
||||
import { BrowserVisibility } from '../browser-visibility';
|
||||
import { TabsPage } from '../../material/tabs.page';
|
||||
|
||||
export class UserInfoDialog {
|
||||
export class UserInfoPage {
|
||||
|
||||
dialog = element.all(by.css('mat-card[class*="adf-userinfo-card"]')).first();
|
||||
userImage = element(by.css('div[id="user-initial-image"]'));
|
||||
@ -37,19 +37,25 @@ export class UserInfoDialog {
|
||||
userInfoSsoHeaderTitle = this.dialog.element(by.css('div[id="identity-username"]'));
|
||||
userInfoSsoTitle = element(by.css('.adf-userinfo__detail-title'));
|
||||
ssoEmail = element(by.id('identity-email'));
|
||||
userProfileButton = element(by.css('button[data-automation-id="adf-user-profile"]'));
|
||||
|
||||
dialogIsDisplayed() {
|
||||
Util.waitUntilElementIsVisible(this.dialog);
|
||||
BrowserVisibility.waitUntilElementIsVisible(this.dialog);
|
||||
return this;
|
||||
}
|
||||
|
||||
dialogIsNotDisplayed() {
|
||||
Util.waitUntilElementIsNotOnPage(this.dialog);
|
||||
BrowserVisibility.waitUntilElementIsNotOnPage(this.dialog);
|
||||
return this;
|
||||
}
|
||||
|
||||
clickUserProfile() {
|
||||
BrowserVisibility.waitUntilElementIsVisible(this.userProfileButton);
|
||||
this.userProfileButton.click();
|
||||
}
|
||||
|
||||
clickOnContentServicesTab() {
|
||||
let tabsPage = new TabsPage;
|
||||
let tabsPage = new TabsPage();
|
||||
tabsPage.clickTabByTitle('Content Services');
|
||||
return this;
|
||||
}
|
||||
@ -67,92 +73,93 @@ export class UserInfoDialog {
|
||||
}
|
||||
|
||||
userImageIsDisplayed() {
|
||||
Util.waitUntilElementIsVisible(this.userImage);
|
||||
BrowserVisibility.waitUntilElementIsVisible(this.userImage);
|
||||
return this;
|
||||
}
|
||||
|
||||
getContentHeaderTitle() {
|
||||
Util.waitUntilElementIsVisible(this.dialog);
|
||||
Util.waitUntilElementIsVisible(this.userInfoEcmHeaderTitle);
|
||||
BrowserVisibility.waitUntilElementIsVisible(this.dialog);
|
||||
BrowserVisibility.waitUntilElementIsVisible(this.userInfoEcmHeaderTitle);
|
||||
return this.userInfoEcmHeaderTitle.getText();
|
||||
}
|
||||
|
||||
getContentTitle() {
|
||||
Util.waitUntilElementIsVisible(this.userInfoEcmTitle);
|
||||
BrowserVisibility.waitUntilElementIsVisible(this.userInfoEcmTitle);
|
||||
return this.userInfoEcmTitle.getText();
|
||||
}
|
||||
|
||||
getContentEmail() {
|
||||
Util.waitUntilElementIsVisible(this.ecmEmail);
|
||||
BrowserVisibility.waitUntilElementIsVisible(this.ecmEmail);
|
||||
return this.ecmEmail.getText();
|
||||
}
|
||||
|
||||
getContentJobTitle() {
|
||||
Util.waitUntilElementIsVisible(this.ecmJobTitle);
|
||||
BrowserVisibility.waitUntilElementIsVisible(this.ecmJobTitle);
|
||||
return this.ecmJobTitle.getText();
|
||||
}
|
||||
|
||||
getProcessHeaderTitle() {
|
||||
Util.waitUntilElementIsVisible(this.userInfoProcessHeaderTitle);
|
||||
BrowserVisibility.waitUntilElementIsVisible(this.userInfoProcessHeaderTitle);
|
||||
return this.userInfoProcessHeaderTitle.getText();
|
||||
}
|
||||
|
||||
getProcessTitle() {
|
||||
Util.waitUntilElementIsVisible(this.userInfoProcessTitle);
|
||||
BrowserVisibility.waitUntilElementIsVisible(this.userInfoProcessTitle);
|
||||
return this.userInfoProcessTitle.getText();
|
||||
}
|
||||
|
||||
getProcessEmail() {
|
||||
Util.waitUntilElementIsVisible(this.processEmail);
|
||||
BrowserVisibility.waitUntilElementIsVisible(this.processEmail);
|
||||
return this.processEmail.getText();
|
||||
}
|
||||
|
||||
getProcessTenant() {
|
||||
Util.waitUntilElementIsVisible(this.processTenant);
|
||||
BrowserVisibility.waitUntilElementIsVisible(this.processTenant);
|
||||
return this.processTenant.getText();
|
||||
}
|
||||
|
||||
getSsoHeaderTitle () {
|
||||
Util.waitUntilElementIsVisible(this.userInfoSsoHeaderTitle);
|
||||
BrowserVisibility.waitUntilElementIsVisible(this.userInfoSsoHeaderTitle);
|
||||
return this.userInfoSsoHeaderTitle.getText();
|
||||
}
|
||||
|
||||
getSsoTitle() {
|
||||
Util.waitUntilElementIsVisible(this.userInfoSsoTitle);
|
||||
BrowserVisibility.waitUntilElementIsVisible(this.userInfoSsoTitle);
|
||||
return this.userInfoSsoTitle.getText();
|
||||
}
|
||||
|
||||
getSsoEmail() {
|
||||
Util.waitUntilElementIsVisible(this.ssoEmail);
|
||||
BrowserVisibility.waitUntilElementIsVisible(this.ssoEmail);
|
||||
return this.ssoEmail.getText();
|
||||
}
|
||||
|
||||
closeUserProfile() {
|
||||
Util.waitUntilElementIsVisible(this.dialog);
|
||||
BrowserVisibility.waitUntilElementIsVisible(this.dialog);
|
||||
browser.actions().sendKeys(protractor.Key.ESCAPE).perform();
|
||||
}
|
||||
|
||||
checkACSProfileImage() {
|
||||
Util.waitUntilElementIsVisible(this.acsImage);
|
||||
BrowserVisibility.waitUntilElementIsVisible(this.acsImage);
|
||||
}
|
||||
|
||||
checkAPSProfileImage() {
|
||||
Util.waitUntilElementIsVisible(this.apsImage);
|
||||
BrowserVisibility.waitUntilElementIsVisible(this.apsImage);
|
||||
}
|
||||
|
||||
checkInitialImage() {
|
||||
Util.waitUntilElementIsVisible(this.initialImage);
|
||||
BrowserVisibility.waitUntilElementIsVisible(this.initialImage);
|
||||
}
|
||||
|
||||
initialImageNotDisplayed() {
|
||||
Util.waitUntilElementIsNotOnPage(this.initialImage);
|
||||
BrowserVisibility.waitUntilElementIsNotOnPage(this.initialImage);
|
||||
}
|
||||
|
||||
ACSProfileImageNotDisplayed() {
|
||||
Util.waitUntilElementIsNotOnPage(this.acsImage);
|
||||
BrowserVisibility.waitUntilElementIsNotOnPage(this.acsImage);
|
||||
}
|
||||
|
||||
APSProfileImageNotDisplayed() {
|
||||
Util.waitUntilElementIsNotOnPage(this.apsImage);
|
||||
BrowserVisibility.waitUntilElementIsNotOnPage(this.apsImage);
|
||||
}
|
||||
|
||||
}
|
5
lib/testing/src/lib/material/public-api.ts
Normal file
5
lib/testing/src/lib/material/public-api.ts
Normal file
@ -0,0 +1,5 @@
|
||||
/*
|
||||
* Public API Surface of testing
|
||||
*/
|
||||
|
||||
export * from './tabs.page';
|
@ -16,13 +16,13 @@
|
||||
*/
|
||||
|
||||
import { element, by } from 'protractor';
|
||||
import { Util } from '../../../util/util';
|
||||
import { BrowserVisibility } from '../core/browser-visibility';
|
||||
|
||||
export class TabsPage {
|
||||
|
||||
clickTabByTitle(tabTitle) {
|
||||
let tab = element(by.cssContainingText("div[id*='mat-tab-label']", tabTitle));
|
||||
Util.waitUntilElementIsVisible(tab);
|
||||
BrowserVisibility.waitUntilElementIsVisible(tab);
|
||||
tab.click();
|
||||
}
|
||||
|
@ -0,0 +1,5 @@
|
||||
/*
|
||||
* Public API Surface of testing
|
||||
*/
|
||||
|
||||
export * from '../app/app-list-cloud.page';
|
@ -1,36 +0,0 @@
|
||||
/*!
|
||||
* @license
|
||||
* Copyright 2019 Alfresco Software, Ltd.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import { by, element } from 'protractor';
|
||||
import { BrowserVisibility } from '../../core/browser-visibility';
|
||||
import { AppListCloudPage } from './app-list-cloud.page';
|
||||
|
||||
export class NavigationBarPage {
|
||||
processServicesCloudButton = element(by.css('a[data-automation-id="Process Cloud"]'));
|
||||
userProfileButton = element(by.css('button[data-automation-id="adf-user-profile"]'));
|
||||
|
||||
navigateToProcessServicesCloudPage() {
|
||||
BrowserVisibility.waitUntilElementIsVisible(this.processServicesCloudButton);
|
||||
this.processServicesCloudButton.click();
|
||||
return new AppListCloudPage();
|
||||
}
|
||||
|
||||
clickUserProfile() {
|
||||
BrowserVisibility.waitUntilElementIsVisible(this.userProfileButton);
|
||||
this.userProfileButton.click();
|
||||
}
|
||||
}
|
@ -2,7 +2,6 @@
|
||||
* Public API Surface of testing
|
||||
*/
|
||||
|
||||
export * from './app-list-cloud.page';
|
||||
export * from './navigation-bar.page';
|
||||
export * from './login-sso.page';
|
||||
export * from './user-info-dialog.page';
|
||||
export * from '../../core/pages/user-info.page';
|
||||
export * from '../app/app-list-cloud.page';
|
||||
|
@ -1,47 +0,0 @@
|
||||
/*!
|
||||
* @license
|
||||
* Copyright 2019 Alfresco Software, Ltd.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import { element, by, browser, protractor } from 'protractor';
|
||||
import { BrowserVisibility } from '../../core/browser-visibility';
|
||||
|
||||
export class UserInfoDialogPage {
|
||||
|
||||
dialog = element.all(by.css('mat-card[class*="adf-userinfo-card"]')).first();
|
||||
userInfoSsoHeaderTitle = this.dialog.element(by.css('div[id="identity-username"]'));
|
||||
userInfoSsoTitle = element(by.css('.adf-userinfo__detail-title'));
|
||||
ssoEmail = element(by.id('identity-email'));
|
||||
|
||||
getSsoHeaderTitle () {
|
||||
BrowserVisibility.waitUntilElementIsVisible(this.userInfoSsoHeaderTitle);
|
||||
return this.userInfoSsoHeaderTitle.getText();
|
||||
}
|
||||
|
||||
getSsoTitle() {
|
||||
BrowserVisibility.waitUntilElementIsVisible(this.userInfoSsoTitle);
|
||||
return this.userInfoSsoTitle.getText();
|
||||
}
|
||||
|
||||
getSsoEmail() {
|
||||
BrowserVisibility.waitUntilElementIsVisible(this.ssoEmail);
|
||||
return this.ssoEmail.getText();
|
||||
}
|
||||
|
||||
closeUserProfile() {
|
||||
BrowserVisibility.waitUntilElementIsVisible(this.dialog);
|
||||
browser.actions().sendKeys(protractor.Key.ESCAPE).perform();
|
||||
}
|
||||
}
|
@ -4,3 +4,4 @@
|
||||
|
||||
export * from './pages/public-api';
|
||||
export * from './actions/public-api';
|
||||
export * from './app/public-api';
|
||||
|
@ -3,6 +3,7 @@
|
||||
*/
|
||||
|
||||
export * from './lib/core/public-api';
|
||||
export * from './lib/material/public-api';
|
||||
export * from './lib/content-services/public-api';
|
||||
export * from './lib/process-services/public-api';
|
||||
export * from './lib/process-services-cloud/public-api';
|
||||
|
Loading…
x
Reference in New Issue
Block a user