@bigbinary/neeto-playwright-commons 1.10.6 → 1.10.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/index.cjs.js CHANGED
@@ -99,6 +99,7 @@ const ROUTES = {
99
99
  show: (id) => `/team_members/teams/${id}`,
100
100
  },
101
101
  attachment: `/neeto_editor${BASE_URL}/direct_uploads/attach`,
102
+ dashboard: "/dashboard",
102
103
  };
103
104
  const API_ROUTES = {
104
105
  teamMembers: {
@@ -12848,6 +12849,7 @@ class EmbedBase {
12848
12849
  const CHAT_WIDGET_TEXTS = {
12849
12850
  newConversation: "Ask a question",
12850
12851
  welcomeChatBubble: "Hi! I'm here to assist you with any questions you may have. What can I do for you?",
12852
+ preChatQuestions: "Please fill in the form to start chatting.",
12851
12853
  };
12852
12854
  const MEMBER_TEXTS = {
12853
12855
  agent: "Agent",
@@ -12930,6 +12932,7 @@ const CHAT_WIDGET_SELECTORS = {
12930
12932
  preChatSubmitButton: "neeto-chat-widget-pre-chat-submit-btn",
12931
12933
  chatBubble: "neeto-chat-widget-chat-message-bubble",
12932
12934
  closeChat: "neeto-chat-widget-close-btn",
12935
+ chatQuestionHeader: "chat-question-header",
12933
12936
  };
12934
12937
  const CHANGELOG_WIDGET_SELECTORS = {
12935
12938
  changelogWrapper: ".nc-widget__wrapper",
@@ -12988,6 +12991,14 @@ class HelpAndProfilePage {
12988
12991
  await test$1.expect(newConversationButton).toBeVisible({ timeout: 35000 }); // Adding additional toBeVisible to take advantage of the auto-retrying web-first assertion
12989
12992
  await newConversationButton.click();
12990
12993
  await test$1.expect(this.neetoChatSpinner).toBeHidden({ timeout: 35000 });
12994
+ (await this.neetoChatFrame
12995
+ .getByTestId(CHAT_WIDGET_SELECTORS.chatQuestionHeader)
12996
+ .getByText(CHAT_WIDGET_TEXTS.preChatQuestions)
12997
+ .isVisible()) &&
12998
+ (await this.neetoChatFrame
12999
+ .getByTestId(CHAT_WIDGET_SELECTORS.preChatSubmitButton)
13000
+ .click());
13001
+ await test$1.expect(this.neetoChatSpinner).toBeHidden({ timeout: 35000 });
12991
13002
  });
12992
13003
  await test$1.test.step("Step 4: Verify conversation window", async () => {
12993
13004
  await test$1.expect(this.neetoChatFrame.getByTestId(CHAT_WIDGET_SELECTORS.chatBubble)).toHaveText(CHAT_WIDGET_TEXTS.welcomeChatBubble);
@@ -13129,7 +13140,7 @@ class HelpAndProfilePage {
13129
13140
  await this.page
13130
13141
  .getByTestId(PROFILE_SECTION_SELECTORS.profileOrganizationSettingsButton)
13131
13142
  .click();
13132
- await test$1.expect(this.page).toHaveURL(new RegExp(ROUTES.authSettings));
13143
+ await test$1.expect(this.page).toHaveURL(new RegExp(ROUTES.dashboard));
13133
13144
  });
13134
13145
  };
13135
13146
  this.verifyLogoutV2 = async () => {