fix: support setting visibility on initial chat creation (#975)
This commit is contained in:
parent
a3221fbcdc
commit
575c12503c
15 changed files with 158 additions and 32 deletions
|
|
@ -115,6 +115,23 @@ export class ChatPage {
|
|||
expect(await this.getSelectedModel()).toBe(chatModel.name);
|
||||
}
|
||||
|
||||
public async getSelectedVisibility() {
|
||||
const visibilityId = await this.page
|
||||
.getByTestId('visibility-selector')
|
||||
.innerText();
|
||||
return visibilityId;
|
||||
}
|
||||
|
||||
public async chooseVisibilityFromSelector(
|
||||
chatVisibility: 'public' | 'private',
|
||||
) {
|
||||
await this.page.getByTestId('visibility-selector').click();
|
||||
await this.page
|
||||
.getByTestId(`visibility-selector-item-${chatVisibility}`)
|
||||
.click();
|
||||
expect(await this.getSelectedVisibility()).toBe(chatVisibility);
|
||||
}
|
||||
|
||||
async getRecentAssistantMessage() {
|
||||
const messageElements = await this.page
|
||||
.getByTestId('message-assistant')
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue