[RESTRICT AUTOMERGE]: Skip report creation with 0 modules/tests
This change prevents the tester from evading the TargetPreparer
preconditions by running retry on a failed invocation (by not recording
the run at all if no modules or tests were run).
* Add method in ResultReporter to allow report creation skipping
* Add logic in StsResultReporter to detect 0 module/test runs
* Update STS res XMLs to use StsResultReporter
Automerge is restricted because retry.xml is only used in PI.
Other desserts utilize tradefed default retry which handles this
correctly already.
Bug: 127303013
Test: `run sts-userbuild` on userdebug device does not create a result
anymore.
Change-Id: I745bc45d0f11ce137b48de0f7d962802b9e19881
1 file changed