Skip to content

Commit abc5f09

Browse files
added functions
1 parent 2b73b28 commit abc5f09

File tree

1 file changed

+16
-0
lines changed

1 file changed

+16
-0
lines changed

tests/e2e-test/pages/homePage.py

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,8 @@ class HomePage(BasePage):
2020
HIDE_CHAT_HISTORY_BUTTON = "//span[text()='Hide chat history']"
2121
USER_CHAT_MESSAGE = "(//div[contains(@class,'chatMessageUserMessage')])[1]"
2222
STOP_GENERATING_LABEL = "//span[text()='Stop generating']"
23+
# # SHOW_CHAT_HISTORY_BUTTON = "//button[normalize-space()='Show Chat History']"
24+
# HIDE_CHAT_HISTORY_BUTTON = "//button[.//span[text()='Hide chat history']]"
2325
CHAT_HISTORY_NAME = "//div[contains(@class, 'ChatHistoryListItemCell_chatTitle')]"
2426
CLEAR_CHAT_HISTORY_MENU = "//button[@id='moreButton']"
2527
CLEAR_CHAT_HISTORY = "//button[@role='menuitem']"
@@ -88,7 +90,21 @@ def validate_next_meeting_date_time(self):
8890
def click_on_show_chat_history_button(self):
8991
self.page.wait_for_selector(self.SHOW_CHAT_HISTORY_BUTTON)
9092
self.page.locator(self.SHOW_CHAT_HISTORY_BUTTON).click()
93+
self.page.wait_for_timeout(1000)
9194

95+
def click_send_button_for_chat_history_response(self):
96+
# Click on send button in question area
97+
self.page.locator(self.SEND_BUTTON).click()
98+
99+
100+
def click_clear_chat_icon(self):
101+
# Click on clear chat icon in question area
102+
if self.page.locator(self.USER_CHAT_MESSAGE).is_visible():
103+
self.page.locator(self.CLEAR_CHAT_ICON).click()
104+
105+
def click_hide_chat_history_button(self):
106+
# Click on hide chat history button in question area
107+
self.page.locator(self.HIDE_CHAT_HISTORY_BUTTON).click()
92108

93109
def has_reference_link(self):
94110
# Get all assistant messages

0 commit comments

Comments
 (0)