Automatically call TestingBuildParams.RelativeToTop()
Fixes the few tests that break due to this and which cannot easily be separated into their own changes. Bug: 183650682 Test: m nothing Change-Id: Ia2f31213a1f114a78e66a81d89279ecde9f4c465
This commit is contained in:
@@ -558,7 +558,7 @@ func (p TestingBuildParams) RelativeToTop() TestingBuildParams {
|
||||
return p
|
||||
}
|
||||
if p.config.config == nil {
|
||||
panic("cannot call RelativeToTop() on a TestingBuildParams previously returned by RelativeToTop()")
|
||||
return p
|
||||
}
|
||||
// Take a copy of the build params and replace any args that contains test specific temporary
|
||||
// paths with paths relative to the top.
|
||||
@@ -670,7 +670,7 @@ func (b baseTestingComponent) newTestingBuildParams(bparams BuildParams) Testing
|
||||
config: b.config,
|
||||
BuildParams: bparams,
|
||||
RuleParams: b.provider.RuleParamsForTests()[bparams.Rule],
|
||||
}
|
||||
}.RelativeToTop()
|
||||
}
|
||||
|
||||
func (b baseTestingComponent) maybeBuildParamsFromRule(rule string) (TestingBuildParams, []string) {
|
||||
|
Reference in New Issue
Block a user