-
Notifications
You must be signed in to change notification settings - Fork 8.4k
chore: refactored test-helper to handle boilerplate for interactive mode #10322
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
base: main
Are you sure you want to change the base?
Conversation
…nteractive' into hriday/chat_compress_intg_test_interactive
Size Change: -2 B (0%) Total Size: 17.5 MB ℹ️ View Unchanged
|
integration-tests/test-helper.ts
Outdated
}> { | ||
const { ptyProcess, promise } = this.runInteractive(); | ||
|
||
const authDialogAppeared = await this.waitForText( |
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.
rather than timing out 5 seconds for the auth prompt, lets end early if "Type your message" appears. You could achieve this by customizing waitForText to take multiple strings returning the one that matched or writing a custom waitFor for just this case with the appropriate more complex logic.
that way we avoid a 5 second timeout just for auth.
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.
changed it.
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.
TLDR
While running integration tests in interactive mode, the auth dialog was showing up on start up. To handle this auth dialog and wait till the cli is ready for input is handled in a new method now in test-helper.
Dive Deeper
Reviewer Test Plan
Testing Matrix
Linked issues / bugs