Skip to content

Commit

Permalink
Merge pull request #365 from Progi1984/boFeaturesPage
Browse files Browse the repository at this point in the history
Migrate `@pages/BO/catalog/features` from Core
  • Loading branch information
Progi1984 authored Jan 27, 2025
2 parents b53e454 + 5c9c88f commit 51d26f8
Show file tree
Hide file tree
Showing 4 changed files with 465 additions and 0 deletions.
1 change: 1 addition & 0 deletions src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -228,6 +228,7 @@ export {default as boEmployeesPage} from '@pages/BO/advancedParameters/team/empl
export {default as boEmployeesCreatePage} from '@pages/BO/advancedParameters/team/employees/create';
export {default as boEmployeeSessionsPage} from '@pages/BO/advancedParameters/security/employeeSessions';
export {default as boFeatureFlagPage} from '@pages/BO/advancedParameters/featureFlag';
export {default as boFeaturesPage} from '@pages/BO/catalog/features';
export {default as boInformationPage} from '@pages/BO/advancedParameters/information';
export {default as boImportPage} from '@pages/BO/advancedParameters/import';
export {default as boInvoicesPage} from '@pages/BO/orders/invoices';
Expand Down
23 changes: 23 additions & 0 deletions src/interfaces/BO/catalog/features/index.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
import {BOBasePagePageInterface} from '@interfaces/BO';
import {type Page} from '@playwright/test';

export interface BOFeaturesPageInterface extends BOBasePagePageInterface {
readonly pageTitle: string;

bulkDeleteFeatures(page: Page): Promise<string>;
changePosition(page: Page, actualPosition: number, newPosition: number): Promise<string | null>;
clickOnEditFeature(page: Page, row: number): Promise<void>;
deleteFeature(page: Page, row: number): Promise<string>;
filterTable(page: Page, filterBy: string, value: string): Promise<void>;
getAllRowsColumnContent(page: Page, columnName: string, sortColumnName?: string): Promise<string[]>;
getNumberOfElementInGrid(page: Page): Promise<number>;
getTextColumn(page: Page, row: number, columnName: string, sortColumnName?: string): Promise<string>;
goToAddFeaturePage(page: Page): Promise<void>;
paginationNext(page: Page): Promise<number>;
paginationPrevious(page: Page): Promise<number>;
resetAndGetNumberOfLines(page: Page): Promise<number>;
resetFilter(page: Page): Promise<void>;
selectPaginationLimit(page: Page, number: number): Promise<number>;
sortTable(page: Page, sortBy: string, sortDirection: string): Promise<void>;
viewFeature(page: Page, row: number): Promise<void>;
}
9 changes: 9 additions & 0 deletions src/pages/BO/catalog/features/index.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
import {type BOFeaturesPageInterface} from '@interfaces/BO/catalog/features';

/* eslint-disable global-require, @typescript-eslint/no-require-imports, @typescript-eslint/no-var-requires */
function requirePage(): BOFeaturesPageInterface {
return require('@versions/develop/pages/BO/catalog/features');
}
/* eslint-enable global-require, @typescript-eslint/no-require-imports, @typescript-eslint/no-var-requires */

export default requirePage();
Loading

0 comments on commit 51d26f8

Please sign in to comment.