Skip to content

Commit

Permalink
feat: add regenerate cases (#1027)
Browse files Browse the repository at this point in the history
* feat: add regenerate cases

Signed-off-by: SuZhou-Joe <[email protected]>

* feat: optimize cases

Signed-off-by: SuZhou-Joe <[email protected]>

---------

Signed-off-by: SuZhou-Joe <[email protected]>
  • Loading branch information
SuZhou-Joe authored Feb 2, 2024
1 parent b65c5de commit ad6faec
Showing 1 changed file with 17 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,23 @@ if (Cypress.env('DASHBOARDS_ASSISTANT_ENABLED')) {

// should have a suggestion section
cy.get(`[aria-label="chat suggestions"]`).should('be.length', 1);

// Click regenerate button
cy.get(`button[title="regenerate message"]`).click();

// The previous message and the regenerate button should be gone
cy.get(`button[title="regenerate message"]`).should('be.length', 0);

// suggestions should be gone
cy.get(`[aria-label="chat suggestions"]`).should('be.length', 0);

// The regenrate message should be there
cy.contains(
'The indices in your cluster are the names listed in the response obtained from using a tool to get information about the OpenSearch indices.'
);

// should have a suggestion section
cy.get(`[aria-label="chat suggestions"]`).should('be.length', 1);
});
});
});
Expand Down

0 comments on commit ad6faec

Please sign in to comment.