diff --git a/tests/UI/campaigns/functional/FO/hummingbird/08_menuAndNavigation/03_navigationAndDisplay/02_pagination.ts b/tests/UI/campaigns/functional/FO/hummingbird/08_menuAndNavigation/03_navigationAndDisplay/02_pagination.ts new file mode 100644 index 0000000000000..cc72f6b12bdae --- /dev/null +++ b/tests/UI/campaigns/functional/FO/hummingbird/08_menuAndNavigation/03_navigationAndDisplay/02_pagination.ts @@ -0,0 +1,276 @@ +// Import utils +import helper from '@utils/helpers'; +import testContext from '@utils/testContext'; + +// Import commonTests +import loginCommon from '@commonTests/BO/loginBO'; +import {installHummingbird, uninstallHummingbird} from '@commonTests/BO/design/hummingbird'; + +// Import BO pages +import dashboardPage from '@pages/BO/dashboard'; +import productSettingsPage from '@pages/BO/shopParameters/productSettings'; + +// Import pages +import homePage from '@pages/FO/hummingbird/home'; +import categoryPage from '@pages/FO/hummingbird/category'; + +import {expect} from 'chai'; +import type {BrowserContext, Page} from 'playwright'; + +const baseContext: string = 'functional_FO_hummingbird_menuAndNavigation_navigationAndDisplay_pagination'; + +/* +Pre-condition: +- Install the theme hummingbird +Scenario: +- Go to FO>All products page +- Check the pagination in the bottom of the page +- Click on next then on previous +- Edit products per page number to 6 in BO +- Check the new pagination in FO +- Edit products per page number to 20 +- Check the new pagination +Post-condition: +- Reset 'Number of products per page' +- Uninstall the theme hummingbird + */ +describe('FO - Navigation and display : Pagination', async () => { + let browserContext: BrowserContext; + let page: Page; + + // Pre-condition : Install Hummingbird + installHummingbird(`${baseContext}_preTest`); + + // before and after functions + before(async function () { + browserContext = await helper.createBrowserContext(this.browser); + page = await helper.newTab(browserContext); + }); + + after(async () => { + await helper.closeBrowserContext(browserContext); + }); + + describe('FO - Pagination next and previous', async () => { + it('should open the shop page', async function () { + await testContext.addContextItem(this, 'testIdentifier', 'openShopPage', baseContext); + + await homePage.goTo(page, global.FO.URL); + + const result = await homePage.isHomePage(page); + expect(result).to.equal(true); + }); + + it('should go to all products page', async function () { + await testContext.addContextItem(this, 'testIdentifier', 'goToAllProducts', baseContext); + + await homePage.changeLanguage(page, 'en'); + await homePage.goToAllProductsPage(page); + + const isCategoryPageVisible = await categoryPage.isCategoryPage(page); + expect(isCategoryPageVisible, 'Home category page was not opened').to.equal(true); + }); + + it('should check the number of products on the page', async function () { + await testContext.addContextItem(this, 'testIdentifier', 'numberOfProducts', baseContext); + + const numberOfProducts = await categoryPage.getNumberOfProducts(page); + expect(numberOfProducts).to.equal(19); + }); + + it('should check the pagination in the bottom of the page', async function () { + await testContext.addContextItem(this, 'testIdentifier', 'checkPaginationLabel', baseContext); + + const pagesList = await categoryPage.getPagesList(page); + expect(pagesList).to.contain('1 2 Next'); + }); + + it('should click on next', async function () { + await testContext.addContextItem(this, 'testIdentifier', 'clickOnNext', baseContext); + + await categoryPage.goToNextPage(page); + + const numberOfItems = await categoryPage.getShowingItems(page); + expect(numberOfItems).to.equal('Showing 13-19 of 19 item(s)'); + }); + + it('should check the pagination in the bottom of the page', async function () { + await testContext.addContextItem(this, 'testIdentifier', 'checkPaginationLabel1', baseContext); + + const pagesList = await categoryPage.getPagesList(page); + expect(pagesList).to.contain('Previous 1 2'); + }); + + it('should click on previous', async function () { + await testContext.addContextItem(this, 'testIdentifier', 'clickOnPrevious', baseContext); + + await categoryPage.goToPreviousPage(page); + + const numberOfItems = await categoryPage.getShowingItems(page); + expect(numberOfItems).to.equal('Showing 1-12 of 19 item(s)'); + }); + }); + + describe('BO - Edit products per page number to 6', async () => { + it('should login in BO', async function () { + await loginCommon.loginBO(this, page); + }); + + it('should go to \'Shop parameters > Product Settings\' page', async function () { + await testContext.addContextItem(this, 'testIdentifier', 'goToProductSettingsPage1', baseContext); + + await dashboardPage.goToSubMenu( + page, + dashboardPage.shopParametersParentLink, + dashboardPage.productSettingsLink, + ); + + const pageTitle = await productSettingsPage.getPageTitle(page); + expect(pageTitle).to.contains(productSettingsPage.pageTitle); + }); + + it('should change the number of products per page to 6', async function () { + await testContext.addContextItem(this, 'testIdentifier', 'changeNumberOfDays0', baseContext); + + const result = await productSettingsPage.setProductsDisplayedPerPage(page, 6); + expect(result).to.contains(productSettingsPage.successfulUpdateMessage); + }); + }); + + describe('FO - Check the new pagination', async () => { + it('should view my shop page', async function () { + await testContext.addContextItem(this, 'testIdentifier', 'goToShopFO1', baseContext); + + page = await productSettingsPage.viewMyShop(page); + await homePage.changeLanguage(page, 'en'); + + const result = await homePage.isHomePage(page); + expect(result).to.equal(true); + }); + + it('should go to all products page', async function () { + await testContext.addContextItem(this, 'testIdentifier', 'goToAllProducts1', baseContext); + + await homePage.changeLanguage(page, 'en'); + await homePage.goToAllProductsPage(page); + + const isCategoryPageVisible = await categoryPage.isCategoryPage(page); + expect(isCategoryPageVisible, 'Home category page was not opened').to.equal(true); + }); + + it('should check the number of products on the page', async function () { + await testContext.addContextItem(this, 'testIdentifier', 'numberOfProducts2', baseContext); + + const numberOfProducts = await categoryPage.getNumberOfProducts(page); + expect(numberOfProducts).to.equal(19); + }); + + it('should check the pagination in the bottom of the page', async function () { + await testContext.addContextItem(this, 'testIdentifier', 'checkPaginationLabel2', baseContext); + + const pagesList = await categoryPage.getPagesList(page); + expect(pagesList).to.contain('1 2 3 4 Next'); + }); + + it('should click on next', async function () { + await testContext.addContextItem(this, 'testIdentifier', 'clickOnNext1', baseContext); + + await categoryPage.goToNextPage(page); + + const numberOfItems = await categoryPage.getShowingItems(page); + expect(numberOfItems).to.equal('Showing 7-12 of 19 item(s)'); + }); + + it('should check the pagination in the bottom of the page', async function () { + await testContext.addContextItem(this, 'testIdentifier', 'checkPaginationLabel3', baseContext); + + const pagesList = await categoryPage.getPagesList(page); + expect(pagesList).to.contain('Previous 1 2 3 4 Next'); + }); + + it('should click on previous', async function () { + await testContext.addContextItem(this, 'testIdentifier', 'clickOnPrevious1', baseContext); + + await categoryPage.goToPreviousPage(page); + + const numberOfItems = await categoryPage.getShowingItems(page); + expect(numberOfItems).to.equal('Showing 1-6 of 19 item(s)'); + }); + }); + + describe('BO - Edit products per page number to 20', async () => { + it('should close the FO page', async function () { + await testContext.addContextItem(this, 'testIdentifier', 'closeFOPage', baseContext); + + page = await homePage.closePage(browserContext, page, 0); + + const pageTitle = await productSettingsPage.getPageTitle(page); + expect(pageTitle).to.contains(productSettingsPage.pageTitle); + }); + + it('should change the number of products per page to 20', async function () { + await testContext.addContextItem(this, 'testIdentifier', 'changeNumberOfDays1', baseContext); + + const result = await productSettingsPage.setProductsDisplayedPerPage(page, 20); + expect(result).to.contains(productSettingsPage.successfulUpdateMessage); + }); + }); + + describe('FO - Check the new pagination', async () => { + it('should view my shop page', async function () { + await testContext.addContextItem(this, 'testIdentifier', 'goToShopFO2', baseContext); + + page = await productSettingsPage.viewMyShop(page); + await homePage.changeLanguage(page, 'en'); + + const result = await homePage.isHomePage(page); + expect(result).to.equal(true); + }); + + it('should go to all products page', async function () { + await testContext.addContextItem(this, 'testIdentifier', 'goToAllProducts2', baseContext); + + await homePage.changeLanguage(page, 'en'); + await homePage.goToAllProductsPage(page); + + const isCategoryPageVisible = await categoryPage.isCategoryPage(page); + expect(isCategoryPageVisible, 'Home category page was not opened').to.equal(true); + }); + + it('should check the number of products on the page', async function () { + await testContext.addContextItem(this, 'testIdentifier', 'numberOfProducts3', baseContext); + + const numberOfProducts = await categoryPage.getNumberOfProducts(page); + expect(numberOfProducts).to.equal(19); + }); + + it('should check that the pagination label is not visible', async function () { + await testContext.addContextItem(this, 'testIdentifier', 'checkPaginationLabel4', baseContext); + + const isVisible = await categoryPage.isPagesListVisible(page); + expect(isVisible).to.equal(false); + }); + }); + + // Post-condition: Reset number of products per page + describe('POST-TEST : Reset \'Number of products per page\'', async () => { + it('should go back BO', async function () { + await testContext.addContextItem(this, 'testIdentifier', 'goBackToBO4', baseContext); + + page = await homePage.closePage(browserContext, page, 0); + + const pageTitle = await productSettingsPage.getPageTitle(page); + expect(pageTitle).to.contains(productSettingsPage.pageTitle); + }); + + it('should change the number of products per page to 12', async function () { + await testContext.addContextItem(this, 'testIdentifier', 'changeNumberOfDays2', baseContext); + + const result = await productSettingsPage.setProductsDisplayedPerPage(page, 12); + expect(result).to.contains(productSettingsPage.successfulUpdateMessage); + }); + }); + + // Post-condition : Uninstall Hummingbird + uninstallHummingbird(`${baseContext}_postTest`); +}); diff --git a/tests/UI/campaigns/functional/FO/hummingbird/08_menuAndNavigation/03_navigationAndDisplay/03_quickViewProduct.ts b/tests/UI/campaigns/functional/FO/hummingbird/08_menuAndNavigation/03_navigationAndDisplay/03_quickViewProduct.ts new file mode 100644 index 0000000000000..07e3ca0ec1685 --- /dev/null +++ b/tests/UI/campaigns/functional/FO/hummingbird/08_menuAndNavigation/03_navigationAndDisplay/03_quickViewProduct.ts @@ -0,0 +1,199 @@ +// Import utils +import helper from '@utils/helpers'; +import testContext from '@utils/testContext'; + +// Import common tests +import {installHummingbird, uninstallHummingbird} from '@commonTests/BO/design/hummingbird'; + +// Import pages +import homePage from '@pages/FO/hummingbird/home'; +import searchResultsPage from '@pages/FO/hummingbird/searchResults'; +import quickViewModal from '@pages/FO/hummingbird/modal/quickView'; +import blockCartModal from '@pages/FO/hummingbird/modal/blockCart'; + +// Import data +import Products from '@data/demo/products'; + +import {expect} from 'chai'; +import type {BrowserContext, Page} from 'playwright'; + +const baseContext: string = 'functional_FO_hummingbird_menuAndNavigation_navigationAndDisplay_quickViewProducts'; + +/* +Pre-condition: +- Install the theme hummingbird +Scenario: +Go to FO > quick view the product demo_3 and check information +quick view the product demo_12 and check information +quick view the product demo_14 and check information +Post-condition: +- Uninstall the theme hummingbird + */ +describe('FO - Navigation and display : Quick view products', async () => { + let browserContext: BrowserContext; + let page: Page; + + // Pre-condition : Install Hummingbird + installHummingbird(`${baseContext}_preTest`); + + // before and after functions + before(async function () { + browserContext = await helper.createBrowserContext(this.browser); + page = await helper.newTab(browserContext); + }); + + after(async () => { + await helper.closeBrowserContext(browserContext); + }); + + describe(`Quick view the product '${Products.demo_3.name}'`, async () => { + it('should open the shop page', async function () { + await testContext.addContextItem(this, 'testIdentifier', 'goToShopFO', baseContext); + + await homePage.goTo(page, global.FO.URL); + + const result = await homePage.isHomePage(page); + expect(result).to.equal(true); + }); + + it(`should search for the product '${Products.demo_3.name}'`, async function () { + await testContext.addContextItem(this, 'testIdentifier', 'searchProduct1', baseContext); + + await homePage.searchProduct(page, Products.demo_3.name); + + const pageTitle = await searchResultsPage.getPageTitle(page); + expect(pageTitle).to.equal(searchResultsPage.pageTitle); + }); + + it(`should quick view the product '${Products.demo_3.name}'`, async function () { + await testContext.addContextItem(this, 'testIdentifier', 'quickViewProduct1', baseContext); + + await searchResultsPage.quickViewProduct(page, 1); + + const isModalVisible = await quickViewModal.isQuickViewProductModalVisible(page); + expect(isModalVisible).to.equal(true); + }); + + it('should check product information', async function () { + await testContext.addContextItem(this, 'testIdentifier', 'checkProductInformation1', baseContext); + + const result = await quickViewModal.getProductDetailsFromQuickViewModal(page); + await Promise.all([ + expect(result.name).to.equal(Products.demo_3.name), + expect(result.price).to.equal(Products.demo_3.finalPrice), + expect(result.taxShippingDeliveryLabel).to.equal('Tax included'), + expect(result.shortDescription).to.equal(Products.demo_3.summary), + expect(result.coverImage).to.contains(Products.demo_3.coverImage), + expect(result.thumbImage).to.contains(Products.demo_3.thumbImage), + ]); + }); + + it('should add product to cart and check that the block cart modal is visible', async function () { + await testContext.addContextItem(this, 'testIdentifier', 'clickOnContinueShopping', baseContext); + + await quickViewModal.addToCartByQuickView(page); + + const isVisible = await blockCartModal.isBlockCartModalVisible(page); + expect(isVisible).to.equal(true); + }); + + it('should click on continue shopping button', async function () { + await testContext.addContextItem(this, 'testIdentifier', 'continueShopping', baseContext); + + const isModalNotVisible = await blockCartModal.continueShopping(page); + expect(isModalNotVisible).to.equal(true); + }); + }); + + describe(`Quick view the product '${Products.demo_12.name}'`, async () => { + it(`should search for the product '${Products.demo_12.name}'`, async function () { + await testContext.addContextItem(this, 'testIdentifier', 'searchProduct2', baseContext); + + await homePage.searchProduct(page, Products.demo_12.name); + + const pageTitle = await searchResultsPage.getPageTitle(page); + expect(pageTitle).to.equal(searchResultsPage.pageTitle); + }); + + it(`should quick view the product '${Products.demo_12.name}'`, async function () { + await testContext.addContextItem(this, 'testIdentifier', 'quickViewProduct2', baseContext); + + await searchResultsPage.quickViewProduct(page, 1); + + const isModalVisible = await quickViewModal.isQuickViewProductModalVisible(page); + expect(isModalVisible).to.equal(true); + }); + + it('should check product information', async function () { + await testContext.addContextItem(this, 'testIdentifier', 'checkProductInformation2', baseContext); + + const result = await quickViewModal.getProductDetailsFromQuickViewModal(page); + await Promise.all([ + expect(result.name).to.equal(Products.demo_12.name), + expect(result.price).to.equal(Products.demo_12.price), + expect(result.taxShippingDeliveryLabel).to.equal('Tax included'), + expect(result.shortDescription).to.equal(Products.demo_12.summary), + expect(result.coverImage).to.contains(Products.demo_12.coverImage), + expect(result.thumbImage).to.contains(Products.demo_12.thumbImage), + ]); + }); + + it('should close the modal', async function () { + await testContext.addContextItem(this, 'testIdentifier', 'closeModal1', baseContext); + + const isQuickViewModalClosed = await quickViewModal.closeQuickViewModal(page); + expect(isQuickViewModalClosed).to.equal(true); + }); + }); + + describe(`Quick view the product '${Products.demo_14.name}'`, async () => { + it(`should search for the product '${Products.demo_12.name}'`, async function () { + await testContext.addContextItem(this, 'testIdentifier', 'searchProduct3', baseContext); + + await homePage.searchProduct(page, Products.demo_14.name); + + const pageTitle = await searchResultsPage.getPageTitle(page); + expect(pageTitle).to.equal(searchResultsPage.pageTitle); + }); + + it(`should quick view the product '${Products.demo_14.name}'`, async function () { + await testContext.addContextItem(this, 'testIdentifier', 'quickViewProduct3', baseContext); + + await searchResultsPage.quickViewProduct(page, 1); + + const isModalVisible = await quickViewModal.isQuickViewProductModalVisible(page); + expect(isModalVisible).to.equal(true); + }); + + it('should check product information', async function () { + await testContext.addContextItem(this, 'testIdentifier', 'checkProductInformation3', baseContext); + + const result = await quickViewModal.getProductDetailsFromQuickViewModal(page); + await Promise.all([ + expect(result.name).to.equal(Products.demo_14.name), + expect(result.price).to.equal(Products.demo_14.price), + expect(result.taxShippingDeliveryLabel).to.equal('Tax included'), + expect(result.shortDescription).to.equal(Products.demo_14.summary), + expect(result.coverImage).to.contains(Products.demo_14.coverImage), + expect(result.thumbImage).to.contains(Products.demo_14.thumbImage), + ]); + }); + + it('should check that \'Add to cart\' button is disabled', async function () { + await testContext.addContextItem(this, 'testIdentifier', 'checkAddToCartButton', baseContext); + + const isEnabled = await quickViewModal.isAddToCartButtonEnabled(page); + expect(isEnabled, 'Add to cart button is not disabled').to.equal(false); + }); + + it('should close the modal', async function () { + await testContext.addContextItem(this, 'testIdentifier', 'closeModal2', baseContext); + + const isQuickViewModalClosed = await quickViewModal.closeQuickViewModal(page, true); + expect(isQuickViewModalClosed).to.equal(true); + }); + }); + + // Post-condition : Uninstall Hummingbird + uninstallHummingbird(`${baseContext}_postTest`); +}); diff --git a/tests/UI/campaigns/functional/FO/hummingbird/08_menuAndNavigation/03_navigationAndDisplay/04_displayOnSaleFlag.ts b/tests/UI/campaigns/functional/FO/hummingbird/08_menuAndNavigation/03_navigationAndDisplay/04_displayOnSaleFlag.ts new file mode 100644 index 0000000000000..c230cb0bf76b8 --- /dev/null +++ b/tests/UI/campaigns/functional/FO/hummingbird/08_menuAndNavigation/03_navigationAndDisplay/04_displayOnSaleFlag.ts @@ -0,0 +1,125 @@ +// Import utils +import helper from '@utils/helpers'; +import testContext from '@utils/testContext'; +import files from '@utils/files'; + +// Import commonTests +import loginCommon from '@commonTests/BO/loginBO'; +import {deleteProductTest} from '@commonTests/BO/catalog/product'; +import {installHummingbird, uninstallHummingbird} from '@commonTests/BO/design/hummingbird'; + +// Import BO pages +import addProductPage from '@pages/BO/catalog/products/add'; +import dashboardPage from '@pages/BO/dashboard'; +import productsPage from '@pages/BO/catalog/products'; + +// Import FO pages +import productPage from '@pages/FO/hummingbird/product'; + +// Import data +import ProductData from '@data/faker/product'; + +import {expect} from 'chai'; +import type {BrowserContext, Page} from 'playwright'; + +const baseContext: string = 'functional_FO_hummingbird_menuAndNavigation_navigationAndDisplay_displayOnSaleFlag'; + +/* +Pre-condition: +- Create new product with enable 'On sale' flag +- Install the theme hummingbird +Scenario: +- Preview product on check 'On sale' flag +Post-condition: +- Delete created product +- Uninstall the theme hummingbird + */ +describe('FO - Navigation and display : Display \'On sale\' flag', async () => { + let browserContext: BrowserContext; + let page: Page; + + const onSaleProductData: ProductData = new ProductData({ + name: 'On sale product', + type: 'standard', + coverImage: 'image.jpg', + onSale: true, + }); + + // Pre-condition : Install Hummingbird + installHummingbird(`${baseContext}_preTest`); + + // before and after functions + before(async function () { + browserContext = await helper.createBrowserContext(this.browser); + page = await helper.newTab(browserContext); + await files.generateImage(onSaleProductData.coverImage!); + }); + + after(async () => { + await helper.closeBrowserContext(browserContext); + + await files.deleteFile(onSaleProductData.coverImage!); + }); + + // Pre-condition : Create product with on sale flag + describe('BO - Create product with enabled flag \'On sale\'', async () => { + it('should login in BO', async function () { + await loginCommon.loginBO(this, page); + }); + + it('should go to \'Catalog > Products\' page', async function () { + await testContext.addContextItem(this, 'testIdentifier', 'goToProductsPage3', baseContext); + + await dashboardPage.goToSubMenu(page, dashboardPage.catalogParentLink, dashboardPage.productsLink); + await productsPage.closeSfToolBar(page); + + const pageTitle = await productsPage.getPageTitle(page); + expect(pageTitle).to.contains(productsPage.pageTitle); + }); + + it('should click on new product button and go to new product page', async function () { + await testContext.addContextItem(this, 'testIdentifier', 'clickOnNewProductPage', baseContext); + + const isModalVisible = await productsPage.clickOnNewProductButton(page); + expect(isModalVisible).to.be.eq(true); + + await productsPage.selectProductType(page, onSaleProductData.type); + + await productsPage.clickOnAddNewProduct(page); + + const pageTitle = await addProductPage.getPageTitle(page); + expect(pageTitle).to.contains(addProductPage.pageTitle); + }); + + it('should create standard product', async function () { + await testContext.addContextItem(this, 'testIdentifier', 'createStandardProduct', baseContext); + + const createProductMessage = await addProductPage.setProduct(page, onSaleProductData); + expect(createProductMessage).to.equal(addProductPage.successfulUpdateMessage); + }); + }); + + describe('FO - Check \'On sale\' flag', async () => { + it('should preview product', async function () { + await testContext.addContextItem(this, 'testIdentifier', 'goToShopFO2', baseContext); + + page = await addProductPage.previewProduct(page); + + const pageTitle = await productPage.getPageTitle(page); + expect(pageTitle).to.contains(onSaleProductData.name); + }); + + it('should check the discount flag', async function () { + await testContext.addContextItem(this, 'testIdentifier', 'checkDiscountTag', baseContext); + + const flagText = await productPage.getProductTag(page); + expect(flagText).to.contains('On sale!'); + }); + }); + + // Post-condition: Delete created product + deleteProductTest(onSaleProductData, `${baseContext}_postTest_1`); + + // Post-condition : Uninstall Hummingbird + uninstallHummingbird(`${baseContext}_postTest_2`); +}); diff --git a/tests/UI/pages/FO/classic/category/index.ts b/tests/UI/pages/FO/classic/category/index.ts index d8334889a2a75..8124ef1ca525f 100644 --- a/tests/UI/pages/FO/classic/category/index.ts +++ b/tests/UI/pages/FO/classic/category/index.ts @@ -26,7 +26,7 @@ class CategoryPage extends FOBasePage { protected productListDiv: string; - private readonly pagesList: string; + protected pagesList: string; protected productItemListDiv: string; @@ -145,8 +145,8 @@ class CategoryPage extends FOBasePage { // Pagination selectors this.pagesList = '.page-list'; this.paginationText = `${this.productListDiv} .pagination div:nth-child(1)`; - this.paginationNext = '#js-product-list nav.pagination a[rel=\'next\']'; - this.paginationPrevious = '#js-product-list nav.pagination a[rel=\'prev\']'; + this.paginationNext = '#js-product-list nav a[rel=\'next\']'; + this.paginationPrevious = '#js-product-list nav a[rel=\'prev\']'; this.categoryDescription = '#category-description'; diff --git a/tests/UI/pages/FO/classic/product/index.ts b/tests/UI/pages/FO/classic/product/index.ts index 2bd33161bd7df..b71f65968c174 100644 --- a/tests/UI/pages/FO/classic/product/index.ts +++ b/tests/UI/pages/FO/classic/product/index.ts @@ -23,7 +23,7 @@ class Product extends FOBasePage { private readonly warningMessage: string; - private readonly productFlags: string; + protected productFlags: string; private readonly productFlag: (flag: string) => string; diff --git a/tests/UI/pages/FO/hummingbird/category/index.ts b/tests/UI/pages/FO/hummingbird/category/index.ts index 6b1388e896834..781d81659a532 100644 --- a/tests/UI/pages/FO/hummingbird/category/index.ts +++ b/tests/UI/pages/FO/hummingbird/category/index.ts @@ -41,6 +41,9 @@ class Category extends CategoryPage { this.searchFilterPriceSlider = 'div.faceted-slider'; this.searchFiltersSlider = 'div.noUi-base'; this.closeOneFilter = (row: number) => `#js-active-search-filters ul li:nth-child(${row + 1}) a i`; + + // Pagination selectors + this.pagesList = 'ul.pagination'; } /** diff --git a/tests/UI/pages/FO/hummingbird/product/index.ts b/tests/UI/pages/FO/hummingbird/product/index.ts index 4a56c279143bc..14ed15a5d95b6 100644 --- a/tests/UI/pages/FO/hummingbird/product/index.ts +++ b/tests/UI/pages/FO/hummingbird/product/index.ts @@ -16,6 +16,7 @@ class ProductPage extends Product { this.proceedToCheckoutButton = '#blockcart-modal div.cart-footer-actions a'; this.productName = '#content-wrapper h1.product__name'; this.shortDescription = 'div.product__description-short'; + this.productFlags = '#product-images ul.product-flags'; // Product prices block this.productPricesBlock = 'div.product__prices';