Skip to content
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

fix(protractor): unable to specify server as configurable attribute #2643

Merged

Conversation

devversion
Copy link
Contributor

Currently it is not possible to specify the protractor_web_test
server using a configurable attribute. i.e. using select.

This happens because the server attribute is accessed directly
in the macro so that Bazel is unable to respect the select. We
fix this by no longer accessing the server in the macro.

@google-cla google-cla bot added the cla: yes label Apr 29, 2021
Currently it is not possible to specify the `protractor_web_test`
server using a configurable attribute. i.e. using `select`.

This happens because the `server` attribute is accessed directly
in the macro so that Bazel is unable to respect the `select`. We
fix this by no longer accessing the server in the macro.
@devversion devversion force-pushed the fix/protractor-pkg-allow-config branch from 223c704 to 476f8c8 Compare April 29, 2021 16:28
@devversion devversion marked this pull request as ready for review April 29, 2021 16:35
# If a server has been specified, add it to the runfiles together with it's required runfiles. This is necessary
# as the test executable references the server executable as per `TMPL_server` and executes it.
if ctx.executable.server:
server_files = depset(
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit : I would have named it server_runfiles but not important enough to fix

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yup. very true. I will send a follow-up!

@alexeagle alexeagle merged commit 4965db6 into bazel-contrib:stable Apr 29, 2021
twheys pushed a commit to twheys/rules_nodejs that referenced this pull request Jan 13, 2022
…bazel-contrib#2643)

Currently it is not possible to specify the `protractor_web_test`
server using a configurable attribute. i.e. using `select`.

This happens because the `server` attribute is accessed directly
in the macro so that Bazel is unable to respect the `select`. We
fix this by no longer accessing the server in the macro.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants