-
Notifications
You must be signed in to change notification settings - Fork 6.8k
build: create script that simplifies bazel testing workflow #18016
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
Conversation
crisbeto
left a comment
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.
LGTM
Instead of remembering what individual browser targets are called, and what the convention for Bazel labels is, we should just provide a script that simplifies the Bazel testing workflow. e.g. ```bash yarn test button [--local] [--firefox] [--no-watch] yarn test src/material/button src/cdk/bidi yarn test button slider coercion ``` Eventually we should document this script better in one of the contributing markdown files, but these docs need a general cleanup since they still mention Gulp.
69ad269 to
f30edba
Compare
| * | ||
| * Supported command line flags: | ||
| * | ||
| * --local | If specified, no browser will be launched. |
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 make this the default? Then invert the flag to something like --no-headless
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.
Do you mean that we do not run any browser by default? (asking because the --local flag does this and you commented on that flag).
If you meant that we run Chrome in non-headless mode by default: I don't think we have a way to launch Chrome through Bazel without headless (it seems to depend on the $DISPLAY env variable).
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 want the command to not pop open a browser window but to also run the tests without having to manually open the page (but you can still open the debug page if you need to)
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 this is possible. The @bazel/karma rules decide based on the platform environment whether the browser runs in headless or non-headless mode. For me on Windows, it always runs headless.
Splaktar
left a comment
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.
This is great! Would love to see at least a minor mention in the Contributing docs.
|
@Splaktar Yeah. I have an item on my list to update it to match our latest changes. IIRC it still references Gulp etc. If you want to have a look at the doc, that would be cool too 😄 |
|
@jelbourn The PR that supposedly fixed the |
jelbourn
left a comment
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.
LGTM
We can see about the upstream behavior as a separate concern
…18016) Instead of remembering what individual browser targets are called, and what the convention for Bazel labels is, we should just provide a script that simplifies the Bazel testing workflow. e.g. ```bash yarn test button [--local] [--firefox] [--no-watch] yarn test src/material/button src/cdk/bidi yarn test button slider coercion ``` Eventually we should document this script better in one of the contributing markdown files, but these docs need a general cleanup since they still mention Gulp.
|
This issue has been automatically locked due to inactivity. Read more about our automatic conversation locking policy. This action has been performed automatically by a bot. |
Instead of remembering what individual browser targets are called,
and what the convention for Bazel labels is, we should just provide
a script that simplifies the Bazel testing workflow. e.g.
Eventually we should document this script better in one of the
contributing markdown files, but these docs need a general cleanup
since they still mention Gulp.