Reland: Move the Once cache for dexpreopt.GlobalConfig into the

dexpreopt package.

Preparation for a future CL that will need to get the make-written
GlobalConfig from within dexpreopt.

Also rename the Load*Config functions to Parse*Config, since they don't
actually load the config files anymore.

This relands https://r.android.com/1211982.

Bug: 145934348
Test: m
Change-Id: Icb9332a93811d77d2d8b06e983b92501b180a358
This commit is contained in:
Martin Stjernholm
2020-01-20 18:12:23 +00:00
parent 75a48d8ae2
commit 40f9f3c061
8 changed files with 88 additions and 77 deletions

View File

@@ -49,7 +49,7 @@ func TestDexpreoptBootJars(t *testing.T) {
pathCtx := android.PathContextForTesting(config)
dexpreoptConfig := dexpreopt.GlobalConfigForTests(pathCtx)
dexpreoptConfig.BootJars = []string{"foo", "bar", "baz"}
setDexpreoptTestGlobalConfig(config, dexpreoptConfig)
dexpreopt.SetTestGlobalConfig(config, dexpreoptConfig)
ctx := testContext()