mirror of
https://github.com/Alfresco/alfresco-content-app.git
synced 2025-09-17 14:21:14 +00:00
eliminate dead code in e2e tests (#3220)
* reduce shared testing dependency * dead code cleanup * eliminate dead code * fix export
This commit is contained in:
@@ -23,7 +23,6 @@
|
||||
*/
|
||||
|
||||
export * from './favorites/favorites-api';
|
||||
export * from './nodes/node-body-create';
|
||||
export * from './nodes/node-content-tree';
|
||||
export * from './nodes/nodes-api';
|
||||
export * from './people/people-api-models';
|
||||
|
@@ -1,38 +0,0 @@
|
||||
/*!
|
||||
* Copyright © 2005-2023 Hyland Software, Inc. and its affiliates. All rights reserved.
|
||||
*
|
||||
* Alfresco Example Content Application
|
||||
*
|
||||
* This file is part of the Alfresco Example Content Application.
|
||||
* If the software was purchased under a paid Alfresco license, the terms of
|
||||
* the paid license agreement will prevail. Otherwise, the software is
|
||||
* provided under the following open source license terms:
|
||||
*
|
||||
* The Alfresco Example Content Application is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU Lesser General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* The Alfresco Example Content Application is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU Lesser General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU Lesser General Public License
|
||||
* along with Alfresco. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
export const NODE_TYPE_FILE = 'cm:content';
|
||||
export const NODE_TYPE_FOLDER = 'cm:folder';
|
||||
export const NODE_TITLE = 'cm:title';
|
||||
export const NODE_DESCRIPTION = 'cm:description';
|
||||
|
||||
export class NodeBodyCreate {
|
||||
constructor(
|
||||
public name: string,
|
||||
public nodeType: string,
|
||||
public relativePath: string = '/',
|
||||
public aspectNames?: string[],
|
||||
public properties?: any[]
|
||||
) {}
|
||||
}
|
@@ -22,7 +22,10 @@
|
||||
* along with Alfresco. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
import { NodeBodyCreate, NODE_TYPE_FILE, NODE_TYPE_FOLDER, NODE_TITLE, NODE_DESCRIPTION } from './node-body-create';
|
||||
const NODE_TYPE_FILE = 'cm:content';
|
||||
const NODE_TYPE_FOLDER = 'cm:folder';
|
||||
const NODE_TITLE = 'cm:title';
|
||||
const NODE_DESCRIPTION = 'cm:description';
|
||||
|
||||
export interface NodeContentTree {
|
||||
name?: string;
|
||||
@@ -32,6 +35,14 @@ export interface NodeContentTree {
|
||||
description?: string;
|
||||
}
|
||||
|
||||
export interface NodeBodyCreate {
|
||||
name: string;
|
||||
nodeType: string;
|
||||
relativePath: string;
|
||||
aspectNames?: string[];
|
||||
properties?: any[];
|
||||
}
|
||||
|
||||
export function flattenNodeContentTree(content: NodeContentTree, relativePath: string = '/'): NodeBodyCreate[] {
|
||||
const { name, files, folders, title, description } = content;
|
||||
const aspectNames: string[] = ['cm:versionable'];
|
||||
|
@@ -22,7 +22,7 @@
|
||||
* along with Alfresco. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
import { browser, protractor, ElementFinder, ExpectedConditions as EC, by, logging, until, WebElement } from 'protractor';
|
||||
import { browser, protractor, ElementFinder, ExpectedConditions as EC, by, until, WebElement } from 'protractor';
|
||||
import { BrowserVisibility, Logger } from '@alfresco/adf-testing';
|
||||
import { BROWSER_WAIT_TIMEOUT } from '../configs';
|
||||
import * as path from 'path';
|
||||
@@ -187,10 +187,6 @@ export class Utils {
|
||||
await browser.actions().sendKeys(protractor.Key.NULL).perform();
|
||||
}
|
||||
|
||||
static async getBrowserLog(): Promise<logging.Entry[]> {
|
||||
return browser.manage().logs().get('browser');
|
||||
}
|
||||
|
||||
static formatDate(date: string): string {
|
||||
return new Date(date).toLocaleDateString('en-US');
|
||||
}
|
||||
|
Reference in New Issue
Block a user