Remove discovery (#5212)

* remove discovery

* remoce discovery test

* fix save remote

* use host acs to save screenshot

* fix e2e

* remove invalid test

* fix the package version
This commit is contained in:
Eugenio Romano
2019-11-05 16:15:54 +02:00
committed by Denys Vuika
parent 040fc52724
commit 7d36400dbd
9 changed files with 40 additions and 109 deletions

View File

@@ -1,43 +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 { LoginSSOPage, SettingsPage } from '@alfresco/adf-testing';
import { browser } from 'protractor';
describe('Login component - SSO', () => {
const settingsPage = new SettingsPage();
const loginSSOPage = new LoginSSOPage();
describe('SSO Login Error for login component', () => {
afterEach(async () => {
await browser.executeScript('window.sessionStorage.clear();');
await browser.executeScript('window.localStorage.clear();');
});
it('[C299205] Should display the login error message when the SSO identity service is wrongly configured', async () => {
await settingsPage.setProviderEcmSso(browser.params.testConfig.adf_acs.host,
'http://aps22/auth/realms/alfresco',
browser.params.testConfig.adf.hostIdentity, false, true, browser.params.config.oauth2.clientId);
await loginSSOPage.clickOnSSOButton();
await loginSSOPage.checkLoginErrorIsDisplayed();
await expect(loginSSOPage.getLoginErrorMessage()).toContain('SSO Authentication server unreachable');
});
});
});

View File

@@ -50,6 +50,8 @@ describe('Login component - SSO', () => {
await settingsPage.setProviderEcmSso(browser.params.testConfig.adf_acs.host,
browser.params.testConfig.adf.hostSso,
browser.params.testConfig.adf.hostIdentity, true, true, browser.params.config.oauth2.clientId);
await browser.refresh();
await loginSSOPage.loginSSOIdentityService(browser.params.testConfig.adf.adminEmail, browser.params.testConfig.adf.adminPassword);
});

View File

@@ -2,7 +2,9 @@ const htmlReporter = require('protractor-html-reporter-2');
const fs = require('fs');
const rimraf = require('rimraf');
const path = require('path');
const projectRoot = path.resolve(__dirname);
const projectRoot = path.resolve(__dirname,'../../');
let FOLDER = process.env.FOLDER || '';
function buildNumber() {
let buildNumber = process.env.TRAVIS_BUILD_NUMBER;
@@ -14,7 +16,7 @@ function buildNumber() {
}
async function uploadScreenshot(alfrescoJsApi, retryCount) {
let files = fs.readdirSync(path.join(__dirname, './e2e-output/screenshots'));
let files = fs.readdirSync(path.join(__dirname, '../../e2e-output/screenshots'));
if (files && files.length > 0) {
@@ -38,7 +40,7 @@ async function uploadScreenshot(alfrescoJsApi, retryCount) {
}
for (const fileName of files) {
let pathFile = path.join(__dirname, './e2e-output/screenshots', fileName);
let pathFile = path.join(__dirname, '../../e2e-output/screenshots', fileName);
let file = fs.createReadStream(pathFile);
let safeFileName = fileName.replace(new RegExp('"', 'g'), '');
@@ -63,7 +65,7 @@ async function uploadScreenshot(alfrescoJsApi, retryCount) {
}
async function uploadReport(alfrescoJsApi, filenameReport) {
let pathFile = path.join(__dirname, './e2e-output/junit-report/html', filenameReport + '.html');
let pathFile = path.join(__dirname, '../../e2e-output/junit-report/html', filenameReport + '.html');
let reportFile = fs.createReadStream(pathFile);
let reportFolder;