AAE-19551 e2e material locators refactor (#9403)

* AAE-19551 e2e-material-locators-refactor

* testing lib

* e2e lib

* playwright refactor

* fix lint issues

* bring back excluded process e2e

* fix spinner

* locator fixes
This commit is contained in:
Rafal Szmit
2024-03-07 19:33:03 +01:00
committed by GitHub
parent 75f33b1990
commit b8e62534bf
70 changed files with 764 additions and 239 deletions

View File

@@ -15,6 +15,4 @@
* limitations under the License.
*/
export * from './error.component';
export * from './listbox.component';
export * from './validation.component';

View File

@@ -15,5 +15,6 @@
* limitations under the License.
*/
export * from './material';
export * from './basic';
export * from './base.component';

View File

@@ -17,9 +17,10 @@
import { Page } from '@playwright/test';
import { BaseComponent } from '../base.component';
import { materialLocators } from './material-locators';
export class ErrorComponent extends BaseComponent {
private static rootElement = 'mat-error';
private static rootElement = materialLocators.Error.root;
public content = this.getChild('');
constructor(page: Page) {

View File

@@ -0,0 +1,19 @@
/*!
* @license
* Copyright © 2005-2023 Hyland Software, Inc. and its affiliates. All rights reserved.
*
* 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.
*/
export * from './error.component';
export * from './validation.component';

View File

@@ -0,0 +1,25 @@
/*!
* @license
* Copyright © 2005-2023 Hyland Software, Inc. and its affiliates. All rights reserved.
*
* 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.
*/
export const materialLocators = {
Error: {
root: 'mat-error'
},
Tooltip: {
root: 'mat-tooltip-component'
}
};

View File

@@ -17,9 +17,10 @@
import { Page } from '@playwright/test';
import { BaseComponent } from '../base.component';
import { materialLocators } from './material-locators';
export class TooltipComponent extends BaseComponent {
private static rootElement = 'mat-tooltip-component';
private static rootElement = materialLocators.Tooltip.root;
public content = this.getChild('div');
constructor(page: Page) {

View File

@@ -17,7 +17,7 @@
import { Page } from '@playwright/test';
import { BaseComponent } from '../../page-object/components/base.component';
import { ErrorComponent, TooltipComponent, ListboxComponent } from '../../page-object/components/basic';
import { ErrorComponent, TooltipComponent, ListboxComponent } from '../../page-object/components';
export class GroupComponent extends BaseComponent {
private static rootElement = 'adf-cloud-group';

View File

@@ -17,7 +17,7 @@
import { Page } from '@playwright/test';
import { BaseComponent } from '../../page-object/components/base.component';
import { ErrorComponent, TooltipComponent, ListboxComponent } from '../../page-object/components/basic';
import { ErrorComponent, TooltipComponent, ListboxComponent } from '../../page-object/components';
export class PeopleComponent extends BaseComponent {
private static rootElement = 'adf-cloud-people';