Skip to content

Commit

Permalink
Fix lint error
Browse files Browse the repository at this point in the history
  • Loading branch information
nesrineabdmouleh committed Jan 9, 2025
1 parent 09d3e9f commit 09eff0d
Show file tree
Hide file tree
Showing 3 changed files with 26 additions and 1 deletion.
3 changes: 3 additions & 0 deletions src/pages/BO/modules/autoupgrade/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,9 @@ const psVersion = testContext.getPSVersion();

/* eslint-disable global-require, @typescript-eslint/no-require-imports */
function requirePage(): ModuleAutoupgradeMainPageInterface {
if (semver.lte(psVersion, '7.1.2') && semver.gte(psVersion, '7.1.0')) {
return require('@versions/1.7.1/pages/BO/modules/autoupgrade').autoupgrade;
}
if (semver.lt(psVersion, '7.4.0')) {
return require('@versions/1.7.3/pages/BO/modules/autoupgrade').autoupgrade;
}
Expand Down
22 changes: 22 additions & 0 deletions src/versions/1.7.1/pages/BO/modules/autoupgrade/index.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
import {ModuleAutoupgradeMainPageInterface} from '@interfaces/BO/modules/autoupgrade';
import {Autoupgrade} from '@versions/1.7.3/pages/BO/modules/autoupgrade';

/**
* Module configuration page for module : Autoupgrade, contains selectors and functions for the page
* @class
* @extends ModuleConfiguration
*/
class AutoupgradeVersion extends Autoupgrade implements ModuleAutoupgradeMainPageInterface {
/**
* @constructs
* Setting up texts and selectors to use on module configuration page
*/
constructor() {
super();

this.pageTitle = 'AdminSelfUpgrade > AdminSelfUpgrade • PrestaShop';
}
}

const autoupgrade = new AutoupgradeVersion();
export {autoupgrade, AutoupgradeVersion as Autoupgrade};
2 changes: 1 addition & 1 deletion src/versions/develop/pages/BO/modules/autoupgrade/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import type {Page} from '@playwright/test';
* @extends ModuleConfiguration
*/
class Autoupgrade extends ModuleConfiguration implements ModuleAutoupgradeMainPageInterface {
public readonly pageTitle: string;
public pageTitle: string;

public readonly checkRequirementSuccessMessage: string;

Expand Down

0 comments on commit 09eff0d

Please sign in to comment.