-
Notifications
You must be signed in to change notification settings - Fork 377
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: Create bot flow #2521
feat: Create bot flow #2521
Conversation
@liweitian can you please add some tests and also address the currently failing Unit and E2E tests? Thank you. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
see earlier comment
Coverage increased (+0.01%) to 40.473% when pulling 1dc508c1f634a226990c26d9cca7c3914b75e50f on liweitian:createBotFlow into 9003876 on microsoft:master. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think we need to plumb through the createdTime
values.
Composer/packages/client/src/CreationFlow/CreateOptions/index.js
Outdated
Show resolved
Hide resolved
Composer/packages/client/src/CreationFlow/CreateOptions/index.js
Outdated
Show resolved
Hide resolved
Composer/packages/client/src/CreationFlow/CreateOptions/index.js
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm going to do a function pass before merging.
@@ -21,7 +21,7 @@ context('Creating a new bot', () => { | |||
|
|||
it('can create a bot from the ToDo template', () => { | |||
cy.findByTestId('Create from template').click(); | |||
cy.findByTestId('TodoSample').click(); | |||
cy.findByTestId('TodoSample').click({ force: true }); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we avoid this? Why is it necessary? Things like this take away from the trustworthiness of our tests.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
cypress-io/cypress#3450
cypress-io/cypress#871
See above issues. the click() method will trigger a weird scroll operation making our bot template invisible. Then we cannot click the template. Using the { force: true } can make it click the template before the scrolling operation. There is a merged PR on this issue which can let user choose whether to scroll or not. I tried it but our current cypress version does not support this. And I checked the official doc. It does not list that option. Perhaps it does not release yet?
@@ -9,7 +9,7 @@ Cypress.Commands.add('createBot', (bobotId: string, botName?: string) => { | |||
cy.findByText('New').click(); | |||
}); | |||
cy.findByTestId('Create from template').click({ force: true }); | |||
cy.findByTestId(`${bobotId}`).click(); | |||
cy.findByTestId(`${bobotId}`).click({ force: true }); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
See above comment.
return ( | ||
<Fragment> | ||
<ChoiceGroup | ||
label={formatMessage('Choose how to create your bot')} | ||
defaultSelectedKey="Create from scratch" | ||
defaultSelectedKey="CreateFromScratch" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Its probably a good idea to make this and CreateFromTemplate
a const value.
* create new bot flow UI * lint fix * update css * update css * update css * fix test case * handle comments * remove unused css Co-authored-by: Chris Whitten <christopher.whitten@microsoft.com>
Description
Applied new design for create bot option 3.
Task Item
Closes #1728
Screenshots