Skip to content

Regenerate test.xml with generate-xml.sh when testing remotely with --remote_download_minimal #12554

@coeuvre

Description

@coeuvre

Description of the problem:

Normally, when running a test, Bazel expects the test to produce a test.xml. If it is not produced, Bazel will run a separate action using generate-xml.sh to generate that file.

When testing remotely with --remote_download_minimal, Bazel doesn't download the XML file, and then observes that it doesn't exist and so tries to regenerate it, regardless of whether the action actually produced it or not.

Bazel shouldn't regenerate the test.xml if the action actually produced it.

What's the simplest, easiest way to reproduce this bug? Please provide a minimal example if possible.

Java tests with junit produce test.xml automatically. You can verify by running a junit test locally (and Bazel won't run the generate-xml.sh action) and find the file under bazel-testlogs folder.

However, when running the test remotely with --remote_download_minimal, you will notice that Bazel will run an additional generate-xml.sh action.

What's the output of bazel info release?

release 3.7.0

Have you found anything relevant by searching the web?

#6862
#11558

Metadata

Metadata

Assignees

Labels

P2We'll consider working on this in future. (Assignee optional)team-Remote-ExecIssues and PRs for the Execution (Remote) teamtype: bug

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions