diff --git a/apps/chat-e2e/src/tests/entityIcon.test.ts b/apps/chat-e2e/src/tests/entityIcon.test.ts index c690dafb25..4622c52fd3 100644 --- a/apps/chat-e2e/src/tests/entityIcon.test.ts +++ b/apps/chat-e2e/src/tests/entityIcon.test.ts @@ -19,6 +19,7 @@ dialTest( dialHomePage, talkToSelector, marketplacePage, + header, addons, addonsDialog, iconApiHelper, @@ -77,7 +78,7 @@ dialTest( await dialTest.step( 'Click "See all addons" and verify all addons have valid icons', async () => { - await marketplaceSidebar.backToChatButton.click(); + await header.backToChatButton.click(); const expectedAddons = ModelsUtil.getAddons(); await addons.seeAllAddons(); const actualAddonsIcons = await addonsDialog.getAddonsIcons(); diff --git a/apps/chat-e2e/src/ui/webElements/header.ts b/apps/chat-e2e/src/ui/webElements/header.ts index e08e847d5c..42ae15c96d 100644 --- a/apps/chat-e2e/src/ui/webElements/header.ts +++ b/apps/chat-e2e/src/ui/webElements/header.ts @@ -1,5 +1,9 @@ import { API } from '@/src/testData'; -import { HeaderSelectors, SideBarSelectors } from '@/src/ui/selectors'; +import { + HeaderSelectors, + MarketplaceSideBarSelectors, + SideBarSelectors, +} from '@/src/ui/selectors'; import { AccountSettings } from '@/src/ui/webElements/accountSettings'; import { BaseElement } from '@/src/ui/webElements/baseElement'; import { Locator, Page } from '@playwright/test'; @@ -29,6 +33,10 @@ export class Header extends BaseElement { SideBarSelectors.newEntity, ); + public backToChatButton = this.getChildElementBySelector( + MarketplaceSideBarSelectors.backToChatButton, + ); + public async createNewConversation() { const modelsResponsePromise = this.page.waitForResponse(API.modelsHost); const addonsResponsePromise = this.page.waitForResponse(API.addonsHost); diff --git a/apps/chat-e2e/src/ui/webElements/marketplace/marketplaceSidebar.ts b/apps/chat-e2e/src/ui/webElements/marketplace/marketplaceSidebar.ts index 03e383273e..7b503b56c3 100644 --- a/apps/chat-e2e/src/ui/webElements/marketplace/marketplaceSidebar.ts +++ b/apps/chat-e2e/src/ui/webElements/marketplace/marketplaceSidebar.ts @@ -20,9 +20,6 @@ export class MarketplaceSidebar extends BaseElement { return this.marketplaceFilter; } - public backToChatButton = this.getChildElementBySelector( - MarketplaceSideBarSelectors.backToChatButton, - ); public homePageButton = this.getChildElementBySelector( MarketplaceSideBarSelectors.homePageButton, ); diff --git a/apps/chat/src/components/Header/BackToChat.tsx b/apps/chat/src/components/Header/BackToChat.tsx index 3a5c473ce6..7cd0c34e67 100644 --- a/apps/chat/src/components/Header/BackToChat.tsx +++ b/apps/chat/src/components/Header/BackToChat.tsx @@ -22,7 +22,7 @@ export const BackToChat = () => { >