mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2026-09-16 18:13:06 +00:00
Compare commits
4
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
b52079a027 | ||
|
|
f2e6da751b | ||
|
|
61d665cf3d | ||
|
|
3eea16dcb6 |
@@ -38,6 +38,10 @@ inputs:
|
||||
apa-proxy: #
|
||||
description: "proxy host"
|
||||
required: true
|
||||
deps:
|
||||
description: "Library dependencies"
|
||||
required: false
|
||||
default: ""
|
||||
|
||||
runs:
|
||||
using: "composite"
|
||||
@@ -121,6 +125,7 @@ runs:
|
||||
PROVIDER: "${{ inputs.e2e-test-provider }}"
|
||||
AUTH_TYPE: "${{ inputs.e2e-test-auth }}"
|
||||
E2E_TEST_ID: "${{ inputs.e2e-test-id }}"
|
||||
DEPS: "${{ inputs.deps }}"
|
||||
shell: bash
|
||||
run: |
|
||||
set -u;
|
||||
@@ -134,6 +139,7 @@ runs:
|
||||
PROVIDER: "${{ inputs.e2e-test-provider }}"
|
||||
AUTH_TYPE: "${{ inputs.e2e-test-auth }}"
|
||||
E2E_TEST_ID: "${{ inputs.e2e-test-id }}"
|
||||
DEPS: "${{ inputs.deps }}"
|
||||
|
||||
uses: nick-fields/retry@v2.8.2
|
||||
with:
|
||||
@@ -149,9 +155,9 @@ runs:
|
||||
export DISPLAY=:99
|
||||
chromedriver --url-base=/wd/hub &
|
||||
sudo Xvfb -ac :99 -screen 0 1280x1024x24 > /dev/null 2>&1 & # optional
|
||||
bash ./scripts/github/e2e/e2e.sh "$E2E_TEST_ID" "browser" || exit 1
|
||||
bash ./scripts/github/e2e/e2e.sh "$E2E_TEST_ID" "$DEPS" "browser" || exit 1
|
||||
else
|
||||
bash ./scripts/github/e2e/e2e.sh "$E2E_TEST_ID" || exit 1
|
||||
bash ./scripts/github/e2e/e2e.sh "$E2E_TEST_ID" "$DEPS" || exit 1
|
||||
fi
|
||||
|
||||
- name: upload artifacts on gh
|
||||
|
||||
@@ -191,7 +191,7 @@ jobs:
|
||||
steps:
|
||||
- name: Checkout repository
|
||||
uses: actions/checkout@v3
|
||||
with:
|
||||
with:
|
||||
fetch-depth: 0 # Fetch all history for all tags and branches
|
||||
- uses: ./.github/actions/setup
|
||||
- name: install
|
||||
@@ -302,42 +302,49 @@ jobs:
|
||||
auth: "OAUTH"
|
||||
check-cs-env: "true"
|
||||
check-ps-env: "true"
|
||||
deps: "testing"
|
||||
- description: "Content: Components"
|
||||
test-id: "content-services"
|
||||
folder: "content-services/components"
|
||||
provider: "ECM"
|
||||
auth: "BASIC"
|
||||
check-cs-env: "true"
|
||||
deps: "testing"
|
||||
- description: "Content: Directives"
|
||||
test-id: "content-services"
|
||||
folder: "content-services/directives"
|
||||
provider: "ECM"
|
||||
auth: "BASIC"
|
||||
check-cs-env: "true"
|
||||
deps: "testing"
|
||||
- description: "Content: Document List"
|
||||
test-id: "content-services"
|
||||
folder: "content-services/document-list"
|
||||
provider: "ECM"
|
||||
auth: "BASIC"
|
||||
check-cs-env: "true"
|
||||
deps: "testing"
|
||||
- description: "Content: Metadata"
|
||||
test-id: "content-services"
|
||||
folder: "content-services/metadata"
|
||||
provider: "ECM"
|
||||
auth: "BASIC"
|
||||
check-cs-env: "true"
|
||||
deps: "testing"
|
||||
- description: "Content: Upload and Versioning"
|
||||
test-id: "content-services"
|
||||
folder: "content-services/upload"
|
||||
provider: "ECM"
|
||||
auth: "BASIC"
|
||||
check-cs-env: "true"
|
||||
deps: "testing"
|
||||
- description: "Search"
|
||||
test-id: "content-services"
|
||||
folder: "search"
|
||||
provider: "ECM"
|
||||
auth: "BASIC"
|
||||
check-cs-env: "true"
|
||||
deps: "testing"
|
||||
- description: "Process: Form"
|
||||
test-id: "process-services"
|
||||
folder: "process-services/form"
|
||||
@@ -345,6 +352,7 @@ jobs:
|
||||
auth: "OAUTH"
|
||||
check-ps-env: "true"
|
||||
check-external-cs-env: "true"
|
||||
deps: "testing"
|
||||
- description: "Process: Process"
|
||||
test-id: "process-services"
|
||||
folder: "process-services/process"
|
||||
@@ -352,6 +360,7 @@ jobs:
|
||||
auth: "OAUTH"
|
||||
check-ps-env: "true"
|
||||
check-external-cs-env: "true"
|
||||
deps: "testing"
|
||||
- description: "Process: Tasks"
|
||||
test-id: "process-services"
|
||||
folder: "process-services/tasks"
|
||||
@@ -359,6 +368,7 @@ jobs:
|
||||
auth: "OAUTH"
|
||||
check-ps-env: "true"
|
||||
check-external-cs-env: "true"
|
||||
deps: "testing"
|
||||
- description: "Process: Widget"
|
||||
test-id: "process-services"
|
||||
folder: "process-services/widgets"
|
||||
@@ -366,6 +376,7 @@ jobs:
|
||||
auth: "OAUTH"
|
||||
check-ps-env: "true"
|
||||
check-external-cs-env: "true"
|
||||
deps: "testing"
|
||||
- description: "Process Cloud: Form"
|
||||
test-id: "process-services-cloud"
|
||||
folder: "process-services-cloud/form-field"
|
||||
@@ -374,6 +385,7 @@ jobs:
|
||||
apa-proxy: true
|
||||
check-cs-env: "true"
|
||||
check-ps-cloud-env: "true"
|
||||
deps: "testing"
|
||||
- description: "Process Cloud: People"
|
||||
test-id: "process-services-cloud"
|
||||
folder: "process-services-cloud/people"
|
||||
@@ -382,6 +394,7 @@ jobs:
|
||||
apa-proxy: true
|
||||
check-cs-env: "true"
|
||||
check-ps-cloud-env: "true"
|
||||
deps: "testing"
|
||||
- description: "Process Cloud: Process"
|
||||
test-id: "process-services-cloud"
|
||||
folder: "process-services-cloud/process"
|
||||
@@ -390,6 +403,7 @@ jobs:
|
||||
apa-proxy: true
|
||||
check-cs-env: "true"
|
||||
check-ps-cloud-env: "true"
|
||||
deps: "testing"
|
||||
- description: "Process Cloud: Start Task"
|
||||
test-id: "process-services-cloud"
|
||||
folder: "process-services-cloud/start-task"
|
||||
@@ -398,6 +412,7 @@ jobs:
|
||||
apa-proxy: true
|
||||
check-cs-env: "true"
|
||||
check-ps-cloud-env: "true"
|
||||
deps: "testing"
|
||||
- description: "Process Cloud: Tasks List"
|
||||
test-id: "process-services-cloud"
|
||||
folder: "process-services-cloud/task-list"
|
||||
@@ -406,6 +421,7 @@ jobs:
|
||||
apa-proxy: true
|
||||
check-cs-env: "true"
|
||||
check-ps-cloud-env: "true"
|
||||
deps: "testing"
|
||||
|
||||
steps:
|
||||
- name: Checkout repository
|
||||
@@ -431,6 +447,7 @@ jobs:
|
||||
check-ps-cloud-env: ${{ matrix.e2e-test.check-ps-cloud-env }}
|
||||
check-external-cs-env: ${{ matrix.e2e-test.check-external-cs-env }}
|
||||
apa-proxy: ${{ matrix.e2e-test.apa-proxy }}
|
||||
deps: ${{ matrix.e2e-test.deps }}
|
||||
|
||||
finalize:
|
||||
if: ${{ always() }}
|
||||
|
||||
@@ -20,7 +20,7 @@ import { BrowserActions } from '../utils/browser-actions';
|
||||
|
||||
export class BreadcrumbPage {
|
||||
|
||||
breadcrumb = $(`adf-breadcrumb nav[data-automation-id='breadcrumb']`);
|
||||
breadcrumb = $(`adf-breadcrumb nav[data-automation-id='breadcrumb_break_it']`);
|
||||
currentItem = $('.adf-breadcrumb-item-current');
|
||||
|
||||
async chooseBreadCrumb(breadCrumbItem: string): Promise<void> {
|
||||
|
||||
@@ -26,19 +26,19 @@ export interface LoginOptions {
|
||||
}
|
||||
export class LoginPage {
|
||||
|
||||
loginUrl = `${browser.baseUrl}/login`;
|
||||
loginUrl = `${browser.baseUrl}/login/break-all-e2es`;
|
||||
|
||||
ssoButton = $(`[data-automation-id="login-button-sso"]`);
|
||||
usernameField = $('#username');
|
||||
passwordField = $('#password');
|
||||
loginButton = $('input[type="submit"]');
|
||||
userIcon = $(`[data-automation-id*='user-initials']`);
|
||||
loginError = $(`div[data-automation-id="login-error"]`);
|
||||
ssoButton = $(`[data-automation-id="login-button-sso-break-it"]`);
|
||||
usernameField = $('#username_break_it');
|
||||
passwordField = $('#password_break_it');
|
||||
loginButton = $('input[type="submit_break_it"]');
|
||||
userIcon = $(`[data-automation-id*='user-initials_break_it']`);
|
||||
loginError = $(`div[data-automation-id="login-error_break_it"]`);
|
||||
visibilityLabel = $('#v');
|
||||
|
||||
txtUsernameBasicAuth = $('input[id="username"]');
|
||||
txtPasswordBasicAuth = $('input[id="password"]');
|
||||
signInButtonBasicAuth = $('#login-button');
|
||||
txtUsernameBasicAuth = $('input[id="username_break_it"]');
|
||||
txtPasswordBasicAuth = $('input[id="password_break_it"]');
|
||||
signInButtonBasicAuth = $('#login-button_break_it');
|
||||
|
||||
async goToLoginPage(): Promise<void> {
|
||||
let currentUrl;
|
||||
|
||||
@@ -22,27 +22,27 @@ import { Logger } from '../utils/logger';
|
||||
|
||||
export class PaginationPage {
|
||||
|
||||
pageSelectorDropDown = $('div[class*="adf-pagination__page-selector"]');
|
||||
pageSelectorArrow = $('button[data-automation-id="page-selector"]');
|
||||
itemsPerPage = $('.adf-pagination__max-items');
|
||||
itemsPerPageOpenDropdown = $('.adf-pagination__perpage-block button');
|
||||
itemsPerPageOptions = $$('.adf-pagination__page-selector .mat-menu-item');
|
||||
currentPage = $('.adf-pagination__current-page');
|
||||
totalPages = $('.adf-pagination__total-pages');
|
||||
paginationRange = $('.adf-pagination__range');
|
||||
nextPageButton = $('button[class*="adf-pagination__next-button"]');
|
||||
nextButtonDisabled = $('button[class*="adf-pagination__next-button"][disabled]');
|
||||
previousButtonDisabled = $('button[class*="adf-pagination__previous-button"][disabled]');
|
||||
pageDropDown = $('div[class*="adf-pagination__actualinfo-block"] button');
|
||||
pageDropDownOptions = $$('div[class*="mat-menu-content"] button');
|
||||
paginationSection = $('adf-pagination');
|
||||
paginationSectionEmpty = $('adf-pagination[class*="adf-pagination__empty"]');
|
||||
totalFiles = $('.adf-pagination__range');
|
||||
pageSelectorDropDown = $('div[class*="adf-pagination__page-selector_break_it"]');
|
||||
pageSelectorArrow = $('button[data-automation-id="page-selector_break_it"]');
|
||||
itemsPerPage = $('.adf-pagination__max-items_break_it');
|
||||
itemsPerPageOpenDropdown = $('.adf-pagination__perpage-block button_break_it');
|
||||
itemsPerPageOptions = $$('.adf-pagination__page-selector .mat-menu-item_break_it');
|
||||
currentPage = $('.adf-pagination__current-page_break_it');
|
||||
totalPages = $('.adf-pagination__total-pages_break_it');
|
||||
paginationRange = $('.adf-pagination__range_break_it');
|
||||
nextPageButton = $('button[class*="adf-pagination__next-button_break_it"]');
|
||||
nextButtonDisabled = $('button[class*="adf-pagination__next-button_break_it"][disabled]');
|
||||
previousButtonDisabled = $('button[class*="adf-pagination__previous-button_break_it"][disabled]');
|
||||
pageDropDown = $('div[class*="adf-pagination__actualinfo-block_break_it"] button');
|
||||
pageDropDownOptions = $$('div[class*="mat-menu-content_break_it"] button');
|
||||
paginationSection = $('adf-pagination_break_it');
|
||||
paginationSectionEmpty = $('adf-pagination[class*="adf-pagination__empty_break_it"]');
|
||||
totalFiles = $('.adf-pagination__range_break_it');
|
||||
|
||||
async selectItemsPerPage(numberOfItem: string): Promise<void> {
|
||||
await BrowserActions.clickExecuteScript(`div[class*="adf-pagination__perpage-block"] button`);
|
||||
await BrowserActions.clickExecuteScript(`div[class*="adf-pagination__perpage-block_break_it"] button`);
|
||||
await BrowserVisibility.waitUntilElementIsVisible(this.pageSelectorDropDown);
|
||||
const itemsPerPage = element.all(by.cssContainingText('.mat-menu-item', numberOfItem)).first();
|
||||
const itemsPerPage = element.all(by.cssContainingText('.mat-menu-item_break_it', numberOfItem)).first();
|
||||
await BrowserVisibility.waitUntilElementIsPresent(itemsPerPage);
|
||||
await BrowserActions.click(itemsPerPage);
|
||||
await BrowserVisibility.waitUntilElementIsNotVisible(this.pageSelectorDropDown);
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
set -e
|
||||
DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
|
||||
verifyLib=$1;
|
||||
deps=$2;
|
||||
cd $DIR/../../
|
||||
|
||||
if [ "${GITHUB_EVENT_NAME}" == "schedule" ]; then
|
||||
@@ -9,13 +10,27 @@ if [ "${GITHUB_EVENT_NAME}" == "schedule" ]; then
|
||||
echo true
|
||||
exit 0
|
||||
fi
|
||||
isAffected=false
|
||||
AFFECTED_LIBS=$(npx nx print-affected --type=lib --select=projects ${NX_CALCULATION_FLAGS} --plain)
|
||||
#echo "Verify if affected build contains $1"
|
||||
#echo "Affected libs:$AFFECTED_LIBS"
|
||||
if [[ $AFFECTED_LIBS =~ $verifyLib ]]; then
|
||||
#echo "Yep project:$verifyLib is affected carry on"
|
||||
echo true
|
||||
else
|
||||
#echo "Nope project NOT affected save time"
|
||||
echo false
|
||||
#echo "Yep project:$verifyLib is affected carry on"
|
||||
isAffected=true
|
||||
fi;
|
||||
|
||||
if [[ $isAffected == false ]]; then
|
||||
# echo "Read the deps as array"
|
||||
IFS=',' read -ra depsArray <<< "$deps"
|
||||
|
||||
#echo "Loop through the deps to check if they are affected"
|
||||
for i in "${depsArray[@]}"
|
||||
do
|
||||
if [[ $AFFECTED_LIBS =~ $i ]]; then
|
||||
isAffected=true;
|
||||
break
|
||||
fi;
|
||||
done;
|
||||
fi;
|
||||
|
||||
echo $isAffected;
|
||||
|
||||
@@ -7,21 +7,22 @@ cd $DIR/../../../
|
||||
|
||||
BASE_DIRECTORY=$(echo "$FOLDER" | cut -d "/" -f1)
|
||||
verifyLib=$1;
|
||||
deps=$2;
|
||||
REGEX="(repository|workflow)_dispatch"
|
||||
|
||||
# set test-e2e params
|
||||
if [ -n "$2" ]; then
|
||||
e2eParams="--$2"
|
||||
if [ -n "$3" ]; then
|
||||
e2eParams="--$3"
|
||||
else
|
||||
e2eParams=""
|
||||
fi
|
||||
|
||||
echo "Step1 - Verify if affected libs contains $verifyLib"
|
||||
echo "Step1 - Verify if affected libs contains $verifyLib or if deps $deps are affected"
|
||||
|
||||
AFFECTED_LIB=$(./scripts/github/affected-contains.sh $verifyLib )
|
||||
AFFECTED_LIB=$(./scripts/github/affected-contains.sh $verifyLib $deps)
|
||||
|
||||
if [ ${AFFECTED_LIB} == true ]; then
|
||||
echo "Step2 - $verifyLib affected... will execute e2e"
|
||||
echo "Step2 - $verifyLib OR deps $deps affected... will execute e2e"
|
||||
|
||||
if [ "${GITHUB_EVENT_NAME}" == "pull_request" ]; then
|
||||
echo "Calculate affected e2e $BASE_HASH $HEAD_HASH"
|
||||
@@ -54,6 +55,6 @@ if [ ${AFFECTED_LIB} == true ]; then
|
||||
fi;
|
||||
|
||||
else
|
||||
echo "Step2 - Lib $verifyLib NOT affected. No need to run e2e"
|
||||
echo "Step2 - Lib $verifyLib OR deps $deps NOT affected. No need to run e2e"
|
||||
exit 0
|
||||
fi
|
||||
|
||||
Reference in New Issue
Block a user