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

Support fast incremental reruns on --test_timeout, etc. changes #5579

Closed
gregestren opened this issue Jul 11, 2018 · 5 comments
Closed

Support fast incremental reruns on --test_timeout, etc. changes #5579

gregestren opened this issue Jul 11, 2018 · 5 comments
Assignees
Labels
team-Configurability Issues for Configurability team

Comments

@gregestren
Copy link
Contributor

Normally, changing any command line flag invalidates the build graph, meaning Bazel's analysis phase has to rebuild the graph from scratch.

There's good reason for this. But it's silly when changing flags like --test_timeout, --test_filter, etc. Those flags are known to only affect tests. So while the tests themselves may need to be re-analyzed, none of their transitive dependencies (which represent the vast majority of the build graph) need to be.

This is a tracking bug for the effort to optimize this case (i.e. only invalidate test targets when --test* flags change).

A flag has already been written to support this: 0412a9f. But some more graph invalidation support is needed to make it functional.

@gregestren
Copy link
Contributor Author

@serynth this is fixed as of f29f78d?

With the caveat that --test_timeout specifically won't get opted in because of the quirk of it being in BuildConfiguration instead of TestConfiguration, but options like --test_filter, --test_arg, --runs_per_test, etc. work out of the box?

@programmablereya
Copy link

Yup, that fixes it! The specific list of flags that works:

  • test_filter
  • cache_test_results
  • test_result_expiration
  • test_arg
  • test_sharding_strategy
  • runs_per_test
  • coverage_support
  • coverage_report_generator

Flags that don't work (well, any of them not listed above, but these are the ones I wanted to move):

  • test_env
  • test_timeout
  • instrumentation_filter
  • instrument_test_targets

@gregestren
Copy link
Contributor Author

Also, have to use --trim_test_configuration to enable the feature.

@gregestren
Copy link
Contributor Author

Anyway, is this issue closeable now?

@programmablereya
Copy link

Yeah, I'm good with this! :D

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
team-Configurability Issues for Configurability team
Projects
None yet
Development

No branches or pull requests

3 participants